Re: Boot-time flight recording

Mathieu Desnoyers <[email protected]>
Newsgroups gmane.linux.kernel.tracing
Message-ID <20061108153722.GH4257@Krystal>
* Deepak Saxena ([email protected]) wrote:
> 
> Mathieu, 
> 
> One of the features that MontaVista added to our internal LTT codebase
> was support for boot-time flight recording, meaning that we would
> start collecting traces as soon as the sytem could possibly do it, before
> init started. I don't think that LTTng supports this but wanted
> to see if this is in your plans for features to add.
> 

Hi Deepak,

Yes, it is in our plans, but not in the roadmap yet (just added). I try
to design LTTng so that it will be easy to do the boot time tracing once
ready by creating a kernel module (configurable built-in) that has one
static buffer per cpu, for each channel (size selectable at compile time).

We will then have to find the best way to connect these buffers with
debugfs so the ioctls, the poll and the mmap can get its information.

These boot time buffers must be put in the "trace list" so the probes
can write to it. I am thinking of an atomic update scheme to switch
from the boot-time buffer to a "normal" relay+debugfs trace that could
be provided by list_replace_rcu : this way, we can put the tracefiles
from both traces inside the same trace directory and view them as one
trace, with no overlapping events. Note that the facility channel will
be a duplicate. The safest way to do it is to only keep the facility
channel from the second trace, which will contain all the facilities
from the first trace too if no facility unregistration has been
performed. Also note that it is useless to start a statedump for the
second "normal" trace.


Mathieu


> ~Deepak
> 
> -- 
> Deepak Saxena - [email protected] - http://www.plexity.net
> 
> "An open heart has no possessions, only experiences" - Matt Bibbeau
> 
OpenPGP public key:              http://krystal.dyndns.org:8080/key/compudj.gpg
Key fingerprint:     8CD5 52C3 8E3C 4140 715F  BA06 3F25 A8FE 3BAE 9A68
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.