question about swap space (590 Views)
Reply
Super Advisor
meekrob
Posts: 375
Registered: ‎02-24-2003
Message 1 of 8 (590 Views)
Accepted Solution

question about swap space

Good day All,

 

in your opinion, what is the recommended swap space (device swap) to configure on a 12GB RAM 11iv3 system?

I guess that the old rule of "double the size of physical memory" is becoming obsolete especially with the large amounts of physical memory that can be added.

 

Many Thanks

Honored Contributor
Patrick Wallek
Posts: 13,784
Registered: ‎06-21-2000
Message 2 of 8 (587 Views)

Re: question about swap space

I would start with 4 GB - 6 GB and monitor periodically with 'swapinfo -tam'.

 

 

Super Advisor
meekrob
Posts: 375
Registered: ‎02-24-2003
Message 3 of 8 (582 Views)

Re: question about swap space

If the size of the device swap is less than the total physical memory does this have an impact on crash dumps? so, suppose the system crashes, will i have all dumps related to that crash logged?

 

Regards

Trusted Contributor
donna hofmeister
Posts: 191
Registered: ‎08-29-2008
Message 4 of 8 (579 Views)

Re: question about swap space

in the old days, the size of swap needed to (at least) match your memory size.  that's (usually) no longer the case as the swap algorithm has been changed (and i'd dearly love to find a simple-human explanation of pseudo-swap) (being a simple human, myself :-)

 

anyhow...

 

run 'crashconf -v' to see what's what on your system.  it will give you an idea of the minimum (but probably too minimum) for swap.

Super Advisor
meekrob
Posts: 375
Registered: ‎02-24-2003
Message 5 of 8 (576 Views)

Re: question about swap space

Many Thanks, i did some research about pseudo-swap and tried to understand it :)

As for running crashconf to get an idea about the minimum size of swap to configure,note that it is the case of cold-installation so i am just wondering on how much the swap would be on 12 GB RAM 11iv3 BOE .

 

Regards

Honored Contributor
Patrick Wallek
Posts: 13,784
Registered: ‎06-21-2000
Message 6 of 8 (569 Views)

Re: question about swap space

Something to keep in mind is that your swap area and your dump area (which is what is actually used to store a crash dump in the event of a system crash) do NOT have to be the same.

 

Historically your primary swap is also your dump area.  Now as far as the system goes ALL of your swap areas should be protected by some sort of RAID to (mirroring or RAID5 depending on your disk technology) so that losing a disk will not impact your swap space.

 

Your dump space can be some sort of old, slow disk that is not useful for much else and it does not have to be mirrored.

 

Now, ideally your DUMP space should be the same size as the amount of RAM you have.  However on a running system you can run 'crashconf' to see if your dump space is sufficient and you can always add more.

 

So, short story long!, I would worry less about what happens if/when the system crashes at this point, and just go with 4-6 GB primary swap space.  You can always add some additional space for the dump area later if you determine that it is needed.

 

As far as pseudo-swap goes -- It is kernel book-keeping magic.  The kernel takes a value that is approximately 75% of your RAM (75% of 12 GB is 9GB)  and uses that, in addition to your primary swap space, as additional swap reservation space.  However, it does NOT actually occupy memory, hence the kernel book-keeping magic.  So if you configure 6GB of primary swap + have the 9GB of pseudo-swap, then kernel thinks you have 15 GB of swap space.  (pseudo-swap is reported as the 'memory' line in 'swapinfo -tam')

 

Acclaimed Contributor
Dennis Handly
Posts: 25,274
Registered: ‎03-06-2006
Message 7 of 8 (558 Views)

Re: question about swap space

>and I'd dearly love to find a simple-human explanation of pseudo-swap

 

Which part?  ;-)

It's pretty simple.  Why swap to disk if you can just leave in memory.

So the bookkeeping part is just how much memory you use for pseudo-swap.

 

>The kernel takes a value that is approximately 75% of your RAM

 

I think this different in each HP-UX version.  Or it just depends?

On one 11.23 system, it exactly matches machinfo's value.  On 11.31, it is 15563 vs 16363.

 

Super Advisor
meekrob
Posts: 375
Registered: ‎02-24-2003
Message 8 of 8 (551 Views)

Re: question about swap space

Thanks to all of you

Now i have a clearest idea.

 

Thread considered closed.

 

Regards

The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.