Find the answer to your Linux question:
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 13
While booting Linux it takes ages for 'enabling swap space' I have allocated swap space twice that of the RAM. Is there a way to fix it? What should I ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jul 2009
    Posts
    7

    Linux takes long time while booting- enabling swap space


    While booting Linux it takes ages for 'enabling swap space'
    I have allocated swap space twice that of the RAM.

    Is there a way to fix it? What should I do to avoid this in the future
    installs? pls
    Cheers

  2. #2
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,453
    1. How much swap space did you actually allocate?
    2. Are you running 32-bit, or 64-bit linux?
    3. Where is the swap space located? On its own partition/disc, or a regular file, or some combination?
    4. Are you running more than one swap file or partition?
    5. Which distribution+version of Linux are you running?
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  3. #3
    Just Joined!
    Join Date
    Jul 2009
    Posts
    7
    1. 2 gigs of RAM, swap space 4 gigs (have even kept 2 gb swap on one machine).
    2. 32-bit as well as 64-bit (3 servers 64-bit, 10 PCs 32-bit)
    3. Swap space on main drive primary partition
    4. only one partition for swap
    5. RHEL 4.0

  4. #4
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,729
    What is the output of free command?
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  5. #5
    Just Joined!
    Join Date
    Jul 2009
    Posts
    7
    Here is the 'free command' output :


    total used free shared buffers cached
    Mem: 3171000 1121956 2049044 0 92484 808488
    -/+ buffers/cache: 220984 2950016
    Swap: 4096524 0 4096524

  6. #6
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,729
    Post the contents of /etc/fstab file too.
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  7. #7
    Just Joined!
    Join Date
    Jul 2009
    Posts
    7
    Here it is, /etc/fstab
    __________________________________________________ _____
    # This file is edited by fstab-sync - see 'man fstab-sync' for details
    LABEL=/ / ext3 defaults 1 1
    LABEL=/boot1 /boot ext3 defaults 1 2
    LABEL=/cad /cad ext3 defaults 1 2
    none /dev/pts devpts gid=5,mode=620 0 0
    none /dev/shm tmpfs defaults 0 0
    LABEL=/home /home ext3 defaults 1 2
    none /proc proc defaults 0 0
    LABEL=/shared /shared ext3 defaults 1 2
    none /sys sysfs defaults 0 0
    LABEL=/tarballs /tarballs ext3 defaults 1 2
    LABEL=/tmp /tmp ext3 defaults 1 2
    LABEL=/var /var ext3 defaults 1 2
    LABEL=SWAP-sda3 swap swap defaults 0 0
    LABEL=SWAP-sdb1 swap swap defaults 0 0

    192.168.1.1:/home /home nfs rw 0 0
    /dev/hdc /media/cdrecorder auto pamconsole,fscontext=system_u:object_r:removable_t ,exec,noauto,managed 0 0
    /dev/hda /media/cdrom auto pamconsole,fscontext=system_u:object_r:removable_t ,exec,noauto,managed 0 0
    /dev/fd0 /media/floppy auto pamconsole,fscontext=system_u:object_r:removable_t ,exec,noauto,managed 0 0
    __________________________________________________ _____________

  8. #8
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,453
    Well, it seems you are using 2 swap partitions instead of one. At least it appears that way from your fstab output. That may be related to your problem for this particular system, but you'd have to disable one of the partitions in order to test that hypothesis. Their size also may be a factor. Also, is the time a problem on the PCs, servers, or both?
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  9. #9
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,729
    free command is listing only one SWAP partition but /etc/fstab has two entries for SWAP. As Rubberman suggested already, disable one SWAP in /etc/fstab and check if it works.

    Put # sign before LABEL=SWAP-sdb1 in /etc/fstab file and reboot machine.
    Code:
    # LABEL=SWAP-sdb1 swap swap defaults 0 0
    In case it doesn't work, disable other SWAP partition.
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  10. #10
    Just Joined!
    Join Date
    Jul 2009
    Posts
    7
    Sorry guys, I gave it some time and realized that the systems halt for a minute just after 'enabling swap space' not on enabling swap space. I tried commenting out that line in fstab but all the same. Moreover, other machines only have one 'LABEL... .. ..'

    Any Ideas?

Page 1 of 2 1 2 LastLast

Posting Permissions

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