<div dir="ltr">Hi,<div><br></div><div>I'd like to use LTTng from within a non-privileged Docker container to perform</div><div>user-space tracing (enable-event --userspace --tracepoint etc.). Specifically,</div><div>I would like to trace a .NET Core application, which uses LTTng events to trace</div><div>GC, JIT, assembly loading, and other events. My testing environment is a FC25</div><div>host with an Ubuntu 14.04 container.</div><div><br></div><div>I can install LTTng within the target container, but the session daemon produces</div><div>the following message while loading:</div><div><br></div><div><div>modprobe: ERROR: ../libkmod/libkmod.c:556 kmod_search_moddep() could</div><div>not open moddep file '/lib/modules /4.12.9-200.fc25.x86_64/modules.dep.bin'</div><div>Error: Unable to load module lttng-tracer</div><div>DEBUG1 [1830/1830]: Failed to open /proc/lttng (in init_kernel_tracer() at main.c:2382)</div><div>Error: Unable to remove module lttng-tracer</div><div>Warning: No kernel tracer available</div></div><div><br></div><div>Subsequent commands seem to work, but there are no traces produced. </div><div>What I ran was:</div><div><br></div><div>lttng create mysession --output /tmp</div><div>lttng enable-event --userspace --tracepoint DotNETRuntime:GC*</div><div>lttng start</div><div>lttng stop</div><div>lttng destroy</div><div><br></div><div>Is there a way to use the LTTng session daemon in non-privileged mode,</div><div>if I'm only interested in userspace tracing? I would like to avoid installing</div><div>LTTng on the host system, or running privileged. In fact, the ideal workflow<br></div><div>for me is to have a separate container image with LTTng and "attach" that </div><div>container image (using docker --pid --net) to the target container that I want</div><div>to analyze. But I'd settle for having LTTng in the target container if that's the</div><div>only option.</div><div><br></div><div>By the way, running LTTng from the host when the target application is in a</div><div>container doesn't work either (i.e. no traces are produced). Running LTTng</div><div>from the host when the target application is also on the host produces</div><div>results successfully.</div><div><br></div><div>Any suggestions would be very much appreciated.</div><div><br></div><div>Thanks,</div><div>Sasha</div></div>