[lttng-dev] Need help in converting trace data into CTF

Jonathan Rajotte-Julien jonathan.rajotte-julien at efficios.com
Wed Jun 19 13:10:57 EDT 2019


Hi,

>  I want to make babeltrace read my metadata file and event stream stored in
> a file. How does babeltrace read an arbitrary CTF session(CTF+event stream)?

Babeltrace traverses the tree and look for files named "metadata"
. All files at the same depth of a metadata file are considered CTF streams.

e.g:
   /tmp/
       my-trace/
           another_dir/
               abcd
               efgh
               metadata

babeltrace /tmp/my-trace/

The files "abcd" and "efgh" will be considered stream files and babeltrace will
try to read them.

You can have hidden file (".abcd") at the same depth, they will not be
considered.

> 
> What should be the file format to store the event stream? I will use
> fwrite() to store the events.

The CTF format.

Cheers

-- 
Jonathan Rajotte-Julien
EfficiOS


More information about the lttng-dev mailing list