Tag Info

Hot answers tagged

1

Necessity for swap Swap is useful for 3 reasons. One is removing clutter from RAM. From the article on kernel.org: "A significant number of the pages referenced by a process early in its life may only be used for initialisation and then never used again. It is better to swap out those pages and create more disk buffers than leave them resident ...


1

You swap file should be in /swapfile with 600 rights. #moving file and changing rights sudo mv /root/myswapfile /myswapfile sudo chmod 600 /myswapfile sudo mkswap /myswapfile add swap file. I think you forget this command sudo swapon /myswapfile #check swap is working sudo swapon -s


1

Use fdisk to create a swap. Add a new partition, select Linux swap, write the changes. mkswap /dev/sd? You need to add it to your /etc/fstab/. Change XXX to the swap UUID. UUID=XXX none swap sw 0 0 Run swapon -a to make it available from /etc/fstab.


1

First, erase your original swapfile: sudo rm /myswapfile Next, run the following commands one by one: sudo fallocate -l 1G /swapfile sudo chmod 600 /swapfile ls -lh /swapfile The output should be similar to the following: -rw------- 1 root root 1.0G Aug 3 18:20 /swapfile Now, run the following commands: sudo mkswap /swapfile sudo swapon /swapfile ...


1

You need to add UUID of your swap partition to /etc/fstab file. Run sudo -H gedit /etc/fstab and add or replace the line regarding swap like this UUID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx none swap sw 0 0 You can see the UUID of your swap partition in gparted if you click properties.


1

So the problem is the total - 0GB, the only difference I could find is that on my (Fedora) system fstab looks like this: /dev/mapper/fedora-swap swap swap defaults 0 0 The /dev part is different because I use LVM, the difference is in the second parameter, at you that is none, here is swap


1

Best you can do is to shange swappiness parameter The swappiness parameter configures how often your system swaps data out of RAM to the swap space. This is a value between 0 and 100 that represents a percentage. With values close to zero, the kernel will not swap data to the disk unless absolutely necessary. Remember, interactions with the swap file are ...


1

You will need to use swapoff and swapon to fix the problem, because you need to reformat the swap to the full size of the partition, and you cannot do this while it is in use. First type: sudo swaplabel /dev/sdb2 You should see something like: UUID: ad49d796-e9d9-4bde-8d28-a920c3727d48 If so, now type the following VERY carefully, where <UUID> ...


1

There is no valid reason any more to have multiple partitions, esp. on personal desktops/laptops. This is even reflected in the default setting for the partition manager: everything on a single partition. I don't bother with a swap partition. IIRC, the Ubuntu installer won't let you install without one, so pick the smallest size you can get away with, and ...


1

A RAMDISK is a block device that is backed by your RAM. Think of it as a way to use your RAM as a 'hard drive' in the sense you could read/write files to it, however all the limitations of RAM would still apply - notably that it's volatile and rebooting your server would cause all data on that drive to be lost. A Swap partition on the other hand is a way ...



Only top voted, non community-wiki answers of a minimum length are eligible