The pmap command (included with procps rpm packages) reports the amount of memory that one or more processes are using. You can use this tool to determine which processes on the server are being allocated memory and whether this amount of memory is a cause of memory bottlenecks and it is also very useful for the administrators to find which of the libary/file is eating more memory on that pid (use pidof <program-name> to find the list of pid )
- # pmap <pid>
To show in device format.
- # pmap -d <pid>
A sample screen-caps below.
Some of the most important information is at the bottom of the display. The line shows:
mapped: Total amount of memory mapped to files used in the process
writable/private: The amount of private address space this process is taking
shared: The amount of address space this process is sharing with others
Use pmap -? to list the help menu.
-x extended Show the extended format.
-d device Show the device format.
-q quiet Do not display some header/footer lines.
-V show version Displays version of program.