[lttng-dev] Enable/disable TPs per executing process

Stanislav Vovk stanislav.vovk at ericsson.com
Mon Mar 5 04:52:41 EST 2012


Hi

In my case LTTng will collect TPs from a number of running processes. I 
would like to enable/disable tracepoints per process. For example, two 
processes p1 & p2 running and there exist a tracepoint called INFO which 
is used in both p1 and p2. I would like to enable INFO for p1 only. So 
later, looking at my traces I should only see INFO triggered by p1 and 
nothing from p2. Is there a way to do like that?

I was thinking to enable one channel per process and and then I could 
enable/disable tracepoints per channel. Can a channel be associated with 
a process?

In LTTng control API I found a following function,

/*
  * Set the tracing group for the *current* flow of execution.
  *
  * On success, returns 0, on error, returns -1 (null name) or -ENOMEM.
  */
extern int lttng_set_tracing_group(const char *name);

I dont really understand how and where I can use these tracing groups? 
Is this something that I can use in the above scenario?

Thanks!
-- 

Stanislav Vovk                   Phone: +46 107151937
TN/EAB/FJB/DLM (SE KI30 05 467)  SMS:   +46 761153432
Ericsson AB
Färögatan 2-6, 164 56 Kista, Sweden




More information about the lttng-dev mailing list