Fix: Fail to add several perf_thread context
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hi Alexander,
Just to make sure I understand the problem, is your point that "lttng add-context" should not fail when multiple contexts are added just because one of them was already present? If not, could you provide a log demonstrating the issue?
Thanks!
Jérémie
Quoted 37 lines · Alexander Grigoriev
In commit
aa3514e96f12c13f681a81ea275dc51dd63473c8not removed old check for duplicate context type increate_ust_app_channel_context()function. If the one ofperf_treadcontexts was already added, in the next similar operation function returns error code EEXIST "UST context already exist".Signed-off-by Alexander Grigoriev <[email protected]>--- src/bin/lttng-sessiond/ust-app.c | 7 ------- 1 file changed, 7 deletions(-)src/bin/lttng-sessiond/ust-app.c +0
-8@@ -1940,13 +1940,6 @@ int create_ust_app_channel_context(struct ust_app_session *ua_sess,DBG2 ("UST app adding context to channel %s" , ua_chan->name); -lttng_ht_lookup (ua_chan->ctx, (void *)((unsigned long )uctx->ctx), &iter); - node =lttng_ht_iter_get_node_ulong (&iter); -if (node !=NULL ) { - ret = -EEXIST ; - goto error; - } - ua_ctx =alloc_ust_app_ctx (uctx);if (ua_ctx ==NULL ) {/* malloc failed */ --1.9.1
_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Signature · 8 lines
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
A message that is not in the archive (sent off-list or not yet received): CA+jJMxvetzEOx7Oy=4Y-J+B7Znc9MDoiJ-X-euryogG1k6Et2w@mail.gmail.com
Hi Jérémie,
"lttng add-context" should not fail when several unique performance counters added after start program with tracepoints. Now "lttng add-context"
fail when several unique perf_tread context added after start program with
tracepoints.
I wrote about this problem:
---------- Forwarded message ----------
From: Alexander Grigoriev <[email protected]>
Date: Tue, Sep 30, 2014 at 4:23 PM
Subject: Problem with perf:thread in 2.5
To: [email protected]
Hello,
I use lttng-2.5 and linux-3.8.13. When I try to add context with several performance counters after start program with tracepoints, I get the following error:
Quoted 1 line
app_with_lttng& // {tracepoint(test, test, 1); sleep(1000); }
[1] 19297
Quoted 1 line
lttng destroy -a
No session found, nothing to do.
Quoted 1 line
lttng -vvv create test
DEBUG3 - 14:54:42.713573 [19313/19313]: URI string:
file:///home/alexgri/lttng-traces/test-20140930-145442 (in uri_parse() at uri.c:293)
DEBUG3 - 14:54:42.713607 [19313/19313]: URI file destination:/home/alexgri/lttng-traces/test-20140930-145442 (in uri_parse() at uri.c:330)
DEBUG3 - 14:54:42.713616 [19313/19313]: URI dtype: 3, proto: 0, host: ,
subdir: , ctrl: 0, data: 0 (in uri_parse() at uri.c:507) DEBUG1 - 14:54:42.713667 [19313/19313]: LSM cmd type : 8 (in send_session_msg() at lttng-ctl.c:131)
Session test created.
Traces will be written in /home/alexgri/lttng-traces/test-20140930-145442 DEBUG1 - 14:54:42.715819 [19313/19313]: Init config session in /home/alexgri (in config_init() at conf.c:295)
Quoted 1 line
lttng -vvv add-context -u -t vpid -t perf:thread:cpu-cycles -t
perf:thread:instructions -t perf:thread:cache-misses -s test DEBUG1 - 14:54:52.124745 [19316/19316]: Adding context... (in add_context() at commands/add_context.c:600)
DEBUG1 - 14:54:52.133393 [19316/19316]: LSM cmd type : 0 (in send_session_msg() at lttng-ctl.c:131)
UST context vpid added to all channels
DEBUG1 - 14:54:52.153445 [19316/19316]: Adding context... (in add_context() at commands/add_context.c:600)
DEBUG1 - 14:54:52.153499 [19316/19316]: LSM cmd type : 0 (in send_session_msg() at lttng-ctl.c:131)
UST context perf:thread:cpu-cycles added to all channels
DEBUG1 - 14:54:52.154356 [19316/19316]: Adding context... (in add_context() at commands/add_context.c:600)
DEBUG1 - 14:54:52.154392 [19316/19316]: LSM cmd type : 0 (in send_session_msg() at lttng-ctl.c:131)
Error: perf:thread:instructions: UST context already exist DEBUG1 - 14:54:52.154469 [19316/19316]: Adding context... (in add_context() at commands/add_context.c:600)
DEBUG1 - 14:54:52.154525 [19316/19316]: LSM cmd type : 0 (in send_session_msg() at lttng-ctl.c:131)
Error: perf:thread:cache-misses: UST context already exist
Warning: Some command(s) went wrong
DEBUG1 - 14:54:52.154620 [19316/19316]: Clean exit (in clean_exit() at lttng.c:167)
'lttng-sessiond -vvv' logs in attachment
Thanks,
Alexander
---------------------------------------------------
Thanks,
Alexander
Quoted 56 lines · Jérémie Galarneau
Hi Alexander,
Just to make sure I understand the problem, is your point that "lttng add-context" should not fail when multiple contexts are added just because one of them was already present? If not, could you provide a log demonstrating the issue?
Thanks!
JérémieQuoted 2 lines · Alexander Grigoriev
In commit
aa3514e96f12c13f681a81ea275dc51dd63473c8not removed old check for duplicate context type increate_ust_app_channel_context()function.If
Review
Quoted 10 lines
the one of
perf_treadcontexts was already added, in the next similar operation function returns error code EEXIST "UST context already exist".Signed-off-by Alexander Grigoriev <[email protected]>--- src/bin/lttng-sessiond/ust-app.c | 7 ------- 1 file changed, 7 deletions(-)(quoted diff) +0
-0
b/src/bin/lttng-sessiond/ust-app.csrc/bin/lttng-sessiond/ust-app.c int create_ust_app_channel_context(struct
Quoted 4 lines
index f8e9693..7f1594b 100644
src/bin/lttng-sessiond/ust-app.c +0
-0@@ -1940,13 +1940,6 @@ int create_ust_app_channel_context(struct
ust_app_session*ua_sess,src/bin/lttng-sessiond/ust-app.c int create_ust_app_channel_context(struct · line 1942
Quoted 4 lines
src/bin/lttng-sessiond/ust-app.c +0
-1DBG2 ("UST app adding context to channel %s" , ua_chan->name); - lttng_ht_lookup(ua_chan->ctx, (void *)((unsignedlong)uctx->ctx), &iter);
Quoted 13 lines
src/bin/lttng-sessiond/ust-app.c +0
-7- node =lttng_ht_iter_get_node_ulong (&iter); -if (node !=NULL ) { - ret = -EEXIST ; - goto error; - } - ua_ctx =alloc_ust_app_ctx (uctx);if (ua_ctx ==NULL ) {/* malloc failed */ --1.9.1
Quoted 4 lines
_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Quoted 6 lines
--
Jérémie Galarneau
EfficiOS Inc.
http://www.efficios.comlttng-sessiond -vvv
DEBUG3 - 14:54:14.762633 [19285/19285]: Creating LTTng run directory: /home/alexgri/.lttng (in create_lttng_rundir() at main.c:4683)
DEBUG1 - 14:54:14.764260 [19285/19285]: Client socket path /home/alexgri/.lttng/client-lttng-sessiond (in main() at main.c:5131)
DEBUG1 - 14:54:14.764302 [19285/19285]: Application socket path /home/alexgri/.lttng/lttng-ust-sock-5 (in main() at main.c:5132)
DEBUG1 - 14:54:14.764310 [19285/19285]: Application wait path /lttng-ust-wait-5-918 (in main() at main.c:5133)
DEBUG1 - 14:54:14.764322 [19285/19285]: LTTng run directory path: /home/alexgri/.lttng (in main() at main.c:5134)
DEBUG2 - 14:54:14.764339 [19285/19285]: UST consumer 32 bits err path: /home/alexgri/.lttng/ustconsumerd32/error (in main() at main.c:5143)
DEBUG2 - 14:54:14.764346 [19285/19285]: UST consumer 32 bits cmd path: /home/alexgri/.lttng/ustconsumerd32/command (in main() at main.c:5145)
DEBUG2 - 14:54:14.764357 [19285/19285]: UST consumer 64 bits err path: /home/alexgri/.lttng/ustconsumerd64/error (in main() at main.c:5154)
DEBUG2 - 14:54:14.764364 [19285/19285]: UST consumer 64 bits cmd path: /home/alexgri/.lttng/ustconsumerd64/command (in main() at main.c:5156)
DEBUG3 - 14:54:14.764715 [19285/19285]: Created hashtable size 4 at 0x6809b0 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:14.764745 [19285/19285]: Created hashtable size 4 at 0x681460 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:14.764756 [19285/19285]: Created hashtable size 4 at 0x681f60 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:14.764767 [19285/19285]: Created hashtable size 4 at 0x682aa0 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG2 - 14:54:14.764782 [19285/19285]: Creating consumer directory: /home/alexgri/.lttng/ustconsumerd64 (in set_consumer_sockets() at main.c:4725)
DEBUG2 - 14:54:14.767029 [19285/19285]: Creating consumer directory: /home/alexgri/.lttng/ustconsumerd32 (in set_consumer_sockets() at main.c:4725)
DEBUG3 - 14:54:14.771347 [19285/19285]: Session daemon client socket 8 and application socket 9 created (in init_daemon_socket() at main.c:4591)
DEBUG3 - 14:54:14.771404 [19285/19285]: Created hashtable size 4 at 0x6835e0 of type 2 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:14.771417 [19285/19285]: Global buffer per UID registry initialized (in buffer_reg_init_uid_registry() at buffer-registry.c:99)
DEBUG3 - 14:54:14.771431 [19285/19285]: Created hashtable size 4 at 0x684120 of type 2 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:14.771438 [19285/19285]: Global buffer per PID registry initialized (in buffer_reg_init_pid_registry() at buffer-registry.c:220)
DEBUG1 - 14:54:14.771460 [19285/19285]: epoll set max size is 24981086 (in compat_epoll_set_max_size() at compat-epoll.c:290)
DEBUG1 - 14:54:14.771479 [19285/19285]: Command subsystem initialized (in cmd_init() at cmd.c:3227)
DEBUG1 - 14:54:14.772937 [19285/19285]: Pid 19285 written in file /home/alexgri/.lttng/lttng-sessiond.pid (in utils_create_pid_file() at utils.c:467)
DEBUG1 - 14:54:14.774492 [19285/19285]: Pid 5345 written in file /home/alexgri/.lttng/jul.port (in utils_create_pid_file() at utils.c:467)
DEBUG1 - 14:54:14.774535 [19285/19285]: TCP inet operation timeout set to 216 sec (in lttcomm_inet_init() at inet.c:529)
DEBUG1 - 14:54:14.774553 [19285/19285]: Health check time delta in seconds set to 236 (in health_init() at health.c:73)
DEBUG1 - 14:54:14.774604 [19285/19286]: [ht-thread] startup. (in thread_ht_cleanup() at ht-cleanup.c:36)
DEBUG1 - 14:54:14.774642 [19285/19289]: [thread] Dispatch UST command started (in thread_dispatch_ust_registration() at main.c:1705)
DEBUG1 - 14:54:14.774632 [19285/19288]: [thread] Manage client started (in thread_manage_clients() at main.c:3941)
DEBUG1 - 14:54:14.774613 [19285/19287]: [thread] Manage health check started (in thread_manage_health() at main.c:3755)
DEBUG1 - 14:54:14.774655 [19285/19290]: [thread] Manage application registration started (in thread_registration_apps() at main.c:1929)
DEBUG1 - 14:54:14.774672 [19285/19289]: Futex n to 1 prepare done (in futex_nto1_prepare() at futex.c:75)
DEBUG3 - 14:54:14.774685 [19285/19286]: [ht-thread] Polling on 2 fds. (in thread_ht_cleanup() at ht-cleanup.c:64)
DEBUG1 - 14:54:14.774754 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
DEBUG1 - 14:54:14.774742 [19285/19292]: [ust-thread] Manage application notify command (in ust_thread_manage_notify() at ust-thread.c:39)
DEBUG1 - 14:54:14.774749 [19285/19289]: Woken up but nothing in the UST command queue (in thread_dispatch_ust_registration() at main.c:1728)
DEBUG1 - 14:54:14.774689 [19285/19291]: [thread] Manage application started (in thread_manage_apps() at main.c:1419)
DEBUG1 - 14:54:14.774774 [19285/19293]: [jul-thread] Manage JUL application registration. (in jul_thread_manage_registration() at jul-thread.c:260)
DEBUG1 - 14:54:14.774773 [19285/19290]: Notifying applications of session daemon state: 1 (in notify_ust_apps() at main.c:756)
DEBUG1 - 14:54:14.774787 [19285/19294]: [load-session-thread] Load session (in thread_load_session() at load-session-thread.c:90)
DEBUG3 - 14:54:14.774811 [19285/19292]: [ust-thread] Manage notify polling on 2 fds (in ust_thread_manage_notify() at ust-thread.c:68)
DEBUG1 - 14:54:14.774850 [19285/19291]: Apps thread polling on 2 fds (in thread_manage_apps() at main.c:1449)
DEBUG3 - 14:54:14.774862 [19285/19293]: URI string: tcp://localhost (in uri_parse() at uri.c:293)
DEBUG1 - 14:54:14.774892 [19285/19290]: Got the wait shm fd 23 (in get_wait_shm() at shm.c:115)
DEBUG1 - 14:54:14.774943 [19285/19290]: Futex wait update active 1 (in futex_wait_update() at futex.c:63)
DEBUG1 - 14:54:14.774956 [19285/19290]: Accepting application registration (in thread_registration_apps() at main.c:1966)
DEBUG2 - 14:54:14.775058 [19285/19293]: IP address resolved to 127.0.0.1 (in set_ip_address() at uri.c:134)
DEBUG3 - 14:54:14.775074 [19285/19293]: URI dtype: 1, proto: 1, host: localhost, subdir: , ctrl: 0, data: 0 (in uri_parse() at uri.c:507)
DEBUG1 - 14:54:14.775097 [19285/19293]: [jul-thread] Listening on TCP port 5345 and socket 24 (in init_tcp_socket() at jul-thread.c:158)
DEBUG3 - 14:54:14.775102 [19285/19293]: [jul-thread] Manage JUL polling on 2 fds (in jul_thread_manage_registration() at jul-thread.c:288)
DEBUG1 - 14:54:14.775582 [19285/19287]: Health check ready (in thread_manage_health() at main.c:3820)
DEBUG1 - 14:54:28.115220 [19285/19290]: UST registration received with pid:19303 ppid:19297 uid:918 gid:800 sock:25 name:llvm-symbolizer (version 5.0) (in thread_registration_apps() at main.c:2074) DEBUG1 - 14:54:28.115246 [19285/19290]: Futex n to 1 wake done (in futex_nto1_wake() at futex.c:104)
DEBUG1 - 14:54:28.115251 [19285/19290]: Accepting application registration (in thread_registration_apps() at main.c:1966)
DEBUG1 - 14:54:28.115250 [19285/19289]: Futex n to 1 wait done (in futex_nto1_wait() at futex.c:90)
DEBUG1 - 14:54:28.115267 [19285/19289]: Futex n to 1 prepare done (in futex_nto1_prepare() at futex.c:75)
DEBUG1 - 14:54:28.115273 [19285/19289]: Dispatching UST registration pid:19303 ppid:19297 uid:918 gid:800 sock:25 name:llvm-symbolizer (version 5.0) (in thread_dispatch_ust_registration() at main.c:1740) DEBUG3 - 14:54:28.115281 [19285/19289]: UST app creating application for socket 25 (in ust_app_create() at ust-app.c:2848)
DEBUG3 - 14:54:28.115353 [19285/19289]: Created hashtable size 4 at 0x7fffd8007760 of type 2 (in lttng_ht_new() at hashtable.c:127)
DEBUG1 - 14:54:28.115355 [19285/19290]: UST registration received with pid:19303 ppid:19297 uid:918 gid:800 sock:26 name:llvm-symbolizer (version 5.0) (in thread_registration_apps() at main.c:2074) DEBUG1 - 14:54:28.115380 [19285/19290]: Futex n to 1 wake done (in futex_nto1_wake() at futex.c:104)
DEBUG1 - 14:54:28.115386 [19285/19290]: Accepting application registration (in thread_registration_apps() at main.c:1966)
DEBUG3 - 14:54:28.115372 [19285/19289]: Created hashtable size 4 at 0x7fffd80067c0 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG1 - 14:54:28.115428 [19285/19289]: Dispatching UST registration pid:19303 ppid:19297 uid:918 gid:800 sock:26 name:llvm-symbolizer (version 5.0) (in thread_dispatch_ust_registration() at main.c:1740) DEBUG3 - 14:54:28.115435 [19285/19289]: UST app notify socket 26 is set (in thread_dispatch_ust_registration() at main.c:1797)
DEBUG1 - 14:54:28.115454 [19285/19289]: App registered with pid:19303 ppid:19297 uid:918 gid:800 sock:25 name:llvm-symbolizer notify_sock:26 (version 5.0) (in ust_app_add() at ust-app.c:2936) DEBUG3 - 14:54:28.115506 [19285/19292]: UST thread notify added sock 26 to pollset (in ust_thread_manage_notify() at ust-thread.c:137)
DEBUG3 - 14:54:28.115516 [19285/19292]: [ust-thread] Manage notify polling on 3 fds (in ust_thread_manage_notify() at ust-thread.c:68)
DEBUG1 - 14:54:28.115519 [19285/19289]: Woken up but nothing in the UST command queue (in thread_dispatch_ust_registration() at main.c:1728)
DEBUG1 - 14:54:28.115524 [19285/19289]: Futex n to 1 wait done (in futex_nto1_wait() at futex.c:90)
DEBUG1 - 14:54:28.115529 [19285/19289]: Futex n to 1 prepare done (in futex_nto1_prepare() at futex.c:75)
DEBUG1 - 14:54:28.115529 [19285/19291]: Apps with sock 25 added to poll set (in thread_manage_apps() at main.c:1510)
DEBUG1 - 14:54:28.115546 [19285/19291]: Apps thread polling on 3 fds (in thread_manage_apps() at main.c:1449)
DEBUG1 - 14:54:28.115532 [19285/19289]: Woken up but nothing in the UST command queue (in thread_dispatch_ust_registration() at main.c:1728)
DEBUG1 - 14:54:28.120762 [19285/19290]: UST registration received with pid:19297 ppid:12755 uid:918 gid:800 sock:27 name:app_with_lttng (version 5.0) (in thread_registration_apps() at main.c:2074) DEBUG1 - 14:54:28.120771 [19285/19290]: Futex n to 1 wake done (in futex_nto1_wake() at futex.c:104)
DEBUG1 - 14:54:28.120773 [19285/19289]: Futex n to 1 wait done (in futex_nto1_wait() at futex.c:90)
DEBUG1 - 14:54:28.120780 [19285/19289]: Futex n to 1 prepare done (in futex_nto1_prepare() at futex.c:75)
DEBUG1 - 14:54:28.120774 [19285/19290]: Accepting application registration (in thread_registration_apps() at main.c:1966)
DEBUG1 - 14:54:28.120787 [19285/19289]: Dispatching UST registration pid:19297 ppid:12755 uid:918 gid:800 sock:27 name:app_with_lttng (version 5.0) (in thread_dispatch_ust_registration() at main.c:1740) DEBUG3 - 14:54:28.120803 [19285/19289]: UST app creating application for socket 27 (in ust_app_create() at ust-app.c:2848)
DEBUG1 - 14:54:28.120808 [19285/19290]: UST registration received with pid:19297 ppid:12755 uid:918 gid:800 sock:28 name:app_with_lttng (version 5.0) (in thread_registration_apps() at main.c:2074) DEBUG3 - 14:54:28.120810 [19285/19289]: Created hashtable size 4 at 0x7fffd8001aa0 of type 2 (in lttng_ht_new() at hashtable.c:127)
DEBUG1 - 14:54:28.120817 [19285/19290]: Futex n to 1 wake done (in futex_nto1_wake() at futex.c:104)
DEBUG3 - 14:54:28.120826 [19285/19289]: Created hashtable size 4 at 0x7fffd8006a60 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG1 - 14:54:28.120836 [19285/19290]: Accepting application registration (in thread_registration_apps() at main.c:1966)
DEBUG1 - 14:54:28.120850 [19285/19289]: Dispatching UST registration pid:19297 ppid:12755 uid:918 gid:800 sock:28 name:app_with_lttng (version 5.0) (in thread_dispatch_ust_registration() at main.c:1740) DEBUG3 - 14:54:28.120856 [19285/19289]: UST app notify socket 28 is set (in thread_dispatch_ust_registration() at main.c:1797)
DEBUG1 - 14:54:28.120864 [19285/19289]: App registered with pid:19297 ppid:12755 uid:918 gid:800 sock:27 name:app_with_lttng notify_sock:28 (version 5.0) (in ust_app_add() at ust-app.c:2936) DEBUG3 - 14:54:28.120900 [19285/19292]: UST thread notify added sock 28 to pollset (in ust_thread_manage_notify() at ust-thread.c:137)
DEBUG3 - 14:54:28.120910 [19285/19292]: [ust-thread] Manage notify polling on 4 fds (in ust_thread_manage_notify() at ust-thread.c:68)
DEBUG1 - 14:54:28.120913 [19285/19291]: Apps with sock 27 added to poll set (in thread_manage_apps() at main.c:1510)
DEBUG1 - 14:54:28.120919 [19285/19291]: Apps thread polling on 4 fds (in thread_manage_apps() at main.c:1449)
DEBUG1 - 14:54:28.120909 [19285/19289]: Woken up but nothing in the UST command queue (in thread_dispatch_ust_registration() at main.c:1728)
DEBUG1 - 14:54:28.120937 [19285/19289]: Futex n to 1 wait done (in futex_nto1_wait() at futex.c:90)
DEBUG1 - 14:54:28.120940 [19285/19289]: Futex n to 1 prepare done (in futex_nto1_prepare() at futex.c:75)
DEBUG1 - 14:54:28.120944 [19285/19289]: Woken up but nothing in the UST command queue (in thread_dispatch_ust_registration() at main.c:1728)
DEBUG1 - 14:54:34.362066 [19285/19288]: Wait for client response (in thread_manage_clients() at main.c:4030)
DEBUG1 - 14:54:34.362092 [19285/19288]: Receiving data from client ... (in thread_manage_clients() at main.c:4075)
DEBUG1 - 14:54:34.362111 [19285/19288]: Nothing recv() from client... continuing (in thread_manage_clients() at main.c:4079)
DEBUG1 - 14:54:34.362119 [19285/19288]: Clean command context structure (in clean_command_ctx() at main.c:736)
DEBUG1 - 14:54:34.362124 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
DEBUG1 - 14:54:34.362298 [19285/19288]: Wait for client response (in thread_manage_clients() at main.c:4030)
DEBUG1 - 14:54:34.362320 [19285/19288]: Receiving data from client ... (in thread_manage_clients() at main.c:4075)
DEBUG1 - 14:54:34.362330 [19285/19288]: Processing client command 13 (in process_client_msg() at main.c:2768)
DEBUG1 - 14:54:34.362335 [19285/19288]: Counting number of available session for UID 918 GID 800 (in lttng_sessions_count() at main.c:2737)
DEBUG1 - 14:54:34.362340 [19285/19288]: Getting all available session for UID 918 GID 800 (in cmd_list_lttng_sessions() at cmd.c:2496)
DEBUG1 - 14:54:34.362355 [19285/19288]: Sending response (size: 16, retcode: Success) (in thread_manage_clients() at main.c:4124)
DEBUG1 - 14:54:34.362366 [19285/19288]: Clean command context structure (in clean_command_ctx() at main.c:736)
DEBUG1 - 14:54:34.362370 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
DEBUG1 - 14:54:42.713503 [19285/19288]: Wait for client response (in thread_manage_clients() at main.c:4030)
DEBUG1 - 14:54:42.713519 [19285/19288]: Receiving data from client ... (in thread_manage_clients() at main.c:4075)
DEBUG1 - 14:54:42.713525 [19285/19288]: Nothing recv() from client... continuing (in thread_manage_clients() at main.c:4079)
DEBUG1 - 14:54:42.713532 [19285/19288]: Clean command context structure (in clean_command_ctx() at main.c:736)
DEBUG1 - 14:54:42.713535 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
DEBUG1 - 14:54:42.713669 [19285/19288]: Wait for client response (in thread_manage_clients() at main.c:4030)
DEBUG1 - 14:54:42.713678 [19285/19288]: Receiving data from client ... (in thread_manage_clients() at main.c:4075)
DEBUG1 - 14:54:42.713697 [19285/19288]: Processing client command 8 (in process_client_msg() at main.c:2768)
DEBUG1 - 14:54:42.713710 [19285/19288]: Waiting for 1 URIs from client ... (in process_client_msg() at main.c:3405)
DEBUG2 - 14:54:42.713719 [19285/19288]: Trying to find session by name test (in session_find_by_name() at session.c:169)
DEBUG3 - 14:54:42.713746 [19285/19288]: Created hashtable size 4 at 0x7fffe4005ee0 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG1 - 14:54:42.713752 [19285/19288]: Tracing session test created with ID 0 by UID 918 GID 800 (in session_create() at session.c:276)
DEBUG2 - 14:54:42.713755 [19285/19288]: Trying to find session by name test (in session_find_by_name() at session.c:169)
DEBUG3 - 14:54:42.713766 [19285/19288]: Created hashtable size 4 at 0x7fffe400ba80 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG2 - 14:54:42.713772 [19285/19288]: Setting trace directory path from URI to /home/alexgri/lttng-traces/test-20140930-145442 (in add_uri_to_consumer() at cmd.c:486) DEBUG1 - 14:54:42.713779 [19285/19288]: Sending response (size: 16, retcode: Success) (in thread_manage_clients() at main.c:4124)
DEBUG1 - 14:54:42.713789 [19285/19288]: Clean command context structure (in clean_command_ctx() at main.c:736)
DEBUG1 - 14:54:42.713793 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
DEBUG1 - 14:54:52.120529 [19285/19288]: Wait for client response (in thread_manage_clients() at main.c:4030)
DEBUG1 - 14:54:52.123211 [19285/19288]: Receiving data from client ... (in thread_manage_clients() at main.c:4075)
DEBUG1 - 14:54:52.123777 [19285/19288]: Nothing recv() from client... continuing (in thread_manage_clients() at main.c:4079)
DEBUG1 - 14:54:52.124489 [19285/19288]: Clean command context structure (in clean_command_ctx() at main.c:736)
DEBUG1 - 14:54:52.124857 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
DEBUG1 - 14:54:52.133391 [19285/19288]: Wait for client response (in thread_manage_clients() at main.c:4030)
DEBUG1 - 14:54:52.134271 [19285/19288]: Receiving data from client ... (in thread_manage_clients() at main.c:4075)
DEBUG1 - 14:54:52.137061 [19285/19288]: Processing client command 0 (in process_client_msg() at main.c:2768)
DEBUG1 - 14:54:52.137617 [19285/19288]: Getting session test by name (in process_client_msg() at main.c:2849)
DEBUG2 - 14:54:52.137968 [19285/19288]: Trying to find session by name test (in session_find_by_name() at session.c:169)
DEBUG1 - 14:54:52.138300 [19285/19288]: Creating UST session (in create_ust_session() at main.c:2648)
DEBUG3 - 14:54:52.139004 [19285/19288]: Created hashtable size 4 at 0x7fffe4003eb0 of type 0 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.139557 [19285/19288]: Created hashtable size 4 at 0x7fffe40049f0 of type 0 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.140982 [19285/19288]: Created hashtable size 4 at 0x7fffe4005530 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG2 - 14:54:52.141337 [19285/19288]: UST trace session create successful (in trace_ust_create_session() at trace-ust.c:263)
DEBUG3 - 14:54:52.141708 [19285/19288]: Copying tracing session consumer output in UST session (in copy_session_consumer() at main.c:2597)
DEBUG3 - 14:54:52.143403 [19285/19288]: Created hashtable size 4 at 0x7fffe4005860 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.143968 [19285/19286]: [ht-thread] Polling on 2 fds. (in thread_ht_cleanup() at ht-cleanup.c:64)
DEBUG3 - 14:54:52.144310 [19285/19288]: Copy session consumer subdir /ust (in copy_session_consumer() at main.c:2615)
DEBUG1 - 14:54:52.146308 [19285/19288]: Spawning consumerd (in spawn_consumerd() at main.c:2286)
DEBUG2 - 14:54:52.163511 [19285/19288]: Consumer pid 19317 (in start_consumerd() at main.c:2471)
DEBUG2 - 14:54:52.164492 [19285/19288]: Spawning consumer control thread (in start_consumerd() at main.c:2474)
DEBUG1 - 14:54:52.167938 [19285/19318]: [thread] Manage consumer started (in thread_manage_consumer() at main.c:1122)
DEBUG1 - 14:54:52.170382 [19317/19317]: Using 64-bit UST consumer at: /usr/lib64/lttng/libexec/lttng-consumerd (in spawn_consumerd() at main.c:2366)
DEBUG2 - 14:54:52.285850 [19285/19318]: Receiving code from consumer err_sock (in thread_manage_consumer() at main.c:1207)
DEBUG1 - 14:54:52.104205 [19285/19318]: Consumer command socket ready (fd: 32 (in thread_manage_consumer() at main.c:1241)
DEBUG1 - 14:54:52.104214 [19285/19318]: Consumer metadata socket ready (fd: 33) (in thread_manage_consumer() at main.c:1243)
DEBUG3 - 14:54:52.104218 [19285/19288]: Consumer socket created (fd: 32) and added to output (in consumer_create_socket() at consumer.c:301)
DEBUG1 - 14:54:52.104238 [19285/19288]: Setting relayd for session test (in cmd_setup_relayd() at cmd.c:727)
DEBUG3 - 14:54:52.104250 [19285/19288]: Created hashtable size 4 at 0x7fffe40118b0 of type 0 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.104258 [19285/19288]: Created hashtable size 4 at 0x7fffe4011b50 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG2 - 14:54:52.104262 [19285/19288]: Trace UST channel channel0 created (in trace_ust_create_channel() at trace-ust.c:331)
DEBUG2 - 14:54:52.104266 [19285/19288]: Channel channel0 is being created for UST with buffer 1 and id 0 (in channel_ust_create() at channel.c:348)
DEBUG2 - 14:54:52.104273 [19285/19288]: UST app adding channel channel0 to UST domain for session id 0 (in ust_app_create_channel_glb() at ust-app.c:3536)
DEBUG2 - 14:54:52.104280 [19285/19288]: UST app pid: 19303 session id 0 not found, creating it (in create_ust_app_session() at ust-app.c:1842)
DEBUG3 - 14:54:52.104288 [19285/19288]: Created hashtable size 4 at 0x7fffe4014740 of type 0 (in lttng_ht_new() at hashtable.c:127)
DEBUG2 - 14:54:52.104305 [19285/19288]: Shadow copy of session handle -1 (in shadow_copy_session() at ust-app.c:1598)
DEBUG3 - 14:54:52.104312 [19285/19288]: Buffer registry per UID find id: 0, ABI: 64, uid: 918 (in buffer_reg_uid_find() at buffer-registry.c:195)
DEBUG3 - 14:54:52.104318 [19285/19288]: Created hashtable size 4 at 0x7fffe4015290 of type 2 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.104322 [19285/19288]: Buffer registry per UID created id: 0, ABI: 64, uid: 918, domain: 2 (in buffer_reg_uid_create() at buffer-registry.c:144)
DEBUG3 - 14:54:52.104326 [19285/19288]: Buffer registry per UID adding to global registry with id: 0 (in buffer_reg_uid_add() at buffer-registry.c:166)
DEBUG3 - 14:54:52.104334 [19285/19288]: Created hashtable size 4 at 0x7fffe4015e70 of type 2 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.104372 [19285/19288]: Append to metadata: "typealias integer { size = 8; align = 8; signed = false; } := uint8_t;
typealias integer { size = 16; align = 8; signed = false; } := uint16_t;
typealias integer { size = 32; align = 8; signed = false; } := uint32_t;
typealias integer { size = 64; align = 8; signed = false; } := uint64_t;
typealias integer { size = 64; align = 8; signed = false; } := unsigned long;
typealias integer { size = 5; align = 1; signed = false; } := uint5_t;
typealias integer { size = 27; align = 1; signed = false; } := uint27_t;
trace {
major = 1;
minor = 8;
uuid = "a11cfb42-aadc-4683-b11a-9628fcabe2c6";
byte_order = le;
packet.header := struct {
uint32_t magic;
uint8_t uuid[16];
uint32_t stream_id;
};
};" (in lttng_metadata_printf() at ust-metadata.c:151)
DEBUG3 - 14:54:52.104395 [19285/19288]: Append to metadata: "env {
hostname = "sandy.tbricks.com";
domain = "ust";
tracer_name = "lttng-ust";
tracer_major = 2;
tracer_minor = 5;" (in lttng_metadata_printf() at ust-metadata.c:151) DEBUG3 - 14:54:52.104404 [19285/19288]: Append to metadata: "};
" (in lttng_metadata_printf() at ust-metadata.c:151)
DEBUG3 - 14:54:52.104409 [19285/19288]: Append to metadata: "clock {
name = monotonic;
" (in lttng_metadata_printf() at ust-metadata.c:151)
DEBUG3 - 14:54:52.104438 [19285/19288]: Append to metadata: " uuid = "f88192a0-463c-40be-a7f2-3f51d7a35d96";
" (in lttng_metadata_printf() at ust-metadata.c:151)
DEBUG3 - 14:54:52.104446 [19285/19288]: Append to metadata: " description = "Monotonic Clock";
freq = 1000000000; /* Frequency, in Hz */
/* clock value offset from Epoch is: offset * (1/freq) */
offset = 1411389228262174265;
};" (in lttng_metadata_printf() at ust-metadata.c:151)
DEBUG3 - 14:54:52.104457 [19285/19288]: Append to metadata: "typealias integer {
size = 27; align = 1; signed = false;
map = clock.monotonic.value;
} := uint27_clock_monotonic_t;typealias integer {
size = 32; align = 8; signed = false;
map = clock.monotonic.value;
} := uint32_clock_monotonic_t;typealias integer {
size = 64; align = 8; signed = false;
map = clock.monotonic.value;
} := uint64_clock_monotonic_t;" (in lttng_metadata_printf() at ust-metadata.c:151)
DEBUG3 - 14:54:52.104471 [19285/19288]: Append to metadata: "struct packet_context {
uint64_clock_monotonic_t timestamp_begin;
uint64_clock_monotonic_t timestamp_end;
uint64_t content_size;
uint64_t packet_size;
unsigned long events_discarded;
uint32_t cpu_id;
};" (in lttng_metadata_printf() at ust-metadata.c:151)
DEBUG3 - 14:54:52.104485 [19285/19288]: Append to metadata: "struct event_header_compact {
enum : uint5_t { compact = 0 ... 30, extended = 31 } id;
variant <id> {
struct {
uint27_clock_monotonic_t timestamp;
} compact;
struct {
uint32_t id;
uint64_clock_monotonic_t timestamp;
} extended;
} v;
} align(8);struct event_header_large {
enum : uint16_t { compact = 0 ... 65534, extended = 65535 } id;
variant <id> {
struct {
uint32_clock_monotonic_t timestamp;
} compact;
struct {
uint32_t id;
uint64_clock_monotonic_t timestamp;
} extended;
} v;
} align(8);" (in lttng_metadata_printf() at ust-metadata.c:151)
DEBUG3 - 14:54:52.104514 [19285/19288]: UST app buffer registry per UID created successfully (in setup_buffer_reg_uid() at ust-app.c:1804)
DEBUG2 - 14:54:52.104595 [19285/19288]: UST app session created successfully with handle 1 (in create_ust_app_session() at ust-app.c:1910)
DEBUG3 - 14:54:52.104611 [19285/19288]: Created hashtable size 4 at 0x7fffe4016bd0 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.104619 [19285/19288]: Created hashtable size 4 at 0x7fffe4018930 of type 0 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.104623 [19285/19288]: UST app channel channel0 allocated (in alloc_ust_app_channel() at ust-app.c:882)
DEBUG2 - 14:54:52.104627 [19285/19288]: UST app shadow copy of channel channel0 started (in shadow_copy_channel() at ust-app.c:1525)
DEBUG3 - 14:54:52.104630 [19285/19288]: UST app shadow copy of channel channel0 done (in shadow_copy_channel() at ust-app.c:1575)
DEBUG1 - 14:54:52.104635 [19285/19288]: UST app creating channel channel0 with per UID buffers (in create_channel_per_uid() at ust-app.c:2437)
DEBUG3 - 14:54:52.104639 [19285/19288]: Buffer registry per UID find id: 0, ABI: 64, uid: 918 (in buffer_reg_uid_find() at buffer-registry.c:195)
DEBUG2 - 14:54:52.104643 [19285/19288]: UST app creating buffer registry channel for channel0 (in create_buffer_reg_channel() at ust-app.c:2290)
DEBUG3 - 14:54:52.104646 [19285/19288]: Buffer registry channel create with key: 0 (in buffer_reg_channel_create() at buffer-registry.c:326)
DEBUG3 - 14:54:52.104651 [19285/19288]: Created hashtable size 4 at 0x7fffe40193e0 of type 0 (in lttng_ht_new() at hashtable.c:127)
DEBUG2 - 14:54:52.104658 [19285/19288]: Asking UST consumer for channel (in ask_channel_creation() at ust-consumer.c:118)
DEBUG3 - 14:54:52.104666 [19285/19288]: mkdir() recursive /home/alexgri/lttng-traces/test-20140930-145442/ust/uid/918/64-bit with mode 504 for uid 918 and gid 800 (in run_as_mkdir_recursive() at runas.c:308) DEBUG1 - 14:54:52.104670 [19285/19288]: Using run_as_clone (in run_as() at runas.c:291)
DEBUG3 - 14:54:52.109133 [19285/19288]: UST registry channel finding key 0 (in ust_registry_channel_find() at ust-registry.c:489)
DEBUG2 - 14:54:52.151797 [19285/19288]: UST ask channel 1 successfully done with 16 stream(s) (in ask_channel_creation() at ust-consumer.c:195)
DEBUG2 - 14:54:52.151858 [19285/19288]: UST app stream 1 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151874 [19285/19288]: UST app stream 2 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151882 [19285/19288]: UST app stream 3 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151889 [19285/19288]: UST app stream 4 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151897 [19285/19288]: UST app stream 5 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151909 [19285/19288]: UST app stream 6 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151919 [19285/19288]: UST app stream 7 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151928 [19285/19288]: UST app stream 8 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151935 [19285/19288]: UST app stream 9 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151943 [19285/19288]: UST app stream 10 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151952 [19285/19288]: UST app stream 11 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151960 [19285/19288]: UST app stream 12 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151969 [19285/19288]: UST app stream 13 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151977 [19285/19288]: UST app stream 14 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151984 [19285/19288]: UST app stream 15 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG2 - 14:54:52.151992 [19285/19288]: UST app stream 16 received successfully (in ust_consumer_get_channel() at ust-consumer.c:311)
DEBUG3 - 14:54:52.152001 [19285/19288]: UST app consumer has no more stream available (in ust_consumer_get_channel() at ust-consumer.c:294)
DEBUG2 - 14:54:52.152007 [19285/19288]: UST app setup buffer registry channel for channel0 (in setup_buffer_reg_channel() at ust-app.c:2338)
DEBUG2 - 14:54:52.152012 [19285/19288]: UST app setup buffer registry stream (in setup_buffer_reg_streams() at ust-app.c:2245)
DEBUG3 - 14:54:52.152015 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152020 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152023 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152026 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152029 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152032 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152035 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152038 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152041 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152044 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152047 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152050 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152052 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152071 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152074 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG3 - 14:54:52.152077 [19285/19288]: Buffer registry creating stream (in buffer_reg_stream_create() at buffer-registry.c:356)
DEBUG1 - 14:54:52.152080 [19285/19288]: UST app sending buffer registry channel to ust sock 25 (in send_channel_uid_to_ust() at ust-app.c:2374)
DEBUG2 - 14:54:52.152087 [19285/19288]: UST app send channel to sock 25 pid 19303 (name: channel0, key: 0) (in ust_consumer_send_channel_to_ust() at ust-consumer.c:415) DEBUG2 - 14:54:52.152261 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152297 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152326 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152351 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152370 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152392 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152416 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152439 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152462 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152484 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152508 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152539 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152562 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152585 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152608 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152631 [19285/19288]: UST consumer send stream to app 25 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152658 [19285/19288]: UST app create channel channel0 for PID 19303 completed (in create_ust_app_channel() at ust-app.c:2643)
DEBUG2 - 14:54:52.152670 [19285/19288]: UST app pid: 19297 session id 0 not found, creating it (in create_ust_app_session() at ust-app.c:1842)
DEBUG3 - 14:54:52.152678 [19285/19288]: Created hashtable size 4 at 0x7fffe401ac30 of type 0 (in lttng_ht_new() at hashtable.c:127)
DEBUG2 - 14:54:52.152690 [19285/19288]: Shadow copy of session handle -1 (in shadow_copy_session() at ust-app.c:1598)
DEBUG3 - 14:54:52.152694 [19285/19288]: Buffer registry per UID find id: 0, ABI: 64, uid: 918 (in buffer_reg_uid_find() at buffer-registry.c:195)
DEBUG2 - 14:54:52.152753 [19285/19288]: UST app session created successfully with handle 1 (in create_ust_app_session() at ust-app.c:1910)
DEBUG3 - 14:54:52.152765 [19285/19288]: Created hashtable size 4 at 0x7fffe401b180 of type 1 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.152770 [19285/19288]: Created hashtable size 4 at 0x7fffe401dc20 of type 0 (in lttng_ht_new() at hashtable.c:127)
DEBUG3 - 14:54:52.152774 [19285/19288]: UST app channel channel0 allocated (in alloc_ust_app_channel() at ust-app.c:882)
DEBUG2 - 14:54:52.152777 [19285/19288]: UST app shadow copy of channel channel0 started (in shadow_copy_channel() at ust-app.c:1525)
DEBUG3 - 14:54:52.152781 [19285/19288]: UST app shadow copy of channel channel0 done (in shadow_copy_channel() at ust-app.c:1575)
DEBUG1 - 14:54:52.152784 [19285/19288]: UST app creating channel channel0 with per UID buffers (in create_channel_per_uid() at ust-app.c:2437)
DEBUG3 - 14:54:52.152787 [19285/19288]: Buffer registry per UID find id: 0, ABI: 64, uid: 918 (in buffer_reg_uid_find() at buffer-registry.c:195)
DEBUG1 - 14:54:52.152791 [19285/19288]: UST app sending buffer registry channel to ust sock 27 (in send_channel_uid_to_ust() at ust-app.c:2374)
DEBUG2 - 14:54:52.152796 [19285/19288]: UST app send channel to sock 27 pid 19297 (name: channel0, key: 0) (in ust_consumer_send_channel_to_ust() at ust-consumer.c:415) DEBUG2 - 14:54:52.152893 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152925 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152950 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152974 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.152996 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153018 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153040 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153062 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153084 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153107 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153128 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153151 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153173 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153202 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153223 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153246 [19285/19288]: UST consumer send stream to app 27 (in ust_consumer_send_stream_to_ust() at ust-consumer.c:380)
DEBUG2 - 14:54:52.153269 [19285/19288]: UST app create channel channel0 for PID 19297 completed (in create_ust_app_channel() at ust-app.c:2643)
DEBUG2 - 14:54:52.153282 [19285/19288]: Channel channel0 created successfully (in channel_ust_create() at channel.c:383)
DEBUG2 - 14:54:52.153291 [19285/19288]: UST app adding context to channel channel0 (in create_ust_app_channel_context() at ust-app.c:1941)
DEBUG3 - 14:54:52.153296 [19285/19288]: UST app context 1 allocated (in alloc_ust_app_ctx() at ust-app.c:965)
DEBUG2 - 14:54:52.153353 [19285/19288]: UST app context handle -1 created successfully for channel channel0 (in create_ust_channel_context() at ust-app.c:1112)
DEBUG2 - 14:54:52.153361 [19285/19288]: UST app adding context to channel channel0 (in create_ust_app_channel_context() at ust-app.c:1941)
DEBUG3 - 14:54:52.153366 [19285/19288]: UST app context 1 allocated (in alloc_ust_app_ctx() at ust-app.c:965)
DEBUG2 - 14:54:52.153392 [19285/19288]: UST app context handle -1 created successfully for channel channel0 (in create_ust_channel_context() at ust-app.c:1112)
DEBUG1 - 14:54:52.153401 [19285/19288]: Context UST 1 added to channel channel0 (in add_uctx_to_channel() at context.c:134)
DEBUG1 - 14:54:52.153406 [19285/19288]: Sending response (size: 16, retcode: Success) (in thread_manage_clients() at main.c:4124)
DEBUG1 - 14:54:52.153418 [19285/19288]: Clean command context structure (in clean_command_ctx() at main.c:736)
DEBUG1 - 14:54:52.153422 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
DEBUG1 - 14:54:52.153500 [19285/19288]: Wait for client response (in thread_manage_clients() at main.c:4030)
DEBUG1 - 14:54:52.153515 [19285/19288]: Receiving data from client ... (in thread_manage_clients() at main.c:4075)
DEBUG1 - 14:54:52.153523 [19285/19288]: Processing client command 0 (in process_client_msg() at main.c:2768)
DEBUG1 - 14:54:52.153527 [19285/19288]: Getting session test by name (in process_client_msg() at main.c:2849)
DEBUG2 - 14:54:52.153530 [19285/19288]: Trying to find session by name test (in session_find_by_name() at session.c:169)
DEBUG3 - 14:54:52.153535 [19285/19288]: Consumer socket created (fd: 32) and added to output (in consumer_create_socket() at consumer.c:301)
DEBUG1 - 14:54:52.153540 [19285/19288]: Setting relayd for session test (in cmd_setup_relayd() at cmd.c:727)
DEBUG2 - 14:54:52.153545 [19285/19288]: UST app adding context to channel channel0 (in create_ust_app_channel_context() at ust-app.c:1941)
DEBUG3 - 14:54:52.153549 [19285/19288]: UST app context 5 allocated (in alloc_ust_app_ctx() at ust-app.c:965)
DEBUG2 - 14:54:52.153956 [19285/19288]: UST app context handle -1 created successfully for channel channel0 (in create_ust_channel_context() at ust-app.c:1112)
DEBUG2 - 14:54:52.153962 [19285/19288]: UST app adding context to channel channel0 (in create_ust_app_channel_context() at ust-app.c:1941)
DEBUG3 - 14:54:52.153966 [19285/19288]: UST app context 5 allocated (in alloc_ust_app_ctx() at ust-app.c:965)
DEBUG2 - 14:54:52.154325 [19285/19288]: UST app context handle -1 created successfully for channel channel0 (in create_ust_channel_context() at ust-app.c:1112)
DEBUG1 - 14:54:52.154334 [19285/19288]: Context UST 5 added to channel channel0 (in add_uctx_to_channel() at context.c:134)
DEBUG1 - 14:54:52.154339 [19285/19288]: Sending response (size: 16, retcode: Success) (in thread_manage_clients() at main.c:4124)
DEBUG1 - 14:54:52.154348 [19285/19288]: Clean command context structure (in clean_command_ctx() at main.c:736)
DEBUG1 - 14:54:52.154352 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
DEBUG1 - 14:54:52.154394 [19285/19288]: Wait for client response (in thread_manage_clients() at main.c:4030)
DEBUG1 - 14:54:52.154403 [19285/19288]: Receiving data from client ... (in thread_manage_clients() at main.c:4075)
DEBUG1 - 14:54:52.154412 [19285/19288]: Processing client command 0 (in process_client_msg() at main.c:2768)
DEBUG1 - 14:54:52.154415 [19285/19288]: Getting session test by name (in process_client_msg() at main.c:2849)
DEBUG2 - 14:54:52.154418 [19285/19288]: Trying to find session by name test (in session_find_by_name() at session.c:169)
DEBUG3 - 14:54:52.154422 [19285/19288]: Consumer socket created (fd: 32) and added to output (in consumer_create_socket() at consumer.c:301)
DEBUG1 - 14:54:52.154426 [19285/19288]: Setting relayd for session test (in cmd_setup_relayd() at cmd.c:727)
DEBUG2 - 14:54:52.154431 [19285/19288]: UST app adding context to channel channel0 (in create_ust_app_channel_context() at ust-app.c:1941)
DEBUG2 - 14:54:52.154435 [19285/19288]: UST app adding context to channel channel0 (in create_ust_app_channel_context() at ust-app.c:1941)
Error: Context failed for channel channel0
DEBUG1 - 14:54:52.154440 [19285/19288]: Sending response (size: 16, retcode: UST context already exist) (in thread_manage_clients() at main.c:4124)
DEBUG1 - 14:54:52.154448 [19285/19288]: Clean command context structure (in clean_command_ctx() at main.c:736)
DEBUG1 - 14:54:52.154452 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
DEBUG1 - 14:54:52.154526 [19285/19288]: Wait for client response (in thread_manage_clients() at main.c:4030)
DEBUG1 - 14:54:52.154535 [19285/19288]: Receiving data from client ... (in thread_manage_clients() at main.c:4075)
DEBUG1 - 14:54:52.154553 [19285/19288]: Processing client command 0 (in process_client_msg() at main.c:2768)
DEBUG1 - 14:54:52.154559 [19285/19288]: Getting session test by name (in process_client_msg() at main.c:2849)
DEBUG2 - 14:54:52.154562 [19285/19288]: Trying to find session by name test (in session_find_by_name() at session.c:169)
DEBUG3 - 14:54:52.154565 [19285/19288]: Consumer socket created (fd: 32) and added to output (in consumer_create_socket() at consumer.c:301)
DEBUG1 - 14:54:52.154569 [19285/19288]: Setting relayd for session test (in cmd_setup_relayd() at cmd.c:727)
DEBUG2 - 14:54:52.154573 [19285/19288]: UST app adding context to channel channel0 (in create_ust_app_channel_context() at ust-app.c:1941)
DEBUG2 - 14:54:52.154577 [19285/19288]: UST app adding context to channel channel0 (in create_ust_app_channel_context() at ust-app.c:1941)
Error: Context failed for channel channel0
DEBUG1 - 14:54:52.154581 [19285/19288]: Sending response (size: 16, retcode: UST context already exist) (in thread_manage_clients() at main.c:4124)
DEBUG1 - 14:54:52.154589 [19285/19288]: Clean command context structure (in clean_command_ctx() at main.c:736)
DEBUG1 - 14:54:52.154593 [19285/19288]: Accepting client command ... (in thread_manage_clients() at main.c:3988)
_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
A message that is not in the archive (sent off-list or not yet received): CAEFm6egRY89XiJDAeHZWfrThWsM_3KKxzDS17fj7FEpQEyjdZw@mail.gmail.com
Quoted 7 lines · Alexander Grigoriev
Hi Jérémie,
"lttng add-context" should not fail when several unique performance counters added after start program with tracepoints. Now "lttng add-context" fail when several unique
perf_treadcontext added after start program with tracepoints.
Alright. Read on for comments about the fix.
Quoted 110 lines
I wrote about this problem:
---------- Forwarded message ----------
From: Alexander Grigoriev <[email protected]>
Date: Tue, Sep 30, 2014 at 4:23 PM
Subject: Problem with perf:thread in 2.5
To: [email protected]Hello,
I use lttng-2.5 and linux-3.8.13. When I try to add context with several performance counters after start program with tracepoints, I get the following error:
Quoted 1 line
app_with_lttng& // {tracepoint(test, test, 1); sleep(1000); }[1] 19297
Quoted 1 line
lttng destroy -a
No session found, nothing to do.
Quoted 1 line
lttng -vvv create test
DEBUG3 - 14:54:42.713573 [19313/19313]: URI string:
file:///home/alexgri/lttng-traces/test-20140930-145442 (inuri_parse()at uri.c:293)
DEBUG3 - 14:54:42.713607 [19313/19313]: URI file destination:/home/alexgri/lttng-traces/test-20140930-145442(inuri_parse()at uri.c:330)
DEBUG3 - 14:54:42.713616 [19313/19313]: URI dtype: 3, proto: 0, host: ,
subdir: , ctrl: 0, data: 0 (inuri_parse()at uri.c:507)
DEBUG1 - 14:54:42.713667 [19313/19313]: LSM cmd type : 8 (insend_session_msg()at lttng-ctl.c:131)
Session test created.
Traces will be written in/home/alexgri/lttng-traces/test-20140930-145442DEBUG1 - 14:54:42.715819 [19313/19313]: Init config session in/home/alexgri(inconfig_init()at conf.c:295)Quoted 2 lines
lttng -vvv add-context -u -t vpid -t perf:thread:cpu-cycles -t perf:thread:instructions -t perf:thread:cache-misses -s test
DEBUG1 - 14:54:52.124745 [19316/19316]: Adding context... (in
add_context()atcommands/add_context.c:600)
DEBUG1 - 14:54:52.133393 [19316/19316]: LSM cmd type : 0 (insend_session_msg()at lttng-ctl.c:131)
UST context vpid added to all channels
DEBUG1 - 14:54:52.153445 [19316/19316]: Adding context... (inadd_context()atcommands/add_context.c:600)
DEBUG1 - 14:54:52.153499 [19316/19316]: LSM cmd type : 0 (insend_session_msg()at lttng-ctl.c:131)
UST context perf:thread:cpu-cycles added to all channels
DEBUG1 - 14:54:52.154356 [19316/19316]: Adding context... (inadd_context()atcommands/add_context.c:600)
DEBUG1 - 14:54:52.154392 [19316/19316]: LSM cmd type : 0 (insend_session_msg()at lttng-ctl.c:131)
Error: perf:thread:instructions: UST context already exist DEBUG1 - 14:54:52.154469 [19316/19316]: Adding context... (inadd_context()atcommands/add_context.c:600)
DEBUG1 - 14:54:52.154525 [19316/19316]: LSM cmd type : 0 (insend_session_msg()at lttng-ctl.c:131)
Error: perf:thread:cache-misses: UST context already exist
Warning: Some command(s) went wrong
DEBUG1 - 14:54:52.154620 [19316/19316]: Clean exit (inclean_exit()at lttng.c:167)'lttng-sessiond -vvv' logs in attachment
Thanks,
Alexander
---------------------------------------------------Thanks,
AlexanderQuoted 35 lines · Jérémie Galarneau
Hi Alexander,
Just to make sure I understand the problem, is your point that "lttng add-context" should not fail when multiple contexts are added just because one of them was already present? If not, could you provide a log demonstrating the issue?
Thanks!
JérémieQuoted 22 lines · Alexander Grigoriev
In commit
aa3514e96f12c13f681a81ea275dc51dd63473c8not removed old check for duplicate context type increate_ust_app_channel_context()function. If
the one ofperf_treadcontexts was already added, in the next similar operation function returns error code EEXIST "UST context already exist".Signed-off-by Alexander Grigoriev <[email protected]>--- src/bin/lttng-sessiond/ust-app.c | 7 ------- 1 file changed, 7 deletions(-)src/bin/lttng-sessiond/ust-app.c +0
-0@@ -1940,13 +1940,6 @@ int create_ust_app_channel_context(struct ust_app_session *ua_sess,DBG2 ("UST app adding context to channel %s" , ua_chan->name);
Quoted 8 lines
Quoted 8 lines
src/bin/lttng-sessiond/ust-app.c int create_ust_app_channel_context(struct · line 1951
Quoted 8 lines
src/bin/lttng-sessiond/ust-app.c +0
-7-lttng_ht_lookup (ua_chan->ctx, (void *)((unsigned long)uctx->ctx), &iter); - node =lttng_ht_iter_get_node_ulong (&iter); -if (node !=NULL ) { - ret = -EEXIST ; - goto error; - } -
The fix is a bit more complex than removing this check since we do want to return an error when a user adds a context which has already been enabled in a given channel.
Basically, that part of the code is fine as is, but the matching function must be changed to account for both the context type and the perf thread counter name when the context type is LTTNG_UST_CONTEXT_PERF_THREAD_COUNTER.
I have implemented a fix in master as:
commit 6a6b20683ccf29e16baceef5d29357001c2c713a
Author: Jérémie Galarneau <[email protected]> Date: Thu Nov 6 17:34:08 2014 -0500
Fix: check userspace perf counter name when looking up contexts
create_ust_app_channel_context() looks for a context's existance in a channel before adding it. However, it only checks for context types. This is valid for all context types except for LTTNG_UST_CONTEXT_PERF_THREAD_COUNTER since multiple perf thread counters may be enabled at the same time.
This fix ensures that the perf counter name is taken into consideration when checking for a context's presence in a channel.
Would you mind testing it? I'll backport it to the affected stable branches if it fixes the problem.
Thanks!
Jérémie
Quoted 20 lines
Quoted 18 lines
Quoted 11 lines
src/bin/lttng-sessiond/ust-app.c +0
-0ua_ctx =alloc_ust_app_ctx (uctx);if (ua_ctx == NULL) { /* malloc failed */--
1.9.1_______________________________________________
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
Signature · 8 lines
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