1

For example, I have:

 % grep '^Mapped:' /proc/meminfo
Mapped:           121868 kB

I want to generate something like this:

PID       Mapped        Path
123       1234 kB       /lib/libX.so
234       23445 kB      /bin/bash
...
TOTAL     121868 kB

So that, TOTAL is the same number from /proc/meminfo. I looked thought /proc/<pid>/smaps, but not sure what exactly fields should I sum in order to get correct TOTAL.

grygorii
  • 11
  • 1

1 Answers1

0

Take a look at pmap. It should report the memory map of a process

NinjaGaiden
  • 3,046
  • 6
  • 28
  • 49
  • It does report. pmap reads /proc//maps and shows it in its own manner. But, how I can get a `Mapped:` number from `/proc/meminfo`? – grygorii Feb 24 '17 at 07:04