On Fri, Nov 7, 2014 at 9:26 AM, Anand Neeli <[email protected]> wrote: > Hi All, > I'm getting following error when reading traces using babeltrace. I have > enabled lttng using relayd and created live session. > > I get this error till the time app is running. After app exits, babeltrace > is able to read the traces. > > Is there any error in my config? or am i doing anything wrong here? > > $>babeltrace > /var/tmp/lttng-traces/node/mysession-20141107-051543/ust/pid/logtrace-5797-20141107-061325/ > > [warning] Ill-shapen or missing "/* CTF x.y" header for text-only metadata. > > [warning] Unsupported CTF specification version 552137642.32558. Trying > anyway. > > [error] at line 1: token "": syntax error, unexpected $end > > [error] Error creating AST > > [warning] Unable to open trace metadata for path > "/var/tmp/lttng-traces/node/mysession-20141107-051543/ust/pid/logtrace-5797-20141107-061325". > > [warning] [Context] Cannot open_trace of format ctf at path > /var/tmp/lttng-traces/vevo_re_node/mysession-20141107-051543/ust/pid/logtrace-5797-20141107-061325. > > [warning] [Context] cannot open trace > "/var/tmp/lttng-traces/node/mysession-20141107-051543/ust/pid/logtrace-5797-20141107-061325" > from > /var/tmp/lttng-traces/node/mysession-20141107-051543/ust/pid/logtrace-5797-20141107-061325/ > for reading. > > [error] Cannot open any trace for reading. > > [error] opening trace > "/var/tmp/lttng-traces/node/mysession-20141107-051543/ust/pid/logtrace-5797-20141107-061325/" > for reading. > > [error] none of the specified trace paths could be opened. > > > > The way i'm enabling lttng: > > > sudo -H /usr/bin/lttng-relayd -o /var/tmp/lttng-traces -d > > sudo -H /usr/bin/lttng-sessiond --consumerd32-path > /usr/lib/lttng/libexec/lttng-consumerd --consumerd32-libdir /usr/lib/ > --consumerd64-path /usr/lib64/lttng/libexec/lttng-consumerd > --consumerd64-libdir /usr/lib64/ -b --no-kernel > > sudo -H /usr/bin/lttng create mysession --live 1000000 -U net://$ipaddr > > sudo -H /usr/bin/lttng enable-channel mychannel --userspace --buffers-pid -s > mysession --tracefile-size 8388608 --tracefile-count 8 > > sudo -H /usr/bin/lttng enable-event --channel mychannel --userspace --all > --exclude 'ust_libc:*' -s mysession > > sudo -H /usr/bin/lttng start >
It seems you are reading a trace from disk before stopping the tracing session. This is unsupported since we have no way to guarantee the trace is readable at all time. The intended way of consuming a live trace while a session is active is to connect to the relay daemon using babeltrace's "-i lttng-live" option. Assuming the relay daemon and the viewer are running on the same machine, connecting to the relay daemon will provide you with a list of available tracing sessions. babeltrace -i lttng-live net://localhost You can then connect to a specific session using babeltrace -i lttng-live net://localhost/my_session Regards, Jérémie > > Thanks, > > Anand Neeli > > > _______________________________________________ > lttng-dev mailing list > [email protected] > http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev > -- Jérémie Galarneau EfficiOS Inc. http://www.efficios.com _______________________________________________ lttng-dev mailing list [email protected] http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
