?
Solved

Virtual Memory under top shows 10x higher on 2.6 kernel then on 2.4

Posted on 2006-05-08
4
Medium Priority
?
838 Views
Last Modified: 2013-12-16
Hi, I am comparing how an application runs on a 2.6 kernel (redhat EL4.3) to how it runs on a 2.4 kernel (redhat 7.3).  Using the ps command I see similar results in the SIZE column; however, using the top command I see a huge difference in the VIRT column.  The RES and SHR are about the same between 2.4 and 2.6, but the VIRT is 10 times higher in the 2.6 kernel (2.4 = 4800,  2.6= 41000).
I have the same top version (procps-3.2.3-8.3).  My guess is that teh VIRT in 2.4 is not working...?  I want to 100% sure that the application does not actually behave badly in 2.6... Thanks
0
Comment
Question by:medent
  • 2
  • 2
4 Comments
 
LVL 15

Expert Comment

by:DonConsolio
ID: 16635927
try using pmap to get "real" memory usage info.

e.g.
# pmap -d PID_OF_PROCESS
Address   Kbytes Mode  Offset           Device    Mapping
08048000     456 r-x-- 0000000000000000 068:00001 bash
080ba000      12 rw--- 0000000000071000 068:00001 bash
[...]
bfffa000      24 rw--- 00000000bfffa000 000:00000   [ stack ]
ffffe000       4 ----- 0000000000000000 000:00000   [ anon ]
mapped: 3096K    writeable/private: 612K    shared: 24K

0
 

Author Comment

by:medent
ID: 16639125
Thanks. Here is the output.  Pmap looks the same on both (2.4 and 2.6), so top/VIRT on 2.4 is not accurate.  Can I derive from this output the real physical memory in use?

[root@testvx root]# pmap -x 27977
27977:   winmed_v15.26 -I194.0.0.250 -NPAULM-XP  -S5 -P11401 -R2 -TSun_May_07_09
:23:55_2006434  -B15
Address   Kbytes     RSS    Anon  Locked Mode   Mapping
08048000   26824       -       -       - r-x--  winmed_v15.26
09a7a000     512       -       -       - rw---  winmed_v15.26
09afa000   11368       -       -       - rwx--    [ anon ]
40007000      40       -       -       - r-x--  libnss_files-2.3.2.so
40011000       4       -       -       - rw---  libnss_files-2.3.2.so
40012000    1160       -       -       - r-x--  libc-2.3.2.so
40134000      24       -       -       - rw---  libc-2.3.2.so
4013a000       8       -       -       - rw---    [ anon ]
4013c000      72       -       -       - r-x--  ld-2.3.2.so
4014e000       4       -       -       - rw---  ld-2.3.2.so
bffed000      76       -       -       - rwx--    [ stack ]
-------- ------- ------- ------- -------
total kB   40092       -       -       -
0
 
LVL 15

Accepted Solution

by:
DonConsolio earned 2000 total points
ID: 16642383
"pmap -d" gives better info for your question
it shows shared (used by several apps) and private (used only by your process) memory
0
 

Author Comment

by:medent
ID: 16647430
perfect- thanks.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Over the last ten+ years I have seen Linux configuration tools come and go. In the early days there was the tried-and-true, all-powerful linuxconf that many thought would remain the one and only Linux configuration tool until the end of times. Well,…
In part one, we reviewed the prerequisites required for installing SQL Server vNext. In this part we will explore how to install Microsoft's SQL Server on Ubuntu 16.04.
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses
Course of the Month15 days, 10 hours left to enroll

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question