]> git.ipfire.org Git - thirdparty/util-linux.git/blob - misc-utils/lslocks.8
docs: remove obsolete and unneeded comments from man-page files
[thirdparty/util-linux.git] / misc-utils / lslocks.8
1 .\" Man page for the lslocks command.
2 .\" Copyright 2012 Davidlohr Bueso <dave@gnu.org>
3 .\" May be distributed under the GNU General Public License
4
5 .TH LSLOCKS 8 "December 2014" "util-linux" "System Administration"
6 .SH NAME
7 lslocks \- list local system locks
8 .SH SYNOPSIS
9 .B lslocks
10 [options]
11
12 .SH DESCRIPTION
13 .B lslocks
14 lists information about all the currently held file locks in a Linux system.
15
16 .SH OPTIONS
17 .TP
18 .BR \-n , " \-\-noheadings"
19 Do not print a header line.
20 .TP
21 .BR \-o , " \-\-output " \fIlist\fP
22 Specify which output columns to print. Use
23 .B "--help"
24 to get a list of all supported columns.
25
26 The default list of columns may be extended if \fIlist\fP is
27 specified in the format \fI+list\fP (e.g. \fBlslocks -o +BLOCKER\fP).
28 .TP
29 .BR \-p , " \-\-pid " \fIpid\fP
30 Display only the locks held by the process with this \fIpid\fR.
31 .TP
32 .BR \-r , " \-\-raw"
33 Use the raw output format.
34 .TP
35 .BR \-u , " \-\-notruncate"
36 Do not truncate text in columns.
37 .TP
38 .BR \-V , " \-\-version"
39 Display version information and exit.
40 .TP
41 .BR \-h , " \-\-help"
42 Display help text and exit.
43
44 .SH OUTPUT
45 .IP "COMMAND"
46 The command name of the process holding the lock.
47 .IP "PID"
48 The process ID of the process which holds the lock.
49 .IP "TYPE"
50 The type of lock; can be FLOCK (created with \fBflock\fR(2)) or POSIX
51 (created with \fBfcntl\fR(2) and \fBlockf\fR(3)).
52 .IP "SIZE"
53 Size of the locked file.
54 .IP "MODE"
55 The lock's access permissions (read, write). If the process is blocked and waiting for the lock,
56 then the mode is postfixed with an '*' (asterisk).
57 .IP "M"
58 Whether the lock is mandatory; 0 means no (meaning the lock is only advisory), 1 means yes.
59 (See \fBfcntl\fR(2).)
60 .IP "START"
61 Relative byte offset of the lock.
62 .IP "END"
63 Ending offset of the lock.
64 .IP "PATH"
65 Full path of the lock. If none is found, or there are no permissions to read the path,
66 it will fall back to the device's mountpoint. The path might be truncated; use
67 \fB\-\-notruncate\fR to get the full path.
68 .IP "BLOCKER"
69 The PID of the process which blocks the lock.
70
71 .SH NOTES
72 .nf
73 The \fBlslocks\fR command is meant to replace the \fBlslk\fR(8) command,
74 originally written by Victor A. Abell <abe@purdue.edu> and unmaintained
75 since 2001.
76 .fi
77
78 .SH AUTHORS
79 .nf
80 Davidlohr Bueso <dave@gnu.org>
81 .fi
82
83 .SH "SEE ALSO"
84 .BR flock (1),
85 .BR fcntl (2),
86 .BR lockf (2)
87
88 .SH AVAILABILITY
89 The lslocks command is part of the util-linux package and is available from
90 ftp://ftp.kernel.org/pub/linux/utils/util-linux/.