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
Discussions
Discussions
Forums
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
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
тАО07-01-2002 08:14 AM
тАО07-01-2002 08:14 AM
Swap-mem
I have a database production server (V-class). 14Gb RAM ; 14Gb device swap (i.e 14 one Gb raw lvs) and pseudo-swap on.
Swapinfo -mt shows swap usage between average 40-50% with all the dev swap entries showing 0% usage and pseudo-swap usage is the same as total swap usage. (sample output:
TYPE AVAIL USED FREE USED LIMIT RESERVE PRI NAME
dev 1024 0 1024 0% 0 - 1 /dev/vg00/lvol2
dev 1024 0 1024 0% 0 - 1 /dev/vg00/lvol9
dev 1024 0 1024 0% 0 - 1 /dev/optvg/swap1
dev 1024 0 1024 0% 0 - 1 /dev/optvg/swap2
dev 1024 0 1024 0% 0 - 1 /dev/optvg/swap3
dev 1024 0 1024 0% 0 - 1 /dev/optvg/swap4
dev 1024 0 1024 0% 0 - 1 /dev/vg00/swap5
dev 1024 0 1024 0% 0 - 1 /dev/vg00/swap6
dev 1024 0 1024 0% 0 - 1 /dev/vg00/swap7
dev 1024 0 1024 0% 0 - 1 /dev/vg00/swap8
dev 1024 0 1024 0% 0 - 1 /dev/vg01/swap9
dev 1024 0 1024 0% 0 - 1 /dev/vg01/swap10
dev 1024 0 1024 0% 0 - 1 /dev/vg01/swap11
dev 1024 0 1024 0% 0 - 1 /dev/vg01/swap12
reserve - 7847 -7847
memory 11146 4472 6674 40%
total 25482 12319 13163 48% - 0 -
Apparently, device swap is not being used. The memory usage is around 65% average and 85% peak.
My question is, if i disable pseudo-swap, would there be a reduction in the memory usage value? I know, everything looks good and there is no need to change it. But, the 85% peak is provoking constant questions from the user groups who would like to add more memory for future growth. i am toying with the idea of disabling pseudo swap to decrease the memory usage value. any thoughts? any body tried this? Wouldn't this increase the cpu load, since the device swap kicks into play?
Again, this has been an oft-discussed item and i know it is good to use even 100% memory , but dealing with "experts" who go by numbers alone is proving to be tedious. Hence i am probing this approach.
thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-01-2002 08:30 AM
тАО07-01-2002 08:30 AM
Re: Swap-mem
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-01-2002 08:41 AM
тАО07-01-2002 08:41 AM
Re: Swap-mem
Your'e looking at the memory line from the swapinfo command the wrong way. What it should really say is memory_swap (not physical memory). Pseudo swap (the memory line) is a safety net in case you run out of device swap, thats all. As you have 14Gb of RAM and 14Gb of device swap you dont need pseudo swap or even have it switched on - seeing as its only causing confusion amongst user groups who cant possibly understand its meaning.
The reserve line from swapinfo shows you have only 7,847Mb of memory used for user programs (not including kernel+root processes) which is available for paging if need be.
The memory line shows 4472Mb already used - this is not really used but 4472Mb of memory locked by processes so it is not availble for use as pseudo swap (or memory swap) thus swpainfo shows it as being already used (or unavailable). This 4472Mb would be used by things like database shared memory or SGA - thats why its locked and is not available for use as memory swap.
To stop confusion I would simply turn pseudo swap off. Instead just supply users with the output from vmstat (free memory pages * 4096) so they can see in reality how much memory is used and how much is free. Remember, as Bill Hassel said, using all your available RAM is a GOOD thing - it means you arent wasting any and your using it to enhance performance. Its only if you use more memory than you have RAM that you start causing problems.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-01-2002 03:20 PM
тАО07-01-2002 03:20 PM
Re: Swap-mem
They said that if you really wanted to know if there was a memory crunch you should look at the page activity columns with the vmstat commands. Especially the scan rate.
I have a lot of systems with a pretty even spread between 256MB of RAM to 4GB of RAM. They all run big databases and lots of processes, and they all seem to use about 85% of Memory after they have been running for a few days. This seems to be completely normal. I don't expect that a system would use less memory than that unless it just had an obscenely large amount of RAM for the amount of programs and data it was working with.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-02-2002 02:29 AM
тАО07-02-2002 02:29 AM
Re: Swap-mem
...
> But, the 85% peak is provoking constant questions
> from the user groups who would like to add more memory
> for future growth.
*What*/*where* is this "memory usage" displayed? I.e. which utility and which (name) field? If "Mem Util" in Glance, then believe the experts, 85% is good and 65% is bad.
If I were you, I would *not* disable pseudo swap. As has been discussed many times before, disabling it has only disadvantages for 99+ percent of the cases (And no, you're not in the 1- percent! :-)).
Same advice as always: *Always* use the "-t" option of swapinfo(1M) and *only* look at the "total" line. It makes everyone's life so much easier, including ours! :-).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-02-2002 05:39 AM
тАО07-02-2002 05:39 AM
Re: Swap-mem
Don't use swapmem_on=0 and return all the extra swap space other than 1-2 Gb. Then monitor swapinfo -tm regularly to see if actual device swap is being used. Once total device swap nears 75%, add another Gb.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-22-2002 01:39 PM
тАО07-22-2002 01:39 PM
Re: Swap-mem
Thanks for the responses. As expected, pseudoswap brings forth contrasting responses from the 1 and 0 camps ;-) I belong to the 1 camp; i prefer to set it to 1 by default, since all my systems have memory in the ~>8Gb range and it's worked fine. Isn't it better to keep everything in the RAM. As far as this "problem" was concerned, i was referring to the memory usage of 65-85% from the Glance output. (and not swapinfo output as some folks construed) and the users refer to glance output as well.
Ideally, i would like to turn pseudoswap off and monitor it's effect overall on the system and see whether it makes any difference vs with pseudoswap on , but this being a production system, any experimentation is ruled out ;-) and the problem is no longer there, as far as users are concerned.
thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-22-2002 06:13 PM
тАО07-22-2002 06:13 PM
Re: Swap-mem
Here's the deal in your case; if you have 1x RAM as swap then swapmem_on=1 does absolutely nothing other than add a little kernel overhead. Your logically consistant choices are 1) leave swap as it is and set swapmem_on=0 OR 2) reduce swap to 1-2GB and set swapmem_on=1. You will then regain a big chunk of wasted disk space and a really big chunk if your swap is mirrored (and it should be).
The important point to remember is that enabling pseudoswap does not mean that you are swapping in memory.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-23-2002 12:13 AM
тАО07-23-2002 12:13 AM
Re: Swap-mem
Having said that I would also have kept pseudoswap and decreased dev-swap.
Regards,
Trond