Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
echo "Creating 3gb swap for $(whoami)"
free -h
sudo fallocate -l 3G /swapfile
ls -lh /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
sudo swapon --show
free -h
sudo sysctl vm.swappiness=10
sudo sysctl vm.vfs_cache_pressure=50
echo "--DONE--"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment