[lttng-dev] Enable UST probes only in specific process

Jérémie Galarneau jeremie.galarneau at efficios.com
Thu Jul 31 17:27:42 EDT 2014

On Thu, Jul 31, 2014 at 4:14 PM, Thibault, Daniel
<Daniel.Thibault at drdc-rddc.gc.ca> wrote:
> ----------------------------------------------------------------------
> Date: Thu, 31 Jul 2014 14:15:01 -0400
> From: Jérémie Galarneau <jeremie.galarneau at efficios.com>
> To: Dmitri Shubin <sbn at tbricks.com>
>>>> The arguments won't be evaluated if the event is not enabled.
>>>> However, when an event is enabled, the arguments are evaluated
>>>> regardless of the result of the filter's expression evaluation since
>>>> it could be based on the event's content.
>>> Yes, exactly.
>>> I pass stack trace as an argument to the tracepoint.
>>> So it's computed just to be dropped...
>>> [...]
>>> I.e. here I have separate session per each process I want to trace.
>>> It would be easier if I can have channel per process, like e.g.
>>> $ lttng enable-channel -p 12345
>>> For instance in dtrace I can explicitly specify process I want to
>>> trace by appending its PID to probe name.
>> You'll be glad to learn that we'll be adding this feature by the end of the year. Probably within the 2.7 release timeframe.
> Once this feature is in place, it will mean the tracepoint arguments get evaluated only if the candidate event passes the PID "pre-filter", right?  Will we be able to set the pre-filter to PID ranges or sets of values?  I suppose there will be similar filtering options with regard to user IDs?

I don't think it will involve a pre-filter stage. It will most likely
work by having the session daemon enable the probe in a single process
and not communicating the enable-event message to the others.

As far as the ability to provide a range or a list of PIDs or other
such options, I'm not really involved in the development of this
feature so I don't really know for sure... It's certainly a legitimate
use case.

David will be working on this feature so I'm sure the feedback will
prove useful.


> Daniel U. Thibault
> Protection des systèmes et contremesures (PSC) | Systems Protection & Countermeasures (SPC)
> Cyber sécurité pour les missions essentielles (CME) | Mission Critical Cyber Security (MCCS)
> RDDC - Centre de recherches de Valcartier | DRDC - Valcartier Research Centre
> 2459 route de la Bravoure
> Québec QC  G3J 1X5
> Vox : (418) 844-4000 x4245
> Fax : (418) 844-4538
> NAC : 918V QSDJ <http://www.travelgis.com/map.asp?addr=918V%20QSDJ>
> Gouvernement du Canada | Government of Canada
> <http://www.valcartier.drdc-rddc.gc.ca/>

Jérémie Galarneau
EfficiOS Inc.

More information about the lttng-dev mailing list