7 lttng-clear - Clear a tracing session
13 *lttng* ['linkgenoptions:(GENERAL OPTIONS)'] *clear* ['SESSION' | option:--all]
18 The `lttng clear` command clears one or more tracing sessions, that is,
19 it deletes the contents of their tracing buffers and all their local and
22 If no options are specified, the current tracing session is cleared
23 (see man:lttng-create(1) for more information about the current
26 If 'SESSION' is specified, the existing tracing session named 'SESSION'
29 With the option:--all option, *all* the tracing sessions, as listed in
30 the output of `lttng list` (see man:lttng-list(1)), are cleared.
32 If a tracing session is configured in snapshot mode (see the
33 man:lttng-create(1) command's nloption:--snapshot option), only the
34 tracing buffers are cleared.
36 For a given tracing session, if at least one rotation occurred (see
37 man:lttng-rotate(1)), only its tracing buffers and its current trace
38 chunk are cleared; its archived trace chunks are :not: cleared.
40 NOTE: The nloption:--disallow-clear option and the
41 `LTTNG_RELAYD_DISALLOW_CLEAR` environment variable of
42 man:lttng-relayd(8) can disable remote clearing operations. If LTTng
43 sends tracing data over the network for 'SESSION' (or for any tracing
44 session with the option:--all option) to a relay daemon configured as
45 such, `lttng clear` fails.
48 include::common-cmd-options-head.txt[]
53 option:-a, option:--all::
54 Clear all the tracing sessions instead of the current tracing
55 session or the tracing session named 'SESSION'.
58 include::common-cmd-help-options.txt[]
61 include::common-cmd-footer.txt[]
68 man:lttng-set-session(1),