Mirror of the lttng-dev mailing list
 help / color / mirror / Atom feed
From: David Aldrich via lttng-dev <lttng-dev@lists.lttng.org>
To: lttng-dev@lists.lttng.org
Subject: Not capturing ust events
Date: Wed, 7 May 2025 17:50:33 +0100	[thread overview]
Message-ID: <CAJK_iejrz-U0-XK1hmoH9=TCLcErZTVE16XdyKzXX0buJuuoCQ@mail.gmail.com> (raw)

Hi

I am just getting started with LTTng. I am trying to use
lttng_ust_tracef() initially.

I am running LTTng version 2.13 on Ubuntu 24.04 LTS, and viewing using
TraceCompass 10.3.0 on Windows 11.

I use  lttng_ust_tracef() in just one source file:

#include <lttng/tracef.h>
<snip>
{
    int my_integer = 0;
    string my_string = "Normal";
    lttng_ust_tracef("TaskManager: %d (%s)", my_integer, my_string.c_str());
}

I build with CMake and link to the lttng-ust library:

target_link_libraries(${_lib_name} lttng-ust)

On the target I created a session and enabled the event:

$ lttng create my_proj
$ lttng enable-event --userspace 'lttng_ust_tracef:*'

I have to run the application as root:

sudo -E lttng-record-trace -a ./my_app

When I import the trace directory into TraceCompass I tick both the
kernel and ust event boxes, and create an experiment, but then only
'kernel' shows under the experiments and Traces in the tree view, no
ust branch is shown.

I guess this isn't much to go on, but if anyone has any ideas why it's
not capturing ust events, I would be grateful.

Finally, which 'event_type' should I search for in the event viewer
for lttng_ust_tracef events?

Best regards
David

             reply	other threads:[~2025-05-07 21:09 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-07 16:50 David Aldrich via lttng-dev [this message]
2025-05-08 13:51 ` Kienan Stewart via lttng-dev
2025-05-08 17:02   ` David Aldrich via lttng-dev
2025-05-08 17:25     ` Kienan Stewart via lttng-dev
2025-05-08 17:59       ` David Aldrich via lttng-dev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJK_iejrz-U0-XK1hmoH9=TCLcErZTVE16XdyKzXX0buJuuoCQ@mail.gmail.com' \
    --to=lttng-dev@lists.lttng.org \
    --cc=david.aldrich.ntml@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox