Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #begin optional swap section
- echo "Setting up disk swap..."
- free -h
- sudo fallocate -l 4G /swapfile
- ls -lh /swapfile
- sudo chmod 600 /swapfile
- sudo mkswap /swapfile
- sudo swapon /swapfile
- echo '/swapfile none swap sw 0 0' | sudo tee -a /etc/fstab
- sudo bash -c "echo 'vm.swappiness = 10' >> /etc/sysctl.conf"
- free -h
- echo "SWAP setup complete..."
- #end optional swap section
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement