Simpler Navigation for Servers and Operating Systems - Please Update Your Bookmarks
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
If you have bookmarked forums or discussion boards in Servers and Operating Systems, we suggest you check and update them as needed.
General
cancel
Showing results for 
Search instead for 
Did you mean: 

Swap partition is not mounted automatically.

Minoru Asano
Frequent Advisor

Swap partition is not mounted automatically.

Hello,

At the customer site, swap partition is not mounted automatically.

[ENVIRONMENT]
RHEL ES 4 up2
HP Proliant BL25p 4G memory

[SITUATION]
One application has consumed physical memory.
The system has 2G swap memory, and when the application has gone down, swap space
seems be "0" by viewing free command.
The application is data transfer application by ftp command.

After reboot, the swap space is not mounted.
The swap partition is configured at /etc/fstab.
Nothing message appeared by viewing "swapon -s" command.
And the situation is not changed even if he executed "mount -a" command.
But he execute "swapon -a" command, the mount partition was mounted.

[QUESTION]
- Have you ever seen this phenomenon ?
- Why is not the swap partition mounted automatically ?

[ADDITIONAL INFORMATION]
When he executed "swapon -s" command, the following messages has appeared at messages file:
Jul 5 19:03:32 host123 kernel: Adding 2097112k swap on /dev/cciss/c0d0p2. Priority:-1 extents:1
But there is not information like following:
Jun 27 13:14:36 ssc0001 rc.sysinit: Enabling swap space: succeeded

Thank you for advice.
Best Regards.
/Minoru


4 REPLIES
Steven E. Protter
Exalted Contributor

Re: Swap partition is not mounted automatically.

Shalom,

check /var/log/messages

There may be some deep ugly problem revealed elsewhere in that file.

Check for invisible characters in /etc/fstab or a mistake as compared the partition you ran the swapon command against.

Also fdisk -l

Make sure the partition is swap or LVM depedning on how you did the system.

SEP

Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Heironimus
Honored Contributor

Re: Swap partition is not mounted automatically.

"mount -a" will never activate swap because swap is not a filesystem to be mounted. swapon is the proper command to use.

The reason it fails to activate the swap is probably displayed to the console or written to a log while the machine boots. It may show up in /var/log/dmesg.
skt_skt
Honored Contributor

Re: Swap partition is not mounted automatically.

Check the /var/log/boot.log. there will be an entry for sucess or failure.
Vitaly Karasik_1
Honored Contributor

Re: Swap partition is not mounted automatically.

May be it was some problem with a disk where swap partition is located?

(I hope you didn't delete swapon command from /etc/rc.sysinit script!)