Rename "tracing session" -> "recording session"
[lttng-tools.git] / doc / man / lttng-rotate.1.txt
CommitLineData
980bb5fd
PP
1lttng-rotate(1)
2===============
aaae4813 3:revdate: 14 June 2021
980bb5fd
PP
4
5
6NAME
7----
aaae4813 8lttng-rotate - Archive the current trace chunk of an LTTng recording session
980bb5fd
PP
9
10
11SYNOPSIS
12--------
13[verse]
14*lttng* ['linkgenoptions:(GENERAL OPTIONS)'] *rotate* [option:--no-wait] ['SESSION']
15
16
17DESCRIPTION
18-----------
188419c4
PP
19The `lttng rotate` command archives to the file system
20the current trace chunk of:
adc4b5c8 21
188419c4 22With the 'SESSION' argument::
aaae4813 23 The recording session named 'SESSION'.
980bb5fd 24
188419c4 25Without the 'SESSION' argument::
aaae4813
PP
26 The current recording session (see man:lttng-concepts(7) to learn
27 more about the current recording session).
980bb5fd 28
aaae4813 29This action is called a _recording session rotation_.
980bb5fd 30
aaae4813 31See man:lttng-concepts(7) to learn more about the recording session
188419c4 32rotation and trace chunk concepts.
adc4b5c8 33
188419c4 34You can use the `rotate` command:
980bb5fd 35
aaae4813 36* Any time the recording session is active.
980bb5fd 37
aaae4813 38* A single time once the recording session becomes inactive.
980bb5fd 39
188419c4 40See man:lttng-concepts(7) to learn more about the activity of a
aaae4813 41recording session.
980bb5fd 42
188419c4 43By default, the `rotate` command ensures that LTTng finished performing
aaae4813
PP
44the recording session rotation before it prints the path of the archived
45trace chunk and exits. The printed path is absolute when the recording
188419c4
PP
46session was created in normal mode and relative to the base output
47directory of the relay daemon (see the nloption:--output option of
48man:lttng-relayd(8)) when it was created in network streaming mode (see
49man:lttng-create(1)).
980bb5fd 50
188419c4
PP
51Make the command exit immediately with the option:--no-wait option. In
52this case, there's no easy way to know when the current trace chunk
53becomes archived, and the command does :not: print the path of the
54archived trace chunk.
980bb5fd 55
aaae4813
PP
56Because LTTng flushes the current sub-buffers of the selected recording
57session when it performs a recording session rotation, archived trace
188419c4
PP
58chunks are never redundant, that is, they do not overlap over time like
59snapshots can (see man:lttng-snapshot(1)). Also, a rotation does :not:
60directly cause discarded event records or packets.
980bb5fd 61
aaae4813
PP
62A `rotate-session` trigger action can also rotate a recording session
63(see man:lttng-add-trigger(1)).
980bb5fd 64
7d259724 65See the ``<<examples,EXAMPLES>>'' section below for usage examples.
08372101 66
188419c4
PP
67[IMPORTANT]
68====
69You may only use the `rotate` command when:
980bb5fd 70
aaae4813
PP
71* The selected recording session was created in normal mode or in
72 network streaming mode (see man:lttng-create(1)).
980bb5fd 73
188419c4
PP
74* No channel was created with a configured trace file count or size
75 limit (see the nloption:--tracefile-size and
76 nloption:--tracefile-count options of the man:lttng-enable-channel(1)
77 command).
980bb5fd 78
188419c4
PP
79* LTTng is not currently performing an immediate rotation (this
80 command).
81====
980bb5fd 82
980bb5fd 83
55e06994 84include::common-lttng-cmd-options-head.txt[]
980bb5fd 85
980bb5fd 86
188419c4 87option:-n, option:--no-wait::
aaae4813 88 Do not ensure that the recording session rotation operation is
188419c4 89 completed before exiting.
980bb5fd 90
980bb5fd 91
55e06994 92include::common-lttng-cmd-help-options.txt[]
980bb5fd 93
980bb5fd 94
55e06994
PP
95include::common-lttng-cmd-after-options.txt[]
96
97
08372101
PP
98[[examples]]
99EXAMPLES
100--------
aaae4813 101.Rotate the current recording session.
08372101
PP
102====
103[role="term"]
104----
105$ lttng rotate
106----
107====
108
aaae4813 109.Rotate a specific recording session.
08372101
PP
110====
111[role="term"]
112----
113$ lttng rotate my-session
114----
115====
116
aaae4813 117.Rotate the current recording session without waiting for completion.
08372101
PP
118====
119See the option:--no-wait option.
120
121[role="term"]
122----
123$ lttng rotate --no-wait
124----
125====
126
127
55e06994 128include::common-footer.txt[]
980bb5fd
PP
129
130
131SEE ALSO
132--------
188419c4 133man:lttng(1),
980bb5fd 134man:lttng-disable-rotation(1),
21b35b3a
PP
135man:lttng-enable-rotation(1),
136man:lttng-concepts(7)
This page took 0.0468 seconds and 5 git commands to generate.