Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save johnpmitsch/e84d42a12067426f40a164617ef772ce to your computer and use it in GitHub Desktop.
Save johnpmitsch/e84d42a12067426f40a164617ef772ce to your computer and use it in GitHub Desktop.
OOM errors for NFS workaround
you could generate a swapfile on the FS and then use that
dd if=/dev/zero of=/path/to/swapfile bs=1014 count=$(expr <megabytes> \* 1024)
mkswap /path/to/swapfile
swapon /path/to/swapfile
then add it to the fstab if you want it to persist past reboots
or
you could dd, mkswap, add to fstab, then swapon -a
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment