Last active
August 29, 2017 06:02
-
-
Save akashjobanputra/8b0f6da5a0097c5163cb27912f579203 to your computer and use it in GitHub Desktop.
Create & use swap file to temporarily increase swap size
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 | |
sudo dd if=/dev/zero of=/swap bs=10M count=100 #Creates a file of size 1000M | |
sudo losetup /dev/loop0 /swap | |
sudo mkswap /dev/loop0 | |
sudo swapon /dev/loop0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment