lttng-tools.git
10 years agoUpdate version to v2.2.6 stable-2.2 v2.2.6
David Goulet [Fri, 28 Feb 2014 17:55:41 +0000 (12:55 -0500)] 
Update version to v2.2.6

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: remove break in epoll loop of apps. thread
David Goulet [Wed, 18 Dec 2013 23:34:44 +0000 (18:34 -0500)] 
Fix: remove break in epoll loop of apps. thread

In *heavy* stress test with a large number of applications (> 7000 a
second), the manage application thread could starve the delete process
by breaking just after adding an application to the poll set.

Also, we've observed that somehow the application unregister process is
not done on most of the application by breaking the loop at each delete
from the poll set. We are still uncertain why but one theory is that
epoll detects that an I/O operation is ready (here a shutdown) and an
other subsystem of the session daemon uses that socket for I/O which
flags the poll event as "has been taken care of" thus the loop never
sees it because of that break.

The notify socket thread does not use a break between poll operation
which leads us to that conclusion with the manage apps thread.

We don't use epoll with edge-trigger thus a POLLERR/POLLHUP should
always be return as long as it's not taken care of.

Acked-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: remove bad code from previous backport patch
David Goulet [Tue, 3 Dec 2013 19:39:29 +0000 (14:39 -0500)] 
Fix: remove bad code from previous backport patch

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: bad logical check of error codes
David Goulet [Tue, 3 Dec 2013 16:35:31 +0000 (11:35 -0500)] 
Fix: bad logical check of error codes

Fixes #701

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: resource leak in enable-event command
David Goulet [Thu, 28 Nov 2013 21:02:14 +0000 (16:02 -0500)] 
Fix: resource leak in enable-event command

Fix coverity issue 1129187.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: unchecked return value in ust app delete
David Goulet [Thu, 28 Nov 2013 20:55:05 +0000 (15:55 -0500)] 
Fix: unchecked return value in ust app delete

Fix coverity issue 1132897.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: dereference after null check in UST registry
David Goulet [Thu, 28 Nov 2013 20:52:25 +0000 (15:52 -0500)] 
Fix: dereference after null check in UST registry

Fix coverity issue 1132896.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: Resource leak in ust registry
David Goulet [Thu, 28 Nov 2013 20:40:44 +0000 (15:40 -0500)] 
Fix: Resource leak in ust registry

Fix coverity issue 1019918.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: backported from urcu commit 92af1a30
David Goulet [Thu, 28 Nov 2013 19:55:07 +0000 (14:55 -0500)] 
Fix: backported from urcu commit 92af1a30

commit 92af1a30ca6a70945b167c31631c8598a626c71a
Author: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Date:   Thu Nov 28 18:41:13 2013 +0100

    Fix undefined NULL pointer arithmetic

    Clang 3.3 with -O2 optimisations is especially picky about arithmetic
    on NULL pointers. This undefined behavior is turned into optimized out
    NULL checks by clang 3.3. Fix the undefined behavior by checking against
    the pointer directly, without going back and forth around NULL with
    pointer arithmetic.

Reported-by: Zifei Tong <soariez@gmail.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: add missing values for a backported fix
David Goulet [Thu, 28 Nov 2013 20:15:16 +0000 (15:15 -0500)] 
Fix: add missing values for a backported fix

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: update back the metadata len sent on failure
David Goulet [Thu, 28 Nov 2013 18:20:15 +0000 (13:20 -0500)] 
Fix: update back the metadata len sent on failure

Acked-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: don't fail on push metadata if no channel
David Goulet [Thu, 28 Nov 2013 18:08:10 +0000 (13:08 -0500)] 
Fix: don't fail on push metadata if no channel

The comments in the code explains it well but in a nutshell, this is an
acceptable race between the creation of the metadata on the consumer
side and the push metadata from the session daemon for that channel.

This race is resolved by either having the consumer requesting metadata
or the session is stopped which will in both situation push the metadata
to the consumer.

Without that fix, the session daemon flags the registry's metadata to be
"closed" which usually indicates that the consumer is not responding
leading to the consumer thread exiting in the session daemon.

Acked-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: comparison of unsigned enum expression >= 0
David Goulet [Mon, 25 Nov 2013 19:15:51 +0000 (14:15 -0500)] 
Fix: comparison of unsigned enum expression >= 0

Signed-off-by: David Goulet <dgoulet@efficios.com>
Conflicts:
src/common/ust-consumer/ust-consumer.c

10 years agoFix: implicit conversion of enum types in sessiond
David Goulet [Mon, 25 Nov 2013 20:06:13 +0000 (15:06 -0500)] 
Fix: implicit conversion of enum types in sessiond

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: comparison of unsigned value agains < 0
David Goulet [Mon, 25 Nov 2013 19:15:17 +0000 (14:15 -0500)] 
Fix: comparison of unsigned value agains < 0

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoAdd libuuid as dependency in README
Zifei Tong [Mon, 25 Nov 2013 12:40:41 +0000 (20:40 +0800)] 
Add libuuid as dependency in README

Signed-off-by: Zifei Tong <soariez@gmail.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoUpdate version to v2.2.5 v2.2.5
David Goulet [Fri, 15 Nov 2013 15:53:19 +0000 (10:53 -0500)] 
Update version to v2.2.5

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: typo in --sig-parent help
David Goulet [Tue, 12 Nov 2013 14:56:45 +0000 (09:56 -0500)] 
Fix: typo in --sig-parent help

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: application SIGBUS when starting in parallel with sessiond
David Goulet [Wed, 6 Nov 2013 15:49:43 +0000 (10:49 -0500)] 
Fix: application SIGBUS when starting in parallel with sessiond

There is a race between application startup and sessiond startup, where there
is an intermediate state where applications can SIGBUS if they see a zero-sized
shm, if the shm has been created, but not ftruncated yet.

On the sessiond side, we need to ensure that the shared memory is writeable by
applications as long as its size is 0, which allow applications to perform
ftruncate and extend its size.

On the UST side, another commit needs to ensure that UST can read the shared
memory file descriptor with a read() system call before they try accessing it
through a memory map (which triggers the SIGBUS if the access goes beyond the
file size)

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: arguments in the wrong order for fd-limit
David Goulet [Mon, 4 Nov 2013 18:19:06 +0000 (13:19 -0500)] 
Fix: arguments in the wrong order for fd-limit

This is related to a bug we've been seeing with a very HIGH load of
applications registering at the same time where the get/put counters get
out of sync. exhausting the fd pool quite rapidely even though there was
no fd leak.

Acked-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: recv creds comm should handle partial receive
David Goulet [Fri, 11 Oct 2013 20:02:13 +0000 (16:02 -0400)] 
Fix: recv creds comm should handle partial receive

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: backported fix uses msec vs sec in stable-2.2
David Goulet [Fri, 11 Oct 2013 19:35:39 +0000 (15:35 -0400)] 
Fix: backported fix uses msec vs sec in stable-2.2

In stable-2.2, setting the timeout expects seconds and not msec like in
stable-2.3 and above. This fixes the previous commit that was backported
from master.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: set app socket timeout just after accept()
David Goulet [Fri, 11 Oct 2013 18:59:45 +0000 (14:59 -0400)] 
Fix: set app socket timeout just after accept()

This is to make sure the socket has a timeout *before* doing any I/O
operations on it.

Signed-off-by: David Goulet <dgoulet@efficios.com>
Conflicts:
src/bin/lttng-sessiond/main.c

10 years agoUpdate version to v2.2.4 v2.2.4
David Goulet [Fri, 30 Aug 2013 18:52:29 +0000 (14:52 -0400)] 
Update version to v2.2.4

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: hashtable: take split_count_order into account
Mathieu Desnoyers [Fri, 30 Aug 2013 18:31:48 +0000 (14:31 -0400)] 
Fix: hashtable: take split_count_order into account

This makes check_resize() handle split-counters more precisely.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: remove wrong doing asserts in sessiond
David Goulet [Fri, 30 Aug 2013 14:04:16 +0000 (10:04 -0400)] 
Fix: remove wrong doing asserts in sessiond

Asserting on the fd and socket was wrong since the two fds can be set to
-1 concurrently when calling this function.

Fixes #624

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: delete the trace directory used for the test
David Goulet [Thu, 29 Aug 2013 14:49:24 +0000 (10:49 -0400)] 
Fix: delete the trace directory used for the test

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: remove bad check after epoll wait in consumer
David Goulet [Thu, 29 Aug 2013 14:38:12 +0000 (10:38 -0400)] 
Fix: remove bad check after epoll wait in consumer

The returned nb_fd value is the number of FD ready for the requested I/O
so having and revents set to 0 is possible since not all fd are ready
thus making this check irrelevant and actually ressource consuming.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: consumer data pending for empty streams
Mathieu Desnoyers [Thu, 29 Aug 2013 02:47:20 +0000 (22:47 -0400)] 
Fix: consumer data pending for empty streams

We should at least output one packet before a stream can be considered
as readable. So far, for PID buffers, if an application exits at the
wrong timing before a stop waiting for data pending, empty streams could
be visible by a babeltrace executed after data pending incorrectly
returned false.

Fix it by considering a stream for which the consumerd has written 0
bytes to the output as having data pending.

This applies to 2.3-rc and stable-2.2.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: hash table growth (for small tables) should be limited (v2)
Mathieu Desnoyers [Tue, 27 Aug 2013 22:11:04 +0000 (18:11 -0400)] 
Fix: hash table growth (for small tables) should be limited (v2)

Buckets with many entries encountered in a hash table could cause it to
grow to a large size, beyond the scope for which this mechanism is
expected to play a role when node accounting is available. Indeed, when
the hash table grows to larger size, split-counter node accounting is
expected to deal with resize/shrink rather than relying on an heuristic
based on the largest bucket size.

This is fixing an issue where we see hash tables sometimes reaching 65k
entries index (65536*8 = 524288 bytes) for a workload limited to adding
1000 entries and then removing all of them, done in a loop (random
keys).

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: run_as gid/uid test should return result to parent
Mathieu Desnoyers [Tue, 27 Aug 2013 20:24:55 +0000 (16:24 -0400)] 
Fix: run_as gid/uid test should return result to parent

Failure to do so could cause the parent to hang on read() waiting for
the return value from the child.

Targets: 2.3-rc and stable-2.2 branches.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: remove health test from fast regression
David Goulet [Tue, 27 Aug 2013 19:44:04 +0000 (15:44 -0400)] 
Fix: remove health test from fast regression

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: set the health delta tcp timeout aware
David Goulet [Tue, 27 Aug 2013 19:23:18 +0000 (15:23 -0400)] 
Fix: set the health delta tcp timeout aware

The health check subsystem now initialized the time delta using the TCP
timeout. It takes the maximum value between our default internal delta
and the TCP timeout fetched by the lttcomm inet subsytem.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoGet the maximum TCP timeout in sessiond
David Goulet [Tue, 27 Aug 2013 19:11:40 +0000 (15:11 -0400)] 
Get the maximum TCP timeout in sessiond

This actually just open some /proc files when calling
lttcomm_init_inet() and computes the maximum value a TCP timeout for
every possible operations (send/recv/connect).

This is the first patch to fix the health check issue of having a
smaller delta than the TCP maximum possible timeout.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: don't report error if UST app dies
David Goulet [Tue, 27 Aug 2013 17:56:57 +0000 (13:56 -0400)] 
Fix: don't report error if UST app dies

An application dying unexpectedly is a normal behavior so the execution
must continue and not report an error when sending commands onto the
dying application.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: improve error message when UST support is disabled
Mathieu Desnoyers [Thu, 22 Aug 2013 21:48:59 +0000 (17:48 -0400)] 
Fix: improve error message when UST support is disabled

Fixes #583

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: remove calibrate syscall option from code
David Goulet [Thu, 22 Aug 2013 20:56:22 +0000 (16:56 -0400)] 
Fix: remove calibrate syscall option from code

Fixes #586

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: check UST float field mantissa length
Mathieu Desnoyers [Thu, 22 Aug 2013 20:05:58 +0000 (16:05 -0400)] 
Fix: check UST float field mantissa length

Fixes #473

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: add UST context in the same order the user enabled them
David Goulet [Wed, 21 Aug 2013 16:04:02 +0000 (12:04 -0400)] 
Fix: add UST context in the same order the user enabled them

This is to avoid having different field order in different traces for
the same contexts enabled in the same order by the user.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoPrepare for automake deprecation of missing subdir-objects
Mathieu Desnoyers [Fri, 16 Aug 2013 21:35:38 +0000 (17:35 -0400)] 
Prepare for automake deprecation of missing subdir-objects

Ensure old and new automake will behave in the same way.

Fixes #594

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: channels can be _enabled_ after tracing is started, but not created
Mathieu Desnoyers [Fri, 16 Aug 2013 20:58:02 +0000 (16:58 -0400)] 
Fix: channels can be _enabled_ after tracing is started, but not created

Fixes #619

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix filter parser segmentation fault with bison 3.0
Zifei Tong [Fri, 16 Aug 2013 20:52:21 +0000 (16:52 -0400)] 
Fix filter parser segmentation fault with bison 3.0

Replace deprecated YYLEX_PARAM with %lex-param

Tested with bison 2.4, 2.5, 2.7 and 3.0.

Signed-off-by: Zifei Tong <soariez@gmail.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: typo in error msg
Mathieu Desnoyers [Fri, 16 Aug 2013 20:50:43 +0000 (16:50 -0400)] 
Fix: typo in error msg

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: imprecise error message about root sessiond/tracing group
Mathieu Desnoyers [Fri, 16 Aug 2013 20:48:08 +0000 (16:48 -0400)] 
Fix: imprecise error message about root sessiond/tracing group

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: LTTNG_ERR_NEED_ROOT_SESSIOND error message
Jérémie Galarneau [Wed, 7 Aug 2013 18:58:05 +0000 (14:58 -0400)] 
Fix: LTTNG_ERR_NEED_ROOT_SESSIOND error message

A root session daemon _and_ "tracing" group user membership are required
to trace the kernel.

Acked-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: don't skip chmod if tracing group is not found
Mathieu Desnoyers [Fri, 16 Aug 2013 20:07:54 +0000 (16:07 -0400)] 
Fix: don't skip chmod if tracing group is not found

Fixes #620

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoTracepoint probes don't need extern C
Mathieu Desnoyers [Thu, 15 Aug 2013 18:11:16 +0000 (14:11 -0400)] 
Tracepoint probes don't need extern C

tracepoint.h has the proper extern C guards, so every liblttng-ust API
called from the probe has the proper linkage.

The rest of the symbols are only meaningful within the probe, so we
don't care if they are mangled or not.

This fixes all UST applications in tests/

Fixes #597

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: reset out_fd_offset when we rotate the trace file
Julien Desfossez [Tue, 13 Aug 2013 21:40:28 +0000 (17:40 -0400)] 
Fix: reset out_fd_offset when we rotate the trace file

This value is only used for the sync_file_range, but it has to be set
to 0 when we start to write in a new trace file, otherwise the values
passed to this call are bogus.

Applied to 2.3, but could probably be backported to 2.2.

Acked-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: kernel ctl error codes are based on errno
Mathieu Desnoyers [Mon, 5 Aug 2013 17:46:58 +0000 (13:46 -0400)] 
Fix: kernel ctl error codes are based on errno

ioctl returns -1, and error codes are based on -errno.

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoVersion 2.2.3 v2.2.3
Mathieu Desnoyers [Tue, 23 Jul 2013 14:18:06 +0000 (10:18 -0400)] 
Version 2.2.3

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agotest: test_periodical_metadata_flush shrink timer period, kill app
Mathieu Desnoyers [Sun, 21 Jul 2013 23:22:06 +0000 (19:22 -0400)] 
test: test_periodical_metadata_flush shrink timer period, kill app

Decrease the switch timer period to 100ms (instead of 1s), since we're
only getting 2s worth of app run. If the system is busy, nothing really
guarantee that the timer will indeed fire during this time-frame (so
strictly speaking, this test could still fail).

Also, kill the application before trying to read the trace: this should
ensure that the trace is not appended to concurrently with validation.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: format string type mismatch
Mathieu Desnoyers [Sun, 21 Jul 2013 23:07:35 +0000 (19:07 -0400)] 
Fix: format string type mismatch

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: tests: provide channel name when a non-default channel exists: per-pid
Mathieu Desnoyers [Fri, 19 Jul 2013 18:06:14 +0000 (14:06 -0400)] 
Fix: tests: provide channel name when a non-default channel exists: per-pid

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: tests: provide channel name when a non-default channel exists
Mathieu Desnoyers [Fri, 19 Jul 2013 17:59:39 +0000 (13:59 -0400)] 
Fix: tests: provide channel name when a non-default channel exists

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: data pending race
Mathieu Desnoyers [Fri, 19 Jul 2013 17:28:13 +0000 (13:28 -0400)] 
Fix: data pending race

There is a data pending race involving late population of the streams in
the stream hash table, and applying flush on streams that are not yet
globally visible.

This is caused by the fact that streams are added to the hash table only
when received by the data-handling consumer thread.

This results in data_pending() incorrectly returning that there is no
data pending in some cases.

This has been discovered by adding 1s delay in read subbuffer function
for testing.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoCleanup: ust-consumer: wrong indentation
Mathieu Desnoyers [Fri, 19 Jul 2013 15:29:14 +0000 (11:29 -0400)] 
Cleanup: ust-consumer: wrong indentation

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: print dots while waiting for data availability
Mathieu Desnoyers [Fri, 19 Jul 2013 14:36:52 +0000 (10:36 -0400)] 
Fix: print dots while waiting for data availability

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: push metadata on stop for per-UID buffers
Mathieu Desnoyers [Fri, 19 Jul 2013 12:59:12 +0000 (08:59 -0400)] 
Fix: push metadata on stop for per-UID buffers

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoVersion 2.2.2 v2.2.2
Mathieu Desnoyers [Wed, 17 Jul 2013 22:14:55 +0000 (18:14 -0400)] 
Version 2.2.2

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: set tracefile size test with PID buffers
David Goulet [Fri, 12 Jul 2013 21:16:41 +0000 (17:16 -0400)] 
Fix: set tracefile size test with PID buffers

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: Babelstats fail to parse output with no process name or pid
Christian Babeux [Fri, 12 Jul 2013 20:39:02 +0000 (16:39 -0400)] 
Fix: Babelstats fail to parse output with no process name or pid

The process name and pid are optionnal components in the babeltrace
text output.

Signed-off-by: Christian Babeux <christian.babeux@efficios.com>
10 years agoFix: kernel data unit test
David Goulet [Fri, 12 Jul 2013 17:47:12 +0000 (13:47 -0400)] 
Fix: kernel data unit test

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: don't send error to sessiond on orderly shutdown
David Goulet [Thu, 4 Jul 2013 20:31:27 +0000 (16:31 -0400)] 
Fix: don't send error to sessiond on orderly shutdown

The send always fail if the sessiond has closed the socket so no point
of trying to send an error.

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: consumer: incorrect size zmalloc
Mathieu Desnoyers [Thu, 4 Jul 2013 21:53:50 +0000 (17:53 -0400)] 
Fix: consumer: incorrect size zmalloc

Also, check return value.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: RCU read side lock unbalanced
David Goulet [Fri, 12 Jul 2013 14:23:28 +0000 (10:23 -0400)] 
Fix: RCU read side lock unbalanced

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix deadlock: don't take channel lock in timer
Mathieu Desnoyers [Tue, 16 Jul 2013 13:53:33 +0000 (09:53 -0400)] 
Fix deadlock: don't take channel lock in timer

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoIntroduce channel timer lock
Mathieu Desnoyers [Tue, 16 Jul 2013 13:36:59 +0000 (09:36 -0400)] 
Introduce channel timer lock

Currently a shadow of the channel lock. Will eventually be used to
protect channel timer handler from concurrent channel updates without
being held when the timer is stopped (future commit).

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Conflicts:
src/common/consumer-stream.c

10 years agodocument lttng_ustconsumer_request_metadata locking constraints
Mathieu Desnoyers [Tue, 16 Jul 2013 01:47:21 +0000 (21:47 -0400)] 
document lttng_ustconsumer_request_metadata locking constraints

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agodocument metadata_switch_timer() deadlock
Mathieu Desnoyers [Tue, 16 Jul 2013 01:15:05 +0000 (21:15 -0400)] 
document metadata_switch_timer() deadlock

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agodocument metadata_switch_timer() locking constraints
Mathieu Desnoyers [Tue, 16 Jul 2013 00:56:51 +0000 (20:56 -0400)] 
document metadata_switch_timer() locking constraints

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoconsumer: replace DBG2() instances by DBG()
Mathieu Desnoyers [Tue, 16 Jul 2013 00:18:13 +0000 (20:18 -0400)] 
consumer: replace DBG2() instances by DBG()

The consumer daemon does not currently support DBG2() printout.

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoust consumer: data_pending check is endpoint active
Mathieu Desnoyers [Tue, 16 Jul 2013 00:14:07 +0000 (20:14 -0400)] 
ust consumer: data_pending check is endpoint active

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: kernel consumer: data_pending check if endpoint active
Mathieu Desnoyers [Tue, 16 Jul 2013 00:12:30 +0000 (20:12 -0400)] 
Fix: kernel consumer: data_pending check if endpoint active

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoconsumer: explicitly set endpoint status to active at init
Mathieu Desnoyers [Tue, 16 Jul 2013 00:07:36 +0000 (20:07 -0400)] 
consumer: explicitly set endpoint status to active at init

Ensures we explicitly set active at init for channels that don't
interact with a relayd.

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agodocument consumer_metadata_cache_flushed use of consumer_data.lock
Mathieu Desnoyers [Tue, 16 Jul 2013 00:03:15 +0000 (20:03 -0400)] 
document consumer_metadata_cache_flushed use of consumer_data.lock

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoconsumer: introduce channel lock
Mathieu Desnoyers [Mon, 15 Jul 2013 23:45:24 +0000 (19:45 -0400)] 
consumer: introduce channel lock

Reviewed-by: Julien Desfossez <julien.desfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoMissing NULL pointer init in tap.c
Mathieu Desnoyers [Fri, 12 Jul 2013 15:41:08 +0000 (11:41 -0400)] 
Missing NULL pointer init in tap.c

Could lead to free() of unitialized pointer.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: Unchecked asprintf/vasprintf return values
Jérémie Galarneau [Fri, 12 Jul 2013 16:38:56 +0000 (12:38 -0400)] 
Fix: Unchecked asprintf/vasprintf return values

strp may be modified even in case of failure according to the
ASPRINTF(3) man page.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoUpdate version to v2.2.1 v2.2.1
David Goulet [Thu, 11 Jul 2013 21:41:08 +0000 (17:41 -0400)] 
Update version to v2.2.1

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: consumer err_sock cloexec
Mathieu Desnoyers [Wed, 10 Jul 2013 19:39:54 +0000 (15:39 -0400)] 
Fix: consumer err_sock cloexec

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: possible consumer sockets double close on cleanup
David Goulet [Tue, 9 Jul 2013 16:28:41 +0000 (12:28 -0400)] 
Fix: possible consumer sockets double close on cleanup

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: add gpl and lgpl files to tarball
David Goulet [Mon, 8 Jul 2013 15:25:52 +0000 (11:25 -0400)] 
Fix: add gpl and lgpl files to tarball

Fixes #581

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: don't install libtap system wide
David Goulet [Mon, 8 Jul 2013 15:23:44 +0000 (11:23 -0400)] 
Fix: don't install libtap system wide

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: close consumer sockets in sessiond cleanup
David Goulet [Fri, 5 Jul 2013 20:03:50 +0000 (16:03 -0400)] 
Fix: close consumer sockets in sessiond cleanup

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: print errno message on connect() error
David Goulet [Fri, 5 Jul 2013 16:01:10 +0000 (12:01 -0400)] 
Fix: print errno message on connect() error

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: possible double-close on stream out_fd
Mathieu Desnoyers [Thu, 4 Jul 2013 22:37:35 +0000 (18:37 -0400)] 
Fix: possible double-close on stream out_fd

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: session ID signess to uin64_t in sessiond
David Goulet [Thu, 4 Jul 2013 19:54:38 +0000 (15:54 -0400)] 
Fix: session ID signess to uin64_t in sessiond

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: consumer_add_relayd_socket() report errors to sessiond
Mathieu Desnoyers [Tue, 2 Jul 2013 19:14:02 +0000 (15:14 -0400)] 
Fix: consumer_add_relayd_socket() report errors to sessiond

Wait until the side-effect to relayd is actually performed before
replying that "all is fine" to sessiond.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: UST per-UID channels persist across application teardown
Mathieu Desnoyers [Tue, 2 Jul 2013 20:20:33 +0000 (16:20 -0400)] 
Fix: UST per-UID channels persist across application teardown

Fixes #582

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: add missing enum lttcomm_return_code entries
Mathieu Desnoyers [Tue, 2 Jul 2013 19:12:42 +0000 (15:12 -0400)] 
Fix: add missing enum lttcomm_return_code entries

Those should not appear as unknown.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: detect the correct version of LTTng-UST
David Goulet [Fri, 28 Jun 2013 18:35:09 +0000 (14:35 -0400)] 
Fix: detect the correct version of LTTng-UST

Fixes #580

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: sessiond: use uint64_t for all session ids
Mathieu Desnoyers [Fri, 28 Jun 2013 16:19:51 +0000 (12:19 -0400)] 
Fix: sessiond: use uint64_t for all session ids

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: consumer: use uint64_t for all sessiond_id
Mathieu Desnoyers [Fri, 28 Jun 2013 16:18:35 +0000 (12:18 -0400)] 
Fix: consumer: use uint64_t for all sessiond_id

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoFix: periodical flush check trace before stop
David Goulet [Fri, 28 Jun 2013 16:07:17 +0000 (12:07 -0400)] 
Fix: periodical flush check trace before stop

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: consumer: 64-bit index for relayd rather than 32-bit (v2)
Mathieu Desnoyers [Fri, 28 Jun 2013 15:26:04 +0000 (11:26 -0400)] 
Fix: consumer: 64-bit index for relayd rather than 32-bit (v2)

Relayd "unique" ids wrap every 32-bit, and in some cases, negative
values are considered as error.

Change this to make the error value specifically -1ULL, use a direct
comparison (since we use an unsigned 64-bit integer, comparison with 0
becomes incorrect).

Since we now use a 64-bit ID, it is assumed to _never_ wrap-around
(remember, value -1ULL is an _error_). Therefore,
consumer_add_relayd_socket() can become much more strict than it was:
instead of accepting re-use of net_seq_idx, we can now assert that upon
LTTNG_STREAM_CONTROL socket, we have indeed allocated a relayd object,
and upon LTTNG_STREAM_DATA, we have found a relayd object.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: send per-pid session id in channel creation
Julien Desfossez [Thu, 27 Jun 2013 21:57:06 +0000 (17:57 -0400)] 
Fix: send per-pid session id in channel creation

The registry indexing for per-pid sessions is done with a per-pid
session id. So for per-pid buffers, we need to send the per-pid session
id as well as the global session id to the consumer in order to give it
enough information if it needs to request metadata later.

This patch adds the session_id_per_pid to the channel creation message
and to the consumer. When the sessiond receives a metadata_request,
depending on the buffer type (per-pid or per-uid), it selects the right
id to do the registry lookup.

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoFix: consumer double-close on error
Mathieu Desnoyers [Thu, 27 Jun 2013 21:32:37 +0000 (17:32 -0400)] 
Fix: consumer double-close on error

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 years agoUpdate URCU detection to correctly check for a 0.7 version
Yannick Brosseau [Thu, 27 Jun 2013 21:03:29 +0000 (17:03 -0400)] 
Update URCU detection to correctly check for a 0.7 version

Signed-off-by: Yannick Brosseau <yannick.brosseau@gmail.com>
10 years agoFix: set hidden attribute to utils_* calls
David Goulet [Fri, 28 Jun 2013 14:30:18 +0000 (10:30 -0400)] 
Fix: set hidden attribute to utils_* calls

Signed-off-by: David Goulet <dgoulet@efficios.com>
10 years agoUpdate version to v2.2.0 v2.2.0
David Goulet [Tue, 25 Jun 2013 20:40:13 +0000 (16:40 -0400)] 
Update version to v2.2.0

Signed-off-by: David Goulet <dgoulet@efficios.com>
This page took 0.042284 seconds and 4 git commands to generate.