Find the answer to your Linux question:
Results 1 to 3 of 3
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    creation of swap space after installation

    hi everybody

    I am using is fedora 4

    i forgot to give the swap space while installation

    i have free space on my disk and i want to add swap space.

    please tell me how to add the swap space


  2. #2
    Linux Guru anomie's Avatar
    Join Date
    Mar 2005
    Let's see:

    1. Create the swap partition using fdisk.
    2. Set up the swap area using mkswap.
    3. Activate the swap area using swapon.
    4. Set up an /etc/fstab entry for it. You can use something like:
    /dev/hda3            swap                 swap       defaults                0 0
    This assumes the swap partition is fourth partition of first physical drive. You will want to adjust accordingly for yourself. I think that should do it.

  3. #3
    Linux Enthusiast puntmuts's Avatar
    Join Date
    Dec 2004
    Republic Banana
    You can use a swap file as well.
    Here is an example for a swap file:
    dd if=/dev/zero of=/usr/local/swapfile bs=1000000 count=200 (200mb swap file)
    chmod 600 /usr/local/swapfile
    mkswap /usr/loca/swapfile
    swapon /usr/local/swapfile
    Then add this line to your /etc/fstab
    /usr/local/swapfile swap swap defaults 0 0
    I\'m so tired .....

  4. $spacer_open

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts