LTTng logger ABI
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Sat, 15 Feb 2014 21:59:09 +0000 (16:59 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Tue, 11 Mar 2014 01:23:39 +0000 (21:23 -0400)
commit0c95667685cf8612eb0d231883874c173b7bb5a1
treecb100b0b6c4c7c274973ef52d1d1e414c9dcea88
parentfb2c37799306d16fb590aebee6fad8be431264b7
LTTng logger ABI

Add a user-space ABI (new file /proc/lttng-logger) to lttng-modules
which can be written into by any user on the system. The content is
saved into the kernel trace stream into the "lttng_logger" kernel event.

The content of a single write is written into an lttng_logger event.
The write count is truncated to 1024 bytes (if larger), which is much
smaller than the smallest subbuffer size available (4096 bytes). This
ensures all written data makes it into the active tracing buffers.

Example use:

lttng-sessiond -d # (as root)
lttng create
lttng enable-event -k lttng_logger
lttng start

echo -n "this is a test" > /proc/lttng-logger

lttng stop
lttng view

Example result:

[17:00:04.251970425] (+179.750663203) thinkos lttng_logger: { cpu_id = 3 }, { _msg_length = 14, msg = "this is a test" }

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
CC: Karim Yaghmour <karim.yaghmour@opersys.com>
Makefile
instrumentation/events/lttng-module/lttng.h [new file with mode: 0644]
lttng-events.c
lttng-events.h
probes/lttng.c [new file with mode: 0644]
This page took 0.02511 seconds and 4 git commands to generate.