Operating System - HP-UX
1752781 Members
5881 Online
108789 Solutions
New Discussion юеВ

Re: Understanding top and swapinfo command HP-UX

 
4joey1
Occasional Contributor

Understanding top and swapinfo command HP-UX

Hi!I am new to HP-UX having used Linux for several years.When I want to check server performance,I use the top and swapinfo command.In Linux,the results of top were quite easy to understand as it would clearly state the amount of free and used physical and virtual memory.For HP-UX,I am not so sure.If I check the top result below

 

$ top

System: aw1bdvrs                                      Mon Jul 18 08:03:51 2011Load averages: 0.04, 0.05, 0.06516 processes: 472 sleeping, 44 runningCpu states:CPU   LOAD   USER   NICE    SYS   IDLE  BLOCK  SWAIT   INTR   SSYS 0    0.03   7.5%   0.0%   1.0%  91.5%   0.0%   0.0%   0.0%   0.0% 2    0.04   1.0%   0.0%   3.2%  95.8%   0.0%   0.0%   0.0%   0.0% 4    0.05   7.1%   0.0%   4.6%  88.3%   0.0%   0.0%   0.0%   0.0% 6    0.02   0.0%   0.0%   0.0% 100.0%   0.0%   0.0%   0.0%   0.0% 8    0.07   2.0%   0.0%   2.8%  95.2%   0.0%   0.0%   0.0%   0.0%10    0.04   2.8%   0.0%   1.0%  96.2%   0.0%   0.0%   0.0%   0.0%12    0.04   4.8%   0.0%   1.4%  93.8%   0.0%   0.0%   0.0%   0.0%14    0.07   6.3%   0.0%   1.0%  92.7%   0.0%   0.0%   0.0%   0.0%---   ----  -----  -----  -----  -----  -----  -----  -----  -----avg   0.04   4.0%   0.0%   1.8%  94.2%   0.0%   0.0%   0.0%   0.0%
System Page Size: 4KbytesMemory: 13282568K (1729912K) real, 57718252K (5759048K) virtual, 23845192K free Page# 1/104                                                                  
CPU TTY  PID USERNAME PRI NI   SIZE    RES STATE    TIME %WCPU  %CPU COMMAND 2   ? 27474 oracle   154 20 52451M  8192K sleep    1:20  9.71  9.69 ora_j001_pr14   ? 27495 oracle   154 20 52453M  8636K sleep    1:19  8.17  8.16 ora_j004_pr 4   ? 27482 oracle   154 20 52457M  9020K sleep    1:18  6.90  6.89 ora_j002_p74

 

What does

Memory: 13282568K (1729912K) real mean-the value 13282568K and 1729912K represents what part s of physical memory?

Also

57718252K (5759048K) virtual repsesents what values

 

And does

23845192K free represent the amount of free physical memory?

I would like to know from the above figures,which values represents value of free and used physical and virtual memory?

Also,please explain to me the various values of swapinfo shown below

 

$ swapinfo             Kb      Kb      Kb   PCT  START/      KbTYPE      AVAIL    USED    FREE   USED   LIMIT RESERVE  PRI  NAMEdev     8388608    7964 8380644      0%       0       -    1  /dev/vg00/lvol2dev     16777216    8196 16769020    0%       0       -    1  /dev/vg00/swapdev     25165824    7824 25158000    0%       0       -    1  /dev/vg00/swap2dev     20971520    7324 20964196    0%       0       -    1  /dev/vg00/swap1reserve       - 57816448 -57816448memory  63661264 10465664 53195600   16%

 

Thanks. 

7 REPLIES 7
V. Nyga
Honored Contributor

Re: Understanding top and swapinfo command HP-UX

sorted:
$ swapinfo Kb Kb Kb PCT START/ Kb

TYPE AVAIL USED FREE USED LIMIT RESERVE PRI NAME
dev 8388608 7964 8380644 0% 0 - 1 /dev/vg00/lvol2
dev 16777216 8196 16769020 0% 0 - 1 /dev/vg00/swap
dev 25165824 7824 25158000 0% 0 - 1 /dev/vg00/swap2
dev 20971520 7324 20964196 0% 0 - 1 /dev/vg00/swap1
reserve - 57816448 -57816448
memory 63661264 10465664 53195600 16%

*** Say 'Thanks' with Kudos ***
V. Nyga
Honored Contributor

Re: Understanding top and swapinfo command HP-UX

dev is your swap space at disks.
(Why is it all set to pri 1?)
memory is about 70% of your physikal RAM.
(With the option -m you get your space in Mb)

>I would like to know ...
You can use man pages for a first information ('man swapinfo').
Also with a search in this forum I'm sure you'll find very detailed informations about the content.

(More detailed than I can give ...)

V.

*** Say 'Thanks' with Kudos ***
Arunabha Banerjee
Valued Contributor

Re: Understanding top and swapinfo command HP-UX

Please give swapinfo -atm output.

AB
Dennis Handly
Acclaimed Contributor

Re: Understanding top and swapinfo command HP-UX

Do you have a particular problem you are trying to solve?

As mentioned, look at the "swapinfo -tam" output, in particular the "total" line.

JohnFjeldberg
Occasional Advisor

Re: Understanding top and swapinfo command HP-UX

Things I might want to suggest to this thread around looking at memory usage on HP-UX:

 

1) "Memory" in the swapinfo line is "pseudo swap", which is confusing at best. It's set by the kernel and may be anything from 0 up to 1:1 of phy memory

 

2) Top is not the best to use for analysing memory usage. Get hold of the internal kmeminfo tool, and play with the options (e.g. "-user"), or optionally glance:

 

Physical memory usage summary (in page/byte/percent):

Physical memory       =  2092180    8.0g 100%
Free memory           =   672090    2.6g  32%
User processes        =   743712    2.8g  36%  details with -user
System                =   657716    2.5g  31%
  Kernel              =   490342    1.9g  23%  kernel text and data
    Dynamic Arenas    =   309457    1.2g  15%  details with -arena
      vx_global_kmcac =   129804  507.0m   6%
      vx_buffer_kmcac =    41824  163.4m   2%
      spinlock        =    30678  119.8m   1%
      vx_rwsleeplock_ =    18907   73.9m   1%
      vx_ihsm_kmcache =     9470   37.0m   0%
      Other arenas    =    78774  307.7m   4%  details with -arena
    Super page pool   =    19770   77.2m   1%  details with -kas
    Static Tables     =   115488  451.1m   6%  details with -static
      pfdat           =    49035  191.5m   2%
      nbuf            =    24480   95.6m   1%  bufcache headers
      vhpt            =    16384   64.0m   1%
      text            =     8176   31.9m   0%  vmunix text section
      inode           =     4896   19.1m   0%
      Other tables    =    12516   48.9m   1%  details with -static
  Buffer cache        =   167374  653.8m   8%  details with -bufcache
  UFC file mrg        =        0     0.0   0%

 

3) Memory values in TOP tends to be confusing at best, make sure understand the differnce between virtual and real (SIZE/RES) . Second, Top reports on user process only, so looking at my example from kmeminfo above, I"ve got about 2.8Gb in use and 2.6Gb free. The virtual memory usage is higher as it includes e.g. reserved memory in swap.

TOP

Memory: 3047984K (2581944K) real, 5228612K (4562188K) virtual, 2718452K free

 

I hope this may clarify as this is confusing at best in my view.

Dennis Handly
Acclaimed Contributor

Re: Understanding top and swapinfo command HP-UX

>1) "memory" in the swapinfo line is "pseudo memory", which is confusing at best. It's set by the kernel and may be anything from 0 up to 1:1 of phy memory

 

That's pseudo swap and hopefully not 0% of memory.  ;-)

 

>2) top is not the best to use for analyzing memory usage.

 

Right.

JohnFjeldberg
Occasional Advisor

Re: Understanding top and swapinfo command HP-UX

Thanks Dennis, I"ve corrected the 1), it should of course be swap!