Created
July 5, 2021 05:52
-
-
Save r4nd1/3b5331eebff34e5f519ff71fb0214ef1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
dd if=/dev/zero of=/swapfile count=4096 bs=1M | |
ls / | grep swapfile | |
chmod 600 /swapfile | |
ls -lh /swapfile | |
mkswap /swapfile | |
swapon /swapfile | |
echo '/swapfile none swap sw 0 0' >> /etc/fstab | |
free -m |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment