Discussion:
[Beowulf] memory usage
Michael Di Domenico
2018-06-22 17:58:24 UTC
Permalink
does anyone know of a tool that looks at a process
(single/multi-threaded) and tells you how much memory it's using and
in which numa domain the allocated memory is sitting.
_______________________________________________
Beowulf mailing list, ***@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf.org/mailman/listinfo/b
Skylar Thompson
2018-06-22 18:28:29 UTC
Permalink
Assuming Linux, you can get that information out of /proc/<pid>/smaps and
numa_maps.

Skylar
Post by Michael Di Domenico
does anyone know of a tool that looks at a process
(single/multi-threaded) and tells you how much memory it's using and
in which numa domain the allocated memory is sitting.
_______________________________________________
To change your subscription (digest mode or unsubscribe) visit
http://www.beowulf.org/mailman/listinfo/beowulf
Michael Di Domenico
2018-06-22 18:36:57 UTC
Permalink
On Fri, Jun 22, 2018 at 2:28 PM, Skylar Thompson
Post by Skylar Thompson
Assuming Linux, you can get that information out of /proc/<pid>/smaps and
numa_maps.
the memory regions are in there for the used bits, but i don't have
anything that translates those regions to which cpu the region sits on
_______________________________________________
Beowulf mailing list, ***@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit http://www.beowu
Skylar Thompson
2018-06-22 18:44:20 UTC
Permalink
Post by Michael Di Domenico
On Fri, Jun 22, 2018 at 2:28 PM, Skylar Thompson
Post by Skylar Thompson
Assuming Linux, you can get that information out of /proc/<pid>/smaps and
numa_maps.
the memory regions are in there for the used bits, but i don't have
anything that translates those regions to which cpu the region sits on
I think the number before the = in the page count fields (Nn=pages) is the
NUMA node number. Not exactly the CPU, but the memory isn't allocated to a
specific CPU (modulo CPU cache).

Skylar
Michael Di Domenico
2018-06-22 18:48:37 UTC
Permalink
On Fri, Jun 22, 2018 at 2:44 PM, Skylar Thompson
Post by Skylar Thompson
Post by Michael Di Domenico
On Fri, Jun 22, 2018 at 2:28 PM, Skylar Thompson
Post by Skylar Thompson
Assuming Linux, you can get that information out of /proc/<pid>/smaps and
numa_maps.
the memory regions are in there for the used bits, but i don't have
anything that translates those regions to which cpu the region sits on
I think the number before the = in the page count fields (Nn=pages) is the
NUMA node number. Not exactly the CPU, but the memory isn't allocated to a
specific CPU (modulo CPU cache).
ah, spiffy. i glossed right over that in the manpage
_______________________________________________
Beowulf mailing list, ***@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf.org/mailman/l
Lawrence Stewart
2018-06-22 19:05:36 UTC
Permalink
And of course

numactl -H

will tell you which numa nodes are associated with which CPUs, at least down to the socket level.
Post by Michael Di Domenico
On Fri, Jun 22, 2018 at 2:44 PM, Skylar Thompson
Post by Skylar Thompson
Post by Michael Di Domenico
On Fri, Jun 22, 2018 at 2:28 PM, Skylar Thompson
Post by Skylar Thompson
Assuming Linux, you can get that information out of /proc/<pid>/smaps and
numa_maps.
the memory regions are in there for the used bits, but i don't have
anything that translates those regions to which cpu the region sits on
I think the number before the = in the page count fields (Nn=pages) is the
NUMA node number. Not exactly the CPU, but the memory isn't allocated to a
specific CPU (modulo CPU cache).
ah, spiffy. i glossed right over that in the manpage
_______________________________________________
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf.org/mailman/listinfo/beowulf
_______________________________________________
Beowulf mailing list, ***@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit http://www.
Chris Samuel
2018-06-23 04:19:50 UTC
Permalink
Post by Michael Di Domenico
does anyone know of a tool that looks at a process
(single/multi-threaded) and tells you how much memory it's using and
in which numa domain the allocated memory is sitting.
numastat <pid>

