- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: Swap is not used in RHAS 4.0
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-12-2007 10:22 PM
05-12-2007 10:22 PM
Swap is not used in RHAS 4.0
My server is : Red Hat Enterprise Linux AS release 3 (Taroon Update 5)
Hardware is Manufacturer: HP
Product Name: ProLiant DL580 G3
kernel : 2.4.21-32.0.1.ELhugemem
The out put of free -m command is shown below
total used free shared buffers cached
Mem: 12045 12026 19 0 139 11525
-/+ buffers/cache: 361 11684
Swap: 23173 0 23173
Why the server is not using the Swap memoy even after the physical memory is almost full. The same server has recently got hung and we had to restart it.
Can anybody help in this case ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-12-2007 11:25 PM
05-12-2007 11:25 PM
Re: Swap is not used in RHAS 4.0
Try adding a new swap space.
---scraped from an oracle doc ----
To add swap space, perform the following steps:
1.
Open a terminal window and log in as root user. Check the id of the logged-in user. To verify and make changes to the kernel parameters, you should be logged in as super user (root).
Move your mouse over this icon to see the image
2.
Check the current availability of memory and swap space by using the free command. You might see different figures than those given in the screenshots.
Move your mouse over this icon to see the image
3.
Note that the system has around 1 GB of total memory and 500 MB of swap space. As per the installation guide, for better performance, it is recommended that swap area should be at least 1.5 or 2 times the total memory. To find whether you have sufficient free space on the disk to increase the swap area, issue the df -m command.
Move your mouse over this icon to see the image
4.
As shown above, there is 4561 MB (around 4 GB) of free space available. Create a swap file by using the following command:
dd if=/dev/zero of=/bigswap bs=1k count=1548576
Note: Name = /bigswap, Block size = 1 KB and File size 1.5 GB.
Move your mouse over this icon to see the image
5.
Change the access rights of the file by using the chmod 600 /bigswap command so that others do not accidentally delete the file.
Move your mouse over this icon to see the image
6.
Use the mkswap /bigswap command to make this file a swap file.
Move your mouse over this icon to see the image
7.
The next step is to enable swap on to the designated file by using swapon /bigswap command.
Move your mouse over this icon to see the image
8.
Check whether the swap space is added by using the free command.
Move your mouse over this icon to see the image
9.
Finally, choose the editor of your choice and add an entry in the /etc/fstab file as shown below to ensure that the new swap file is available after you reboot the machine. After adding the entry, save and close the file. So next time you log in, the system will read this file and use the /bigswap file to increase the swap space.
Move your mouse over this icon to see the image
Note: This is not a mandatory step.
-------------
Take a look at /var/log/messages and dmesg and see if swap is even activated.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-13-2007 12:38 PM
05-13-2007 12:38 PM
Re: Swap is not used in RHAS 4.0
The fact that a number shows up in the swap columns shows that swap is turned on, and is available.
What is the difference between the 'SwapTotal' and 'SwapFree' values in '/proc/meminfo' ? My bet is something like 200K.
Also, the sheer value of swap.. 23GB.. Is this all in one partition, or in multiple parts?
There was a post recently on this forum which discussed the maxiumum swap sizes, and how best to split them up.. Let me see if I can dig it up..
*rifles around* ah, here we go..
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=1114456&admit=-682735245+1179102509755+28353475
Which points to:
http://www.redhat.com/magazine/017mar06/departments/tips_tricks/
Which states:
--
Red Hat Enterprise Linux 3 and higher supports larger swap partitions, each can be of maximum size set by the file size limit and the block device limit for swap partitions on that platform. Red Hat Enterprise Linux 3 has a 1TB limitation as maximum size of block devices, so it's 1TB.
While larger swap partitions are permitted, one large swap partition could affect system performance. For better performance it is recommended to split swap space to multiple discs. Separating swap partitions to different disk could reduce the load on a single disk.
--
So, that shouldn't be the issue.
So this really leaves the one concept..
*ponders*
11GB of 'cached' means that there's alot of 'play' room in the memory.
Whilst there is only 19MB available memory, in reality it's about 11.6GB (Cached + Buffers + Free).
Before swap will readily be used, it will first exhaust cache and buffers (which speed up IO read/writes etc.).
As you've got plenty of that available, there's no need to use massive slabs of swap.
That being said, if you do a little math here, there's only about 360MB memory in actual use for programs. The rest is IO buffers and caching.
Speedy ;)
So, simple answer: Don't fret! You're system is REALLY happy.
Now, as for the crash.. In the subject, you say AS4, but in the post you say AS3. Given Taroon and the kernel revision, we are talking 3.
You're at least 4 kernel revisions old. There's 2.4.21-47.0.1.EL available. Are other packages similarly not updated?
Also, are you running the PSP?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-13-2007 03:24 PM
05-13-2007 03:24 PM
Re: Swap is not used in RHAS 4.0
See also:
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=1029490
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-13-2007 05:58 PM
05-13-2007 05:58 PM
Re: Swap is not used in RHAS 4.0
you have enough free RAM, so why should it be using slow disk memory?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2007 07:11 PM
05-16-2007 07:11 PM
Re: Swap is not used in RHAS 4.0
You sure check the page in and page out...if there is high usage/utilization, then it will start to use swap.....you can use iostat to check this page in and page out...
Thanks