commands

pmap — Inspect process memory mappings

Report mappings for a permitted process. The default total is virtual mapping size, not unique resident memory. Extended columns vary by version. Use a fresh private workspace; No production workload is required.

Formal Syntax & Structure

linux syntaxlinux
pmap PID

Parameters & Attributes

NameTypeDescription
PIDoperandNumeric ID of an accessible, authorized process.

Return Value

exit status and output

Reports mappings for the specified process, subject to procfs access and process lifetime. Inspect the returned mappings and diagnostic status; mapped virtual sizes are not the same as resident memory usage.

Working Example

Example Snippetlinux
pmap "$$" | grep -Eq '^ total +[0-9]+K' && printf 'mapping total present\n'
Linux Reference