[lttng-dev] babeltrace

Jessica Foest jessica.foest at gmail.com
Tue May 13 15:27:44 EDT 2014


Thanks a lot Jérémie :)


2014-05-13 14:48 GMT-04:00 Jérémie Galarneau <jeremie.galarneau at efficios.com
>:

> Hi Jessica,
>
> I suggest you start by looking at this example in Babeltrace's
> tree[1]. These will show you how to read a CTF trace's events from a
> Python script.
>
> As for formatting the events as CSV, there is a section dedicated to
> this topic in Python's documentation [2].
>
> Regards,
> Jérémie
>
> [1]
> https://bugs.lttng.org/projects/babeltrace/repository/revisions/master/entry/bindings/python/examples/example-api-test.py
> [2] https://docs.python.org/3.4/library/csv.html
>
> On Mon, May 12, 2014 at 7:24 PM, Jessica Foest <jessica.foest at gmail.com>
> wrote:
> > Thanks for your detailed responses :)
> > Actually i will begin by taking my own trace that i will configure it in
> > advance ( same event type , and i will add the different event context
> that
> > i need ) .
> > It's my first time to develop with python and i don't really know the
> > architecture of babeltrace , So can you help me and tell me how to
> proceed
> > to filter my data from CTF to the output Format that i will choose ?
> > I'm only interested on kernel space tracing .
> >
> >
> > 2014-05-08 17:29 GMT-04:00 Jessica Foest <jessica.foest at gmail.com>:
> >
> >> i work only on kernel space event .
> >>
> >>
> >> 2014-05-08 17:10 GMT-04:00 Jessica Foest <jessica.foest at gmail.com>:
> >>
> >>> Thanks for your detailed responses :)
> >>> Actually i will begin by taking my own trace that i will configure it
> in
> >>> advance ( same event type , and i will add the different event context
> that
> >>> i need ) .
> >>> It's my first time to develop with python and i don't really know the
> >>> architecture of babeltrace , So can you help me and tell me how to
> proceed
> >>> to filter my data from CTF to the output Format that i will choose ?
> >>>
> >>>
> >>> 2014-05-08 11:53 GMT-04:00 Alexandre Montplaisir
> >>> <alexmonthy at voxpopuli.im>:
> >>>
> >>>>
> >>>>> To avoid doing a complete first pass of the trace, you can just
> >>>>> iterate on the event types as described in the metadata, and take
> note
> >>>>> of all the possible field you can find in the trace. Then, during
> your
> >>>>> only pass, you already know all your "columns".
> >>>>
> >>>>
> >>>> That's true. Although right now TMF doesn't have an API to ask a trace
> >>>> "give me all the event types you have", other than just reading the
> trace ;)
> >>>>
> >>>> wrt CTF, it's possible to have events in the metadata that don't
> >>>> actually show up in the trace. But that's not really a problem, at
> worst
> >>>> you'd end up with empty columns.
> >>>
> >>>
> >>
> >
>
>
>
> --
> Jérémie Galarneau
> EfficiOS Inc.
> http://www.efficios.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20140513/5e6d3774/attachment.html>


More information about the lttng-dev mailing list