Project

General

Profile

Actions

Bug #375

closed

Memory leaks in lttng-sessiond

Added by Anas Alkhatib over 11 years ago. Updated over 11 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Target version:
Start date:
10/16/2012
Due date:
% Done:

0%

Estimated time:

Description

Created a number of sessions using filters, activated and deactivated.

Git commit:
lttng-tools 4dbc372 (HEAD, origin/master, origin/HEAD, master) ABI with support for compat 32/64 bits

Valgrind log:

pkill lttng-sessiond; LTTNG_DEBUG_NOCLONE=1 /opt/valgrind/bin/valgrind --leak-check=full /usr/bin/lttng-sessiond
15385 Memcheck, a memory error detector
15385 Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al.
15385 Using Valgrind-3.8.1 and LibVEX; rerun with -h for copyright info
15385 Command: /usr/bin/lttng-sessiond
15385
FATAL: Module lttng_tracer not found.
Error: Unable to load module lttng-tracer
Error: Unable to remove module lttng-tracer
Warning: No kernel tracer available
PERROR: failed to set open files limit: Operation not permitted [in set_ulimit() at main.c:3673]
Warning: No tracing group detected
15385 Thread 3:
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ? (in /usr/bin/lttng-sessiond)
15385 by 0x417082: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x418B00: ? (in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0x9a33b48 is on thread 3's stack
15385
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x418B1B: ? (in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0x9a33b58 is on thread 3's stack
15385
15385 Thread 6:
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x417082: ? (in /usr/bin/lttng-sessiond)
15385 by 0x41B243: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0xb236b28 is on thread 6's stack
15385
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ? (in /usr/bin/lttng-sessiond)
15385 by 0x41B25E: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0xb236b38 is on thread 6's stack
15385
15385 Thread 7:
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ? (in /usr/bin/lttng-sessiond)
15385 by 0x417082: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x41AADD: ? (in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0xba37c18 is on thread 7's stack
15385
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x41AAFA: ? (in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0xba37c28 is on thread 7's stack
15385
15385 Thread 2:
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x417082: ? (in /usr/bin/lttng-sessiond)
15385 by 0x41A54F: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0x9232b58 is on thread 2's stack
15385
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ? (in /usr/bin/lttng-sessiond)
15385 by 0x41A562: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0x9232b68 is on thread 2's stack
15385
15385 Thread 5:
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ? (in /usr/bin/lttng-sessiond)
15385 by 0x417082: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x41B856: ? (in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0xaa35b38 is on thread 5's stack
15385
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x41B871: ? (in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0xaa35b48 is on thread 5's stack
15385
15385 Thread 8:
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x417082: ? (in /usr/bin/lttng-sessiond)
15385 by 0x41838D: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0x13238b68 is on thread 8's stack
15385
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ? (in /usr/bin/lttng-sessiond)
15385 by 0x4183A8: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0x13238b78 is on thread 8's stack
15385
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ? (in /usr/bin/lttng-sessiond)
15385 by 0x41882E: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0x13238b78 is on thread 8's stack
15385

15385 Thread 6:
15385 Syscall param epoll_ctl(event) points to uninitialised byte(s)
15385 at 0x5F891FA: epoll_ctl (in /lib64/libc-2.11.3.so)
15385 by 0x42040F: ? (in /usr/bin/lttng-sessiond)
15385 by 0x41B674: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385 Address 0xb236b38 is on thread 6's stack
15385
^CError: Unable to remove module lttng-probe-lttng
Error: Unable to remove module lttng-ring-buffer-metadata-mmap-client
Error: Unable to remove module lttng-ring-buffer-client-mmap-overwrite
Error: Unable to remove module lttng-ring-buffer-client-mmap-discard
Error: Unable to remove module lttng-ring-buffer-metadata-client
Error: Unable to remove module lttng-ring-buffer-client-overwrite
Error: Unable to remove module lttng-ring-buffer-client-discard
Error: Unable to remove module lttng-lib-ring-buffer
Error: Unable to remove module lttng-tracer
15385
15385 HEAP SUMMARY:
15385 in use at exit: 5,569,779 bytes in 1,085 blocks
15385 total heap usage: 15,288 allocs, 14,203 frees, 42,472,237 bytes allocated
15385
15385 Thread 1:
15385 320 bytes in 1 blocks are possibly lost in loss record 4 of 12
15385 at 0x4C26B03: calloc (vg_replace_malloc.c:593)
15385 by 0x40114AE: _dl_allocate_tls (in /lib64/ld-2.11.3.so)
15385 by 0x5C9B045: pthread_create@GLIBC_2.2.5 (in /lib64/libpthread-2.11.3.so)
15385 by 0x41611A: ? (in /usr/bin/lttng-sessiond)
15385 by 0x5ECFC35: (below main) (in /lib64/libc-2.11.3.so)
15385
15385 320 bytes in 1 blocks are possibly lost in loss record 5 of 12
15385 at 0x4C26B03: calloc (vg_replace_malloc.c:593)
15385 by 0x40114AE: _dl_allocate_tls (in /lib64/ld-2.11.3.so)
15385 by 0x5C9B045: pthread_create
@GLIBC_2.2.5 (in /lib64/libpthread-2.11.3.so)
15385 by 0x418082: ? (in /usr/bin/lttng-sessiond)
15385 by 0x41A2BF: ? (in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385
15385 320 bytes in 1 blocks are possibly lost in loss record 6 of 12
15385 at 0x4C26B03: calloc (vg_replace_malloc.c:593)
15385 by 0x40114AE: _dl_allocate_tls (in /lib64/ld-2.11.3.so)
15385 by 0x5C9B045: pthread_create@@GLIBC_2.2.5 (in /lib64/libpthread-2.11.3.so)
15385 by 0x545ECF5: ?
(in /usr/lib64/liburcu.so.1.0.0)
15385 by 0x545EE42: get_default_call_rcu_data_mb (in /usr/lib64/liburcu.so.1.0.0)
15385 by 0x545F328: call_rcu_mb (in /usr/lib64/liburcu.so.1.0.0)
15385 by 0x40E31C: ? (in /usr/bin/lttng-sessiond)
15385 by 0x40E3A4: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x40C5FC: ? (in /usr/bin/lttng-sessiond)
15385 by 0x4197B5: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385
15385 116,960 (4,128 direct, 112,832 indirect) bytes in 172 blocks are definitely lost in loss record 10 of 12
15385 at 0x4C26B03: calloc (vg_replace_malloc.c:593)
15385 by 0x5043F9B: lttng_ht_new (in /usr/lib64/liblttng-ctl.so.0.0.0)
15385 by 0x408CC5: ? (in /usr/bin/lttng-sessiond)
15385 by 0x408FDD: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x417436: ? (in /usr/bin/lttng-sessiond)
15385 by 0x419FC4: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385
15385 1,798,428 bytes in 219 blocks are definitely lost in loss record 11 of 12
15385 at 0x4C26B03: calloc (vg_replace_malloc.c:593)
15385 by 0x4197EC: ? (in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385
15385 3,653,280 (3,536,320 direct, 116,960 indirect) bytes in 172 blocks are definitely lost in loss record 12 of 12
15385 at 0x4C26B03: calloc (vg_replace_malloc.c:593)
15385 by 0x408CA1: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x40EDF3: ? (in /usr/bin/lttng-sessiond)
15385 by 0x419F80: ?
(in /usr/bin/lttng-sessiond)
15385 by 0x5C9B7B5: start_thread (in /lib64/libpthread-2.11.3.so)
15385 by 0x5F88BCC: clone (in /lib64/libc-2.11.3.so)
15385
15385 LEAK SUMMARY:
15385 definitely lost: 5,338,876 bytes in 563 blocks
15385 indirectly lost: 229,792 bytes in 516 blocks
15385 possibly lost: 960 bytes in 3 blocks
15385 still reachable: 151 bytes in 3 blocks
15385 suppressed: 0 bytes in 0 blocks
15385 Reachable blocks (those to which a pointer was found) are not shown.
15385 To see them, rerun with: --leak-check=full --show-reachable=yes
15385
15385 For counts of detected and suppressed errors, rerun with: -v
15385 Use --track-origins=yes to see where uninitialised values come from
15385 ERROR SUMMARY: 123 errors from 20 contexts (suppressed: 4 from 4)
Actions #1

Updated by David Goulet over 11 years ago

  • Status changed from New to Confirmed
  • Priority changed from High to Normal

We are aware of possible memory leaks in the session daemon and relayd. Before 2.1-stable release, they will be fixed.

I'm changing the priority to this one to Normal since it does not break any features.

Thanks for the valgrind report!

Actions #2

Updated by David Goulet over 11 years ago

A lot of fixes were pushed upstream.

I'm keeping this bug open to remind us to check for memory leaks before any stable release.

Thanks!

Actions #3

Updated by David Goulet over 11 years ago

  • Status changed from Confirmed to In Progress
Actions #4

Updated by David Goulet over 11 years ago

  • Status changed from In Progress to Resolved

We are about to release 2.1-stable and memory leaks were audited.

If you find more at some point in time, don't hesitate to open back this bug or a new one!

Actions

Also available in: Atom PDF