Skip to content

Instantly share code, notes, and snippets.

@Wind4
Created April 15, 2015 08:56
Show Gist options
  • Save Wind4/283a289775b188a17b92 to your computer and use it in GitHub Desktop.
Save Wind4/283a289775b188a17b92 to your computer and use it in GitHub Desktop.
fallocate -l 512M /var/swapfile
chmod 0600 /var/swapfile
mkswap /var/swapfile
swapon /var/swapfile
echo "/var/swapfile swap swap sw 0 0" >> /etc/fstab
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment