<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic another discussion on memory usage in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906285#M106166</link>
    <description>Hi all,&lt;BR /&gt;&lt;BR /&gt;I remember there're some discussion on memory usage last week, I have a similar situation here which kind of confusing me. On one of my dev server(HPUX11.0), we have 2GB memory, /usr/contrib/Q4/bin/kmeminfo shows the following:&lt;BR /&gt;Physical memory usage summary (in pages):&lt;BR /&gt;&lt;BR /&gt;Physmem        =  524288  Available physical memory:&lt;BR /&gt;  Freemem      =   14933    Free physical memory&lt;BR /&gt;  Used         =  509355    Used physical memory:&lt;BR /&gt;    System     =  234215      by kernel:&lt;BR /&gt;      Static   =   20312        for text and static data&lt;BR /&gt;      Dynamic  =  135260        for dynamic data&lt;BR /&gt;      Bufcache =   78643        for file-system buffer cache&lt;BR /&gt;    User       =  277644      by user processes&lt;BR /&gt;      Uarea    =    5848        for thread uareas&lt;BR /&gt;    Disowned   =    1024      disowned pages&lt;BR /&gt;&lt;BR /&gt;it tells me that user process consumed 277k pages( more that 1.1GB) memory.&lt;BR /&gt;&lt;BR /&gt;but using UNIX95= ps -e -o 'vsz ruser' | grep -v VSZ | grep -v root|awk '{ sum += $1 } END { printf "%ld\n",  sum }' the result is only 683368KB. &lt;BR /&gt;&lt;BR /&gt;Note that I was getting 'vsz' of the process, but still there're about 500MB user process memory difference un-account for.  &lt;BR /&gt;&lt;BR /&gt;what may cause this? BTW, we don't have Glance on this server.&lt;BR /&gt;&lt;BR /&gt;any idea is greatly welcomed.&lt;BR /&gt;&lt;BR /&gt;thanks,&lt;BR /&gt;Gary</description>
    <pubDate>Mon, 17 Feb 2003 17:16:27 GMT</pubDate>
    <dc:creator>Gary Yu</dc:creator>
    <dc:date>2003-02-17T17:16:27Z</dc:date>
    <item>
      <title>another discussion on memory usage</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906285#M106166</link>
      <description>Hi all,&lt;BR /&gt;&lt;BR /&gt;I remember there're some discussion on memory usage last week, I have a similar situation here which kind of confusing me. On one of my dev server(HPUX11.0), we have 2GB memory, /usr/contrib/Q4/bin/kmeminfo shows the following:&lt;BR /&gt;Physical memory usage summary (in pages):&lt;BR /&gt;&lt;BR /&gt;Physmem        =  524288  Available physical memory:&lt;BR /&gt;  Freemem      =   14933    Free physical memory&lt;BR /&gt;  Used         =  509355    Used physical memory:&lt;BR /&gt;    System     =  234215      by kernel:&lt;BR /&gt;      Static   =   20312        for text and static data&lt;BR /&gt;      Dynamic  =  135260        for dynamic data&lt;BR /&gt;      Bufcache =   78643        for file-system buffer cache&lt;BR /&gt;    User       =  277644      by user processes&lt;BR /&gt;      Uarea    =    5848        for thread uareas&lt;BR /&gt;    Disowned   =    1024      disowned pages&lt;BR /&gt;&lt;BR /&gt;it tells me that user process consumed 277k pages( more that 1.1GB) memory.&lt;BR /&gt;&lt;BR /&gt;but using UNIX95= ps -e -o 'vsz ruser' | grep -v VSZ | grep -v root|awk '{ sum += $1 } END { printf "%ld\n",  sum }' the result is only 683368KB. &lt;BR /&gt;&lt;BR /&gt;Note that I was getting 'vsz' of the process, but still there're about 500MB user process memory difference un-account for.  &lt;BR /&gt;&lt;BR /&gt;what may cause this? BTW, we don't have Glance on this server.&lt;BR /&gt;&lt;BR /&gt;any idea is greatly welcomed.&lt;BR /&gt;&lt;BR /&gt;thanks,&lt;BR /&gt;Gary</description>
      <pubDate>Mon, 17 Feb 2003 17:16:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906285#M106166</guid>
      <dc:creator>Gary Yu</dc:creator>
      <dc:date>2003-02-17T17:16:27Z</dc:date>
    </item>
    <item>
      <title>Re: another discussion on memory usage</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906286#M106167</link>
      <description>the format of the output of kmeminfo is messed up, I put it in attachment</description>
      <pubDate>Mon, 17 Feb 2003 17:19:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906286#M106167</guid>
      <dc:creator>Gary Yu</dc:creator>
      <dc:date>2003-02-17T17:19:58Z</dc:date>
    </item>
    <item>
      <title>Re: another discussion on memory usage</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906287#M106168</link>
      <description>Hi Gary,&lt;BR /&gt;&lt;BR /&gt;The command you are running is excluding all processes owned by root, hence here is probably where the shortfall is. &lt;BR /&gt;&lt;BR /&gt;Remember root is just another user, albeit with special privileges, so many of the processes owned by it will contribute to user memory usage.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;James.</description>
      <pubDate>Mon, 17 Feb 2003 17:49:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906287#M106168</guid>
      <dc:creator>James Murtagh</dc:creator>
      <dc:date>2003-02-17T17:49:03Z</dc:date>
    </item>
    <item>
      <title>Re: another discussion on memory usage</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906288#M106169</link>
      <description>Hi James,&lt;BR /&gt;&lt;BR /&gt;thanks for the reply, I guess I should include root, but with root, the result from UNIX95 ps is still only 795820KB&lt;BR /&gt;&lt;BR /&gt;Gary</description>
      <pubDate>Mon, 17 Feb 2003 18:05:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906288#M106169</guid>
      <dc:creator>Gary Yu</dc:creator>
      <dc:date>2003-02-17T18:05:07Z</dc:date>
    </item>
    <item>
      <title>Re: another discussion on memory usage</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906289#M106170</link>
      <description>Hi Gary,&lt;BR /&gt;&lt;BR /&gt;Maybe this example will help. I've taken a process at random (well, almost at random - one with shared memory usage) and used different methods of checking its memory:&lt;BR /&gt;&lt;BR /&gt;# ps -el|grep 1674&lt;BR /&gt;2001 S         30  1674  1662  0 154 20         42b25800  322         42ae44e8 ?         0:00 httpd&lt;BR /&gt;&lt;BR /&gt;*322 is the RSS - equal to real text+data+stack in the next example.&lt;BR /&gt;&lt;BR /&gt;# UNIX95= ps -e -o 'vsz ruser' -o 'pid'|grep 1674&lt;BR /&gt;   2656 www       1674&lt;BR /&gt;&lt;BR /&gt;# ./procmem 1674                         &lt;BR /&gt;&lt;BR /&gt;Memory usage for process 1674:&lt;BR /&gt;&lt;BR /&gt;Real Pages Text : 167&lt;BR /&gt;Real Pages Data : 147&lt;BR /&gt;Real Pages Stack : 8&lt;BR /&gt;Real Pages Shared Memory : 47&lt;BR /&gt;Real Pages Memory Mapped : 1041&lt;BR /&gt;Real Pages U-Area + Kernel Stack : 8&lt;BR /&gt;Real Pages I/O mapping : 0&lt;BR /&gt;&lt;BR /&gt;Resident Set Size : 352&lt;BR /&gt;&lt;BR /&gt;Virtual Pages Text : 497&lt;BR /&gt;Virtual Pages Data : 159&lt;BR /&gt;Virtual Pages Stack : 8&lt;BR /&gt;Virtual Pages Shared Memory : 303&lt;BR /&gt;Virtual Pages Memory Mapped : 1412&lt;BR /&gt;Virtual Pages U-Area + Kernel Stack : 8&lt;BR /&gt;Virtual Pages I/O mapping : 0&lt;BR /&gt;&lt;BR /&gt;So you can see the total from the UNIX95 command is the virtual text+data+stack. ((497+159+8)*4096)/1024. It doesn't include shared memory or mapped areas. &lt;BR /&gt;&lt;BR /&gt;procmem is just a program I wrote myself using the pstat interface, see "man pstat" for a full description.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;BR /&gt;James.</description>
      <pubDate>Mon, 17 Feb 2003 18:38:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906289#M106170</guid>
      <dc:creator>James Murtagh</dc:creator>
      <dc:date>2003-02-17T18:38:39Z</dc:date>
    </item>
    <item>
      <title>Re: another discussion on memory usage</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906290#M106171</link>
      <description>Hi, Gary!&lt;BR /&gt;&lt;BR /&gt;I need to take care to compare apple with apples.&lt;BR /&gt;&lt;BR /&gt;Your kmeminfo output reports a physical memory statistic. So you cannot compare that with the vsz metric of ps(1), since this is a virtual memory metric.&lt;BR /&gt;&lt;BR /&gt;OK, you could use ps' rz metric...&lt;BR /&gt;&lt;BR /&gt;UNIX95= ps -e -o sz= | awk '{x=x+$1} END {print x*4}'&lt;BR /&gt;&lt;BR /&gt;But here you have the problem that it does not consider the reference counts, causing pages of shared objects to be counted  more than once.&lt;BR /&gt;&lt;BR /&gt;Check if your kmeminfo version supports the -user option. This  should give you a really precise stat.&lt;BR /&gt;&lt;BR /&gt;Best regards...&lt;BR /&gt; Dietmar.</description>
      <pubDate>Mon, 17 Feb 2003 18:42:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906290#M106171</guid>
      <dc:creator>Dietmar Konermann</dc:creator>
      <dc:date>2003-02-17T18:42:05Z</dc:date>
    </item>
    <item>
      <title>Re: another discussion on memory usage</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906291#M106172</link>
      <description>Dear James,&lt;BR /&gt;&lt;BR /&gt;Could you share the procmem program with me?&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 05 Jun 2003 02:34:01 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/another-discussion-on-memory-usage/m-p/2906291#M106172</guid>
      <dc:creator>System Dude_1</dc:creator>
      <dc:date>2003-06-05T02:34:01Z</dc:date>
    </item>
  </channel>
</rss>

