Step by step creating Ubuntu swap file

Ubuntu, 2015-06-16 23:22:36 UTC

Login as root and type these command;

1. Swap allocation;

# fallocate -l 512M /swap



2. Seting permission

# chmod 600 /swap



3. Make swap

# mkswap /swap



4. Swap activation

# swapon /swap



5. Open fstab

# nano /etc/fstab



6. Add this line into fstab

/swap none swap defaults 0 0



Sumber: http://www.develbook.com/2015/02/step-by-step-creating-ubuntu-swap-file.html

 


Share: