# change "128" (MBytes) below to a number which suits your needs dd if=/dev/zero of=/swapfile bs=1M count=128 mkswap /swapfile swapon /swapfile # enables swap right away; disable with "swapoff -a" echo '/swapfile none swap sw 0 0' >> /etc/fstab # enables swap at system boot