For example:

# numastat 54032

Per-node process memory usage (in MBs) for PID 54032 (nbody6.gpu)
Node 0 Node 1 Total
--------------- --------------- ---------------
Huge 0.00 0.00 0.00
Heap 0.00 4.98 4.98
Stack 0.00 0.16 0.16
Private 0.34 940.02 940.37
---------------- --------------- --------------- ---------------
Total 0.34 945.17 945.51

All the best!
Chris
--
Chris Samuel : http://www.csamuel.org/ : Melbourne, VIC

_______________________________________________
Beowulf mailing list, ***@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf.org/mailman/li
Michael Di Domenico
2018-06-25 12:38:15 UTC
Permalink
Post by Chris Samuel
Post by Michael Di Domenico
does anyone know of a tool that looks at a process
(single/multi-threaded) and tells you how much memory it's using and
in which numa domain the allocated memory is sitting.
numastat <pid>
# numastat 54032
Per-node process memory usage (in MBs) for PID 54032 (nbody6.gpu)
Node 0 Node 1 Total
--------------- --------------- ---------------
Huge 0.00 0.00 0.00
Heap 0.00 4.98 4.98
Stack 0.00 0.16 0.16
Private 0.34 940.02 940.37
---------------- --------------- --------------- ---------------
Total 0.34 945.17 945.51
awesome, that's exactly what i was looking for...
_______________________________________________
Beowulf mailing list, ***@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf
Jörg Saßmannshausen
2018-06-24 11:14:32 UTC
Permalink
Hi Michael,

out of curiosity: why do you want to / need to know which in numa domain the
allocated memory is sitting?
I simply try to understand what you are after here.

All the best from a sunny London!

Jörg
Post by Michael Di Domenico
does anyone know of a tool that looks at a process
(single/multi-threaded) and tells you how much memory it's using and
in which numa domain the allocated memory is sitting.
_______________________________________________
To change your subscription (digest mode or unsubscribe) visit
http://www.beowulf.org/mailman/listinfo/beowulf
_______________________________________________
Beowulf mailing list, ***@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf.org/
Michael Di Domenico
2018-06-25 12:35:09 UTC
Permalink
On Sun, Jun 24, 2018 at 7:14 AM, Jörg Saßmannshausen
Post by Jörg Saßmannshausen
out of curiosity: why do you want to / need to know which in numa domain the
allocated memory is sitting?
I simply try to understand what you are after here.
I'm trying to prove that when a process is locked to a domain via some
mechanism, either numactl, mpi binding, etc, that it is in fact only
allocating memory on that domain. It's a trust but verify thing.
_______________________________________________
Beowulf mailing list, ***@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit http://www.beowulf.org/mailman/li
Jörg Saßmannshausen
2018-07-09 22:23:31 UTC
Permalink
Hi Michael,

thanks.

Sorry I am a bit slow with replying right now.

All the best

Jörg
Post by Michael Di Domenico
On Sun, Jun 24, 2018 at 7:14 AM, Jörg Saßmannshausen
Post by Jörg Saßmannshausen
out of curiosity: why do you want to / need to know which in numa domain
the allocated memory is sitting?
I simply try to understand what you are after here.
I'm trying to prove that when a process is locked to a domain via some
mechanism, either numactl, mpi binding, etc, that it is in fact only
allocating memory on that domain. It's a trust but verify thing.
_______________________________________________
To change your subscription (digest mode or unsubscribe) visit
http://www.beowulf.org/mailman/listinfo/beowulf
_______________________________________________
Beowulf mailing list, ***@beowulf.org sponsored by Penguin Computing
To change your subscription (digest mode or unsubscribe) visit http://www.b
Continue reading on narkive:
Loading...