1833778 Members
2401 Online
110063 Solutions
New Discussion

swap space

 
Anh-Thu Tran
Frequent Advisor

swap space

Why there is the difference between the swap space info if I use swapinfo and sam.
For swapinfo command, my system shows:
swapinfo -m
Mb Mb Mb PCT START/ Mb
TYPE AVAIL USED FREE USED LIMIT RESERVE PRI NAME
dev 4096 1619 2477 40% 0 - 1 /dev/vg00/lvol2
reserve - 2451 -2451
memory 6310 4404 1906 70%

Look like it has 2G swap free. While sam (under system properties) shows: Avail 4096Mb, Used 3878 MB, free 218mb.
10 REPLIES 10
Rick Garland
Honored Contributor

Re: swap space

The SAM output you posted is not displaying the swap area.
baiju_3
Esteemed Contributor

Re: swap space

Hi ,

use swapinfo -tam

This will give you % util per device and total utilisation .

Thanks,
BL.
Good things Just Got better (Plz,not stolen from advertisement -:) )
Anh-Thu Tran
Frequent Advisor

Re: swap space

So look like swapinfo will show you how the swap space get allocate in the system. How can I interpret the swap space shows in Sam? What is it?
Anh-Thu Tran
Frequent Advisor

Re: swap space

This is how I get the swap info on Sam:
Sam - Performance Monitor - system properties - Memory tab. This info here is different than the info by using swapingo command.
DCE
Honored Contributor

Re: swap space

You might want to get your swap info from Glance - it does a very good, and accurate job.

Devender Khatana
Honored Contributor

Re: swap space

Hi,

As suggested above please post swapinfo -atm output, as it will provide details for memory and swap seperately.

Here you are getting 1906 MB free out of SWAP+Memory (4+2=6GB) whereas swap is giving details of only virtual memory i.e. swap (4GB).

HTH,
Devender
Impossible itself mentions "I m possible"
Anh-Thu Tran
Frequent Advisor

Re: swap space

I want to know how swap space allocate because the machine only allows us to run up to 4 same executables from different users. The next user (the fifth one) will get errno 12 (ENOMEM - not enough core). HP suggested us to increase swap space or define the secondary swap space. However, we monitor the swap space (without increase or adding the secondary swap space) by running swapinfo whenever 1 or 4 executables running, the swap space does not change. We just wonder there are any parameters that limit the number of particular process running?
Andrew Rutter
Honored Contributor

Re: swap space

hi,

I think your getting a little confused about the two items swap and physical memory
in the output you have it shows 4gb swap on dev/vg00/lvol2
and bottom figure 6gb physical memory

In sam this is also be the same

ie 4096mb swap used 3878mb and free 218mb

if you look at the physical memory amount on same sam page you will see this is 6gb.

you only have 30% free of physical mem and 60% swap free.

It is normal to only have 4gb primary swap as a maximum amount and that is why you then need to add secondry swap.

It would be interesting to know what apps/exec are wanting this amnount of memory and how heavily loaded the system is. Also what version of hpux is runnimng and patch level. there are some patches available for erno errors and large apps?

looks like you could do with adding more ram though to ease the load

Andy

Al Langen_1
Advisor

Re: swap space

Anh-Thu,

My experiences with RAM and swap show that the kernel will partition Virtual Memory such that memory for RAM will not exceed memory for swap and the remaining RAM will be included as swap with one condition: after these RAM swap chunks have been freed by a program, they are either too fragmented to become useful or are just not available until after re-boot.

I would like to hear from the HP memory management engineers regarding memory management:

HP-UX Memory Management
White Paper
Version 1.4
5965-4641

Last modified September 22, 2000

Alf
Ted Buis
Honored Contributor

Re: swap space

SAM is showing the amount of physical device swap space. From your output, it would appear that you have Psuedoswap enabled in the kernel. There is very good information in the book by Chris Cooper on HP-UX 11i Internals on how pseudo-swap works, but my interpretation is that it locks pages of RAM into memory thus eliminating the need for corresponding device swap space. This has the effect of allowing smaller device swap files, and is intended for large memory configurations were it is unlikely that page-outs will occur. So with Psuedoswap enabled, your virtual memory address space is equal to the device swap plus the lockable pages of RAM.
Mom 6