Creating a loopback swap partition

dd if=/dev/zero of=swapfile bs=1M count=1024
note: replace count with the appropriate size
mkswap swapfile
swapon swapfile
edit /etc/fstab to include the appropriate entry e.g.
/root/swapfile swap swap defaults 0 0

Submitted by jkelly on Wed, 2007-06-20 19:43. categories [ | | ] login or register to post comments