Whamcloud - gitweb
LU-930 doc: fix format man page sections for lctl
[fs/lustre-release.git] / lustre / doc / lctl-barrier.8
1 .TH LCTL-BARRIER 8 "2017-07-18" Lustre "configuration utilities"
2 .SH NAME
3 lctl-barrier \- Lustre write barrier utilities
4 .SH SYNOPSIS
5 .br
6 .B lctl barrier_freeze \fR{fsname} [timeout]
7 .br
8 .br
9 .B lctl barrier_thaw \fR{fsname}
10 .br
11 .br
12 .B lctl barrier_stat \fR[--state|-s] [--timeout|-t] {fsname}
13 .br
14 .br
15 .B lctl barrier_rescan \fR{fsname} [timeout]
16 .br
17 .SH DESCRIPTION
18 .TP
19 .B barrier_freeze \fR{fsname} [timeout]
20 Set write barrier on all MDTs. The command will not return until the
21 barrier is set (frozen) or failed. With the write barrier set, any
22 subsequent metadata modification will be blocked until the barrier is
23 thawed or expired. The barrier lifetime is started when triggering
24 freeze and will be terminated when barrier thawed. To avoid the system
25 being frozen for very long time if miss/fail to call barrier_thaw, you
26 can specify its lifetime via the
27 .I timeout
28 parameter in seconds, the default value is 30 (seconds). If the barrier
29 is not thawed before that, it will be expired automatically. The command
30 can only succeed when all registered MDTs are available. If some MDT is
31 registered but goes offline, then the freeze command will fail. To check
32 and update current status of MDTs, see the command
33 .B barrier_rescan
34 in subsequent section.
35 .TP
36 .B barrier_thaw \fR{fsname}
37 Reset write barrier on all MDTs. After the write barrier thawed, all the
38 blocked metadata modifications (because of the former
39 .B barrier_freeze
40 command) will be handled normally.
41 .TP
42 .B barrier_stat \fR[--state|-s] [--timeout|-t] {fsname}
43 .br
44 Query the write barrier status, the possible status and related meanings are
45 as following:
46 .br
47   'init': has never set barrier on the system
48   'freezing_p1': in the first stage of setting the write barrier
49   'freezing_p2': in the second stage of setting the write barrier
50   'frozen': the write barrier has been set successfully
51   'thawing': in thawing the write barrier
52   'thawed': the write barrier has been thawed
53   'failed': fail to set write barrier
54   'expired': the write barrier is expired
55   'rescan': in scanning the MDTs status, see the command barrier_rescan
56   'unknown': other cases
57 .br
58 If the barrier is in 'freezing_p1', 'freezing_p2' or 'frozen' status, then
59 the lifetime remaining will be returned also. If no option is specified,
60 or both "-s" and "-t" options are specified, then the output format is:
61
62   state: xxx
63   timeout: nnn seconds
64
65 Otherwise, only the value ('xxx' or 'nnn') corresponding to the given option
66 will be printed.
67 .TP
68 .B barrier_rescan \fR{fsname} [timeout]
69 .br
70 Scan the system to check which MDTs are active. The status of the MDTs is
71 required because the
72 .B barrier_freeze
73 will be unsuccessful if any of the MDTs are permenantly offline. During
74 the rescan, the MDT status is updated. If an MDT does not respond the
75 .B barrier_rescan
76 within the given
77 .I timeout
78 seconds (where the default value is 30 seconds), then it will be marked
79 as unavailable or inactive.
80
81 .SH AVAILABILITY
82 .B lctl-barrier
83 is part of the
84 .BR lustre (7)
85 filesystem package.
86 .SH SEE ALSO
87 .BR lctl (8),
88 .BR lctl-snapshot-create (8)