Commit | Line | Data |
---|---|---|
fb58d659 PP |
1 | lttng-stop(1) |
2 | ============= | |
e9711845 | 3 | :revdate: 14 June 2021 |
fb58d659 PP |
4 | |
5 | ||
6 | NAME | |
7 | ---- | |
e9711845 | 8 | lttng-stop - Stop an LTTng recording session |
fb58d659 PP |
9 | |
10 | ||
11 | SYNOPSIS | |
12 | -------- | |
13 | [verse] | |
ce19b9ed | 14 | *lttng* ['linkgenoptions:(GENERAL OPTIONS)'] *stop* [option:--no-wait] ['SESSION'] |
fb58d659 PP |
15 | |
16 | ||
17 | DESCRIPTION | |
18 | ----------- | |
e9711845 | 19 | The `lttng stop` command stops a recording session, that is, it |
484b2a0c PP |
20 | deactivates the LTTng tracers for: |
21 | ||
22 | With the 'SESSION' argument:: | |
e9711845 | 23 | The recording session named 'SESSION'. |
484b2a0c PP |
24 | |
25 | Without the 'SESSION' argument:: | |
e9711845 PP |
26 | The current recording session (see man:lttng-concepts(7) to learn more |
27 | about the current recording session). | |
26f0c779 | 28 | |
e9711845 | 29 | See man:lttng-concepts(7) to learn more about recording sessions. |
484b2a0c | 30 | |
e9711845 PP |
31 | The selected recording session must be active (started; see |
32 | man:lttng-start(1)). A recording session is inactive on creation (see | |
484b2a0c PP |
33 | man:lttng-create(1)). |
34 | ||
e9711845 | 35 | A `stop-session` trigger action can also stop a recording session (see |
484b2a0c PP |
36 | man:lttng-add-trigger(1)). |
37 | ||
e9711845 | 38 | Start an inactive recording session with the man:lttng-start(1) command. |
484b2a0c PP |
39 | |
40 | By default, the `stop` command ensures that the trace data of the | |
e9711845 PP |
41 | selected recording session is valid before it exits. Make the command |
42 | exit immediately with the option:--no-wait option. In this case, | |
43 | however, the traces(s) might not be valid when the command exits, and | |
44 | there's no way to know when it/they becomes valid. | |
484b2a0c PP |
45 | |
46 | If LTTng archived the current trace chunk (see man:lttng-rotate(1) and | |
e9711845 | 47 | man:lttng-enable-rotation(1)) of the selected recording session at least |
484b2a0c PP |
48 | once during its lifetime, the `stop` command renames the current trace |
49 | chunk subdirectory and prints the renamed path. Although it's safe to | |
e9711845 PP |
50 | read the content of this renamed subdirectory while the recording |
51 | session remains inactive, it's :not: a trace chunk archive: you need to | |
52 | destroy the recording session with man:lttng-destroy(1) or perform a | |
53 | rotation with man:lttng-rotate(1) to archive it. | |
980bb5fd | 54 | |
da39b67c | 55 | See the ``<<examples,EXAMPLES>>'' section below for usage examples. |
4182cfea | 56 | |
fb58d659 | 57 | |
f5511eea | 58 | include::common-lttng-cmd-options-head.txt[] |
fb58d659 PP |
59 | |
60 | ||
61 | option:-n, option:--no-wait:: | |
e9711845 PP |
62 | Do :not: ensure that the trace data of the selected recording |
63 | session is valid before exiting. | |
fb58d659 PP |
64 | |
65 | ||
f5511eea | 66 | include::common-lttng-cmd-help-options.txt[] |
fb58d659 PP |
67 | |
68 | ||
f5511eea PP |
69 | include::common-lttng-cmd-after-options.txt[] |
70 | ||
71 | ||
4182cfea PP |
72 | [[examples]] |
73 | EXAMPLES | |
74 | -------- | |
e9711845 | 75 | .Stop the current recording session. |
4182cfea PP |
76 | ==== |
77 | [role="term"] | |
78 | ---- | |
79 | $ lttng stop | |
80 | ---- | |
81 | ==== | |
82 | ||
e9711845 | 83 | .Stop a specific recording session. |
4182cfea PP |
84 | ==== |
85 | [role="term"] | |
86 | ---- | |
87 | $ lttng stop my-session | |
88 | ---- | |
89 | ==== | |
90 | ||
e9711845 | 91 | .Stop the current recording session without waiting for completion. |
4182cfea PP |
92 | ==== |
93 | See the option:--no-wait option. | |
94 | ||
95 | [role="term"] | |
96 | ---- | |
97 | $ lttng stop --no-wait | |
98 | ---- | |
99 | ==== | |
100 | ||
101 | ||
f5511eea | 102 | include::common-footer.txt[] |
fb58d659 PP |
103 | |
104 | ||
105 | SEE ALSO | |
106 | -------- | |
484b2a0c PP |
107 | man:lttng(1), |
108 | man:lttng-add-trigger(1), | |
109 | man:lttng-create(1), | |
110 | man:lttng-enable-event(1), | |
111 | man:lttng-rotate(1), | |
af1c4164 PP |
112 | man:lttng-start(1), |
113 | man:lttng-concepts(7) |