Re: Memory Consumption High After Upgrading to 2.13 from 2.10

Kienan Stewart via lttng-dev <[email protected]> Tue, 11 Mar 2025 14:55:21 -0400
Newsgroups org.lttng.lists.lttng-dev
Message-ID <[email protected]>
Hi Lakshya,

On 3/11/25 12:25 PM, Gour DEV wrote:
 > Hi, Kienan
 >
 > here is the requested output
 >
 > root@localhost:~# top -b -n 1 | grep  lttng
 >     4841 root      20   0   11.5g  11.0g  11.0g S   5.9  35.4   8:39.93
 > lttng-c+
 >     4824 root      20   0 1098824  26456   5380 S   0.0   0.1   0:07.25
 > lttng-s+
 >     4825 root      20   0   48872   2188   1012 S   0.0   0.0   0:00.00
 > lttng-r+
 >     4843 root      20   0    3680   1160    816 S   0.0   0.0   0:00.23

This top output for `localhost` seems very different than the output for 
`localhost` in your previous message.


 > lttng-r+
 > root@localhost:~# nrpco
 > bash: nrpco: command not found
 > root@localhost:~# nproc
 > 16
 > root@localhost:~# cat /sys/devices/system/cpu/possible
 > 0-15
 >

You indicated the bookworm machine has 32 cores, this is showing 16. If 
you're comparing a 16 core machine to a 32 core machine, it is very 
normal that the memory usage is higher on the 32 core machine.

 >
 > Most of the process are running as asorcs user but some are running 
as root.

So you have two users with instrumented applications.


Given the discrepancies in the information provided I'm finding it a bit 
hard to understand what you're looking at.


In general, a channel's shared memory footprint can be estimated with[1]:

   (nSubbuf * subbufSize) * (nCPUs + 1 iff snapshot mode is enabled) * 
(nUIDs or nPIDs)

Note that the sub-buffer sizes you are using get rounded to the nearest 
larger power of 2. See [2].

thanks,
kienan

[1]: https://lttng.org/docs/v2.13/#doc-channel-buffering-schemes
[2]: 
https://lttng.org/man/1/lttng-enable-channel/v2.13/#doc-opt--subbuf-size