See LTTng-modules's
4d32837 ("Add a new /dev/lttng-logger interface")
commit.
Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
The LTTng Documentation
=======================
Philippe Proulx <pproulx@efficios.com>
The LTTng Documentation
=======================
Philippe Proulx <pproulx@efficios.com>
include::../common/copyright.txt[]
include::../common/copyright.txt[]
+
This change makes the tracer more efficient on NUMA systems.
+
This change makes the tracer more efficient on NUMA systems.
+* The <<proc-lttng-logger-abi,LTTng logger>> kernel module now also
+ creates a ``misc'' device named `lttng-logger`, which udev will
+ make accessible as the path:{/dev/lttng-logger} special file.
++
+The `lttng-logger` device shares the `/proc/lttng-logger` file's ABI,
+but it works from within containers when the path is made accessible to
+them.
+
[[nuts-and-bolts]]
== Nuts and bolts
[[nuts-and-bolts]]
== Nuts and bolts
* The _LTTng logger_ module.
+
The LTTng logger module implements the special path:{/proc/lttng-logger}
* The _LTTng logger_ module.
+
The LTTng logger module implements the special path:{/proc/lttng-logger}
-file so that any executable can generate LTTng events by opening and
-writing to this file.
+(and path:{/dev/lttng-logger} since LTTng{nbsp}2.11) files so that any
+executable can generate LTTng events by opening and writing to those
+files.
+
See <<proc-lttng-logger-abi,LTTng logger>>.
+
See <<proc-lttng-logger-abi,LTTng logger>>.
=== LTTng logger
The `lttng-tracer` Linux kernel module, part of
=== LTTng logger
The `lttng-tracer` Linux kernel module, part of
-<<lttng-modules,LTTng-modules>>, creates the special LTTng logger file
-path:{/proc/lttng-logger} when it's loaded. Any application can write
-text data to this file to emit an LTTng event.
+<<lttng-modules,LTTng-modules>>, creates the special LTTng logger files
+path:{/proc/lttng-logger} and path:{/dev/lttng-logger} (since
+LTTng{nbsp}2.11) when it's loaded. Any application can write text data
+to any of those files to emit an LTTng event.
[role="img-100"]
.An application writes to the LTTng logger file to emit an LTTng event.
[role="img-100"]
.An application writes to the LTTng logger file to emit an LTTng event.
-$ echo "Some message, some $variable" > /proc/lttng-logger
+$ echo "Some message, some $variable" > /dev/lttng-logger
----
Any event that the LTTng logger emits is named `lttng_logger` and
----
Any event that the LTTng logger emits is named `lttng_logger` and
-* From any application, write text data to the path:{/proc/lttng-logger}
+* From any application, write text data to the path:{/dev/lttng-logger}
file.
The `msg` field of `lttng_logger` event records contains the
file.
The `msg` field of `lttng_logger` event records contains the
[source,bash]
.path:{test.bash}
----
[source,bash]
.path:{test.bash}
----
-echo 'Hello, World!' > /proc/lttng-logger
+echo 'Hello, World!' > /dev/lttng-logger
-df --human-readable --print-type / > /proc/lttng-logger
+df --human-readable --print-type / > /dev/lttng-logger
----
<<creating-destroying-tracing-sessions,Create a tracing session>>,
----
<<creating-destroying-tracing-sessions,Create a tracing session>>,