Support per UID buffers
authorDavid Goulet <dgoulet@efficios.com>
Thu, 7 Mar 2013 20:39:10 +0000 (15:39 -0500)
committerDavid Goulet <dgoulet@efficios.com>
Thu, 21 Mar 2013 16:29:43 +0000 (12:29 -0400)
commit7972aab22f74b18faa168c0482216a3dd711a075
treef359040de36b36a196b8ed29035b0320981b7294
parent45893984238b2e2c12fc0d84b90336c98a6d98c9
Support per UID buffers

This is a rather large commit. It adds the support for per UID buffers
for the user space tracer.

The --buffers-uid option is added to the lttng enable-channel command
which will set the session to use per UID buffers. So, all other channel
in that session MUST be set with the same buffer type or else an error
will be returned. For instance, here is an invalid use case:

$ lttng create
$ lttng enable-channel -u --buffers-uid chan1
$ lttng enable-channel -u chan2

The default is per PID (--buffers-pid). With no buffer type option, the
per PID is used for the UST tracer and global buffers for the kernel
being the only supported type for it (--buffers-global).

The tracing directory path are also changed to support this. For per UID
buffers, the path is now:

~/lttng-traces/ust/uid/1000/64-bit/*

For per PID buffers:

~/lttng-traces/<session_name>-<date>-<time>/ust/pid/ \
<app-name>-<pid>-<date>-<time>/

So basically, for UID, traces are stored per UID/ABI and for PID is
simply stored with the app name and pid. The kernel traces are untouched
and are still in kernel/.

Tests are also added for per UID buffers.

Acked-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
55 files changed:
configure.ac
doc/man/lttng.1
include/lttng/lttng-error.h
include/lttng/lttng.h
src/bin/lttng-sessiond/Makefile.am
src/bin/lttng-sessiond/buffer-registry.c [new file with mode: 0644]
src/bin/lttng-sessiond/buffer-registry.h [new file with mode: 0644]
src/bin/lttng-sessiond/channel.c
src/bin/lttng-sessiond/channel.h
src/bin/lttng-sessiond/cmd.c
src/bin/lttng-sessiond/cmd.h
src/bin/lttng-sessiond/consumer.c
src/bin/lttng-sessiond/consumer.h
src/bin/lttng-sessiond/event.c
src/bin/lttng-sessiond/event.h
src/bin/lttng-sessiond/kernel-consumer.c
src/bin/lttng-sessiond/lttng-ust-abi.h
src/bin/lttng-sessiond/lttng-ust-ctl.h
src/bin/lttng-sessiond/lttng-ust-error.h
src/bin/lttng-sessiond/main.c
src/bin/lttng-sessiond/session.h
src/bin/lttng-sessiond/trace-ust.c
src/bin/lttng-sessiond/trace-ust.h
src/bin/lttng-sessiond/ust-app.c
src/bin/lttng-sessiond/ust-app.h
src/bin/lttng-sessiond/ust-consumer.c
src/bin/lttng-sessiond/ust-consumer.h
src/bin/lttng-sessiond/ust-ctl.h
src/bin/lttng-sessiond/ust-metadata.c
src/bin/lttng-sessiond/ust-registry.c
src/bin/lttng-sessiond/ust-registry.h
src/bin/lttng/commands/enable_channels.c
src/bin/lttng/commands/enable_events.c
src/common/consumer.c
src/common/consumer.h
src/common/defaults.h
src/common/error.c
src/common/hashtable/hashtable.c
src/common/hashtable/hashtable.h
src/common/sessiond-comm/sessiond-comm.h
src/common/ust-consumer/ust-consumer.c
tests/regression/tools/streaming/test_kernel
tests/regression/tools/streaming/test_ust
tests/regression/ust/buffers-uid/Makefile.am [new file with mode: 0644]
tests/regression/ust/buffers-uid/gen-nevents.c [new file with mode: 0644]
tests/regression/ust/buffers-uid/test_buffers_uid [new file with mode: 0755]
tests/regression/ust/buffers-uid/tp.c [new file with mode: 0644]
tests/regression/ust/buffers-uid/ust_gen_nevents.h [new file with mode: 0644]
tests/regression/ust/nprocesses/test_nprocesses
tests/regression/ust/overlap/test_overlap
tests/regression/ust/run.sh
tests/unit/Makefile.am
tests/unit/test_kernel_data.c
tests/unit/test_session.c
tests/unit/test_ust_data.c
This page took 0.034159 seconds and 5 git commands to generate.