Java Linux Memory: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
(Created page with "=Internal= * Linux Memory Management * Linux Process Information =Information on how Much Physical Memory a JVM Uses= Once you have the PID, you can look in: <pre>...")
 
 
(5 intermediate revisions by the same user not shown)
Line 3: Line 3:
* [[Linux Memory Management]]
* [[Linux Memory Management]]
* [[Linux Process Information]]
* [[Linux Process Information]]
* [[Java_Memory_Concepts#Non-Heap_Memory|Java Memory Concepts &#124; Non-Heap Memory]]


=Information on how Much Physical Memory a JVM Uses=
=Information on how Much Physical Memory a JVM Uses=
Line 12: Line 13:
</pre>
</pre>


Per the documentation:
For a description of the fields, see: {{Internal|Linux_Process_Information#.2Fproc.2F.3CPID.3E.2Fstatus|/proc/<PID>/status}}
 
* VmPeak: Peak virtual memory size.
 
* VmSize: Virtual memory size.
 
* VmLck: Locked memory size.
 
* VmHWM: Peak resident set size ("high water mark").
 
* VmRSS: Resident set size.
 
* VmData, VmStk, VmExe: Size of data, stack, and text segments.
 
* VmLib: Shared library code size.
 
* VmPTE: Page table entries size (since Linux 2.6.10).
 
* Threads: Number of threads in process containing this thread.


=More Info=
=More Info=
Line 38: Line 21:
=Script=
=Script=


{{{
<blockquote style="background-color: AliceBlue; border: solid thin LightSteelBlue;">
C:\c054-CGI\ec\src\ec-scripts-trunk\misc\jboss-os-memory-stats.sh
:https://github.com/NovaOrdis/shell-tools/blob/master/jboss-os-memory-stats.sh<br>
}}}
</blockquote>

Latest revision as of 04:00, 29 December 2020

Internal

Information on how Much Physical Memory a JVM Uses

Once you have the PID, you can look in:

/proc/<PID>/status

For a description of the fields, see:

/proc/<PID>/status

More Info

"man proc" has a ton of information we can pull.

Script

https://github.com/NovaOrdis/shell-tools/blob/master/jboss-os-memory-stats.sh