Mirror of the lttng-dev mailing list
 help / color / mirror / Atom feed
* [lttng-dev] lttng-ust quick start?
@ 2013-01-11 22:12 Thibault, Daniel
  2013-01-11 22:45 ` Christian Babeux
  0 siblings, 1 reply; 4+ messages in thread
From: Thibault, Daniel @ 2013-01-11 22:12 UTC (permalink / raw)



   I have this Ubuntu 12.04 machine with the lttng-tools suite installed, and I now want to quickstart userspace tracing.  Starting at http://lttng.org/quickstart, we're told succinctly that we need to instrument the target application (details in the lttng-ust(3) manpage) and then do the actual tracing (Userspace Tracing section of the lttng-tools wiki page).  Fair enough.  But the lttng-ust(3) manpage is off to a rocky start.

   The first thing we're told is " to use the lttng-gen-tp(1) tool. See the lttng-gen-tp(1) manpage for explanation."  The catch here is that lttng-gen-tp is NOT part of the basic lttng-tools installation.  The manpage should explain (briefly) that lttng-gen-tp is obtained by installing liblttng-ust-dev.  Might as well install liblttng-ctl-dev at the same time, so we have a complete LTTng installation.

   The next step in the lttng-ust(3) manpage is to create a tracepoint provider: "To create a tracepoint provider, within a build tree similar to examples/easy-ust installed with lttng-ust documentation, a sample_component_provider.h for the general layout."  The sentence makes no sense (is it missing parts?), but even if one glosses over this, the main problem is that there is no easy-ust anywhere to be found within the LTTng installation.  Turning to the Internet, I find https://github.com/giraldeau/lttng-ust/tree/master/doc/examples/easy-ust and grab the handful of files found there.  I then open a console within that directory and invoke make:

gcc -I. -c -o sample.o sample.c
gcc -I. -c -o tp.o tp.c
In file included from /usr/local/include/lttng/ust-tracepoint-event.h:496:0,
                 from /usr/local/include/lttng/tracepoint-event.h:40,
                 from sample_component_provider.h:135,
                 from tp.c:25:
././sample_component_provider.h:128:1: erreur: '__tp_loglevel_entry__sample_component___TRACE_WARNING' undeclared here (not in a function)
make: *** [tp.o] Erreur 1

   I think it's telling me it does not recognise the TRACE_WARNING tracepoint loglevel being defined in sample_component_provider.h (the "TRACEPOINT_LOGLEVEL(sample_component, message, TRACE_WARNING)" call), but the name seems legitimate and ust-tracepoint-event.h looks like it should handle the TRACEPOINT_LOGLEVEL* definitions.

   How do I fix this?

Daniel U. Thibault
R & D pour la d?fense Canada - Valcartier (RDDC Valcartier) / Defence R&D Canada - Valcartier (DRDC Valcartier)
Cyber s?curit? pour les missions essentielles (CME) / Mission Critical Cyber Security (MCCS)
Protection des syst?mes et contremesures (PSC) / Systems Protection & Countermeasures (SPC)
2459 route de la Bravoure
Qu?bec, QC? G3J 1X5
CANADA
Vox?: (418) 844-4000 x4245
Fax?: (418) 844-4538
Gouvernement du Canada?/ Government of Canada
<http://www.valcartier.drdc-rddc.gc.ca/>



^ permalink raw reply	[flat|nested] 4+ messages in thread

* [lttng-dev] lttng-ust quick start?
  2013-01-11 22:12 [lttng-dev] lttng-ust quick start? Thibault, Daniel
@ 2013-01-11 22:45 ` Christian Babeux
  2013-01-14 17:30   ` Thibault, Daniel
  2013-01-14 19:27   ` Thibault, Daniel
  0 siblings, 2 replies; 4+ messages in thread
From: Christian Babeux @ 2013-01-11 22:45 UTC (permalink / raw)


> Turning to the Internet, I find https://github.com/giraldeau/lttng-ust/tree/master/doc/examples/easy-ust and grab the handful of files found there.
> I then open a console within that directory and invoke make:

Please use an official git repository such as: git://git.lttng.org/lttng-ust.git
Or you can use a source distribution:
http://lttng.org/files/lttng-ust/lttng-ust-2.1.0.tar.bz2

Normally this example should be installed in
/usr/share/doc/lttng-ust/examples/easy-ust or
/usr/local/share/doc/lttng-ust/examples/easy-ust in your case.

Christian



^ permalink raw reply	[flat|nested] 4+ messages in thread

* [lttng-dev] lttng-ust quick start?
  2013-01-11 22:45 ` Christian Babeux
@ 2013-01-14 17:30   ` Thibault, Daniel
  2013-01-14 19:27   ` Thibault, Daniel
  1 sibling, 0 replies; 4+ messages in thread
From: Thibault, Daniel @ 2013-01-14 17:30 UTC (permalink / raw)


-----Message d'origine-----
Envoy??: 11 janvier 2013 17:45

> > Turning to the Internet, I find https://github.com/giraldeau/lttng-ust/tree/master/doc/examples/easy-ust and grab the handful of files found there.
> > I then open a console within that directory and invoke make:
>
> Please use an official git repository such as: git://git.lttng.org/lttng-ust.git Or you can use a source distribution:
> http://lttng.org/files/lttng-ust/lttng-ust-2.1.0.tar.bz2
>
> Normally this example should be installed in /usr/share/doc/lttng-ust/examples/easy-ust or /usr/local/share/doc/lttng-ust/examples/easy-ust in your case.
>
> Christian
-----Fin du message d'origine-----

   Part of my point is that the Ubuntu distribution is broken because it does not install the easy-ust files.  I have neither /usr/share/doc/lttng-ust/ nor /usr/local/share/doc/ directories on my machines.

   Note that Googling for "easy-ust" finds no git repositories except for the one I quoted.

   The Ubuntu distribution (liblttng-ust0) is 2.0.2, but it is nevertheless not self-consistent because the man pages it installs for lttng-ust(3) mention easy-ust.  Could it be an lttng-ust distribution was (is) planned for Ubuntu but hasn't made it "out there" yet, and the lttng-ust man pages were included in liblttng-ust0 by accident?

   There is a nearly complete mismatch between the Ubuntu lttng packages and the lttng.org git repository, which is not conducive to one adding the contents of the latter to what's installed by the former:

Ubuntu                                     lttng.org git

liblttng-ctl-dev
liblttng-ctl0
liblttng-ust-dev
liblttng-ust0
liburcu-dev
liburcu1
lttng-modules-dkms     lttng-modules.git
lttng-tools                         lttng-tools.git
                                              lttng-ust.git
lttngtop                              lttngtop.git   (2.0?)

   I tried lttng-ust 2.0.2 (a367ee6) 2013-Apr-18 from http://git.lttng.org/.  Although lttng-ust itself compiles correctly (I only omitted the last step, 'sudo make install', in order to use the existing liblttng-ust 2.0.2 installation), easy-ust's make yields precisely the same error:

gcc -I. -c -o sample.o sample.c
gcc -I. -c -o tp.o tp.c
In file included from /usr/local/include/lttng/ust-tracepoint-event.h:496:0,
                 from /usr/local/include/lttng/tracepoint-event.h:40,
                 from sample_component_provider.h:135,
                 from tp.c:25:
././sample_component_provider.h:128:1: error: ?__tp_loglevel_entry__sample_component___TRACE_WARNING? undeclared here (not in a function)
make: *** [tp.o] Error 1

Daniel U. Thibault
R & D pour la d?fense Canada - Valcartier (RDDC Valcartier) / Defence R&D Canada - Valcartier (DRDC Valcartier)
Cyber s?curit? pour les missions essentielles (CME) / Mission Critical Cyber Security (MCCS)
Protection des syst?mes et contremesures (PSC) / Systems Protection & Countermeasures (SPC)
2459 route de la Bravoure
Qu?bec, QC  G3J 1X5
CANADA
Vox : (418) 844-4000 x4245
Fax : (418) 844-4538
[Valcartier]\\vsi-wdut-o980, [Secteur-SI]\\edge
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/>
 LinkedIn: <http://ca.linkedin.com/in/daniel-u-thibault/>
 Research Gate: <https://www.researchgate.net/profile/Daniel_Thibault/>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [lttng-dev] lttng-ust quick start?
  2013-01-11 22:45 ` Christian Babeux
  2013-01-14 17:30   ` Thibault, Daniel
@ 2013-01-14 19:27   ` Thibault, Daniel
  1 sibling, 0 replies; 4+ messages in thread
From: Thibault, Daniel @ 2013-01-14 19:27 UTC (permalink / raw)


   Interestingly, if I do install lttng-ust 2.0.2 (a367ee6) 2013-Apr-18, easy-ust's make compiles correctly.  One key difference is that /usr[/local]/include/lttng/tracepoint.h now includes an enum setting the TRACE_WARNING value.

   The conclusion is inescapable: the Ubuntu liblttng-ust-dev package is broken.  How many more headers in this Ubuntu package are the wrong ones?  And are any of the other .h-containing packages (liblttng-ctl-dev, liburcu-dev and lttng-modules-dkms) similarly compromised?

Daniel U. Thibault
R & D pour la d?fense Canada - Valcartier (RDDC Valcartier) / Defence R&D Canada - Valcartier (DRDC Valcartier) Cyber s?curit? pour les missions essentielles (CME) / Mission Critical Cyber Security (MCCS) Protection des syst?mes et contremesures (PSC) / Systems Protection & Countermeasures (SPC)
2459 route de la Bravoure
Qu?bec, QC  G3J 1X5
CANADA
Vox : (418) 844-4000 x4245
Fax : (418) 844-4538
[Valcartier]\\vsi-wdut-o980, [Secteur-SI]\\edge 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/>
 LinkedIn: <http://ca.linkedin.com/in/daniel-u-thibault/>
 Research Gate: <https://www.researchgate.net/profile/Daniel_Thibault/>


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-01-14 19:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-01-11 22:12 [lttng-dev] lttng-ust quick start? Thibault, Daniel
2013-01-11 22:45 ` Christian Babeux
2013-01-14 17:30   ` Thibault, Daniel
2013-01-14 19:27   ` Thibault, Daniel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox