Debian – How to configure swap space after system installation

debianswap

I've installed Debian Wheezy; after installation completed, I realized that I forgot to set the swap memory. So now, how can I configure the swap space?

Best Answer

Try this:

  1. Create a partition or RAID array or logical volume... (or use an existing one) for swap
  2. mkswap that partition
  3. Run blkid that-block-device
  4. Add an entry to /etc/fstab in the form UUID=7321174b-e4d8-4d9d-b223-113a1b8e9c9f swap swap sw 0 0 (see step 3 for actual UUID)
  5. swapon -a or reboot
Related Question