]>
Commit | Line | Data |
---|---|---|
5330b97e | 1 | .\" Man page for the lsns command. |
1bb4fe24 KZ |
2 | .\" Copyright 2015 Karel Zak <kzak@redhat.com> |
3 | .\" May be distributed under the GNU General Public License | |
4 | ||
5 | .TH LSNS 8 "December 2015" "util-linux" "System Administration" | |
6 | .SH NAME | |
7 | lsns \- list namespaces | |
8 | .SH SYNOPSIS | |
9 | .B lsns | |
10 | [options] | |
5330b97e | 11 | .RI [ namespace ] |
1bb4fe24 KZ |
12 | |
13 | .SH DESCRIPTION | |
14 | .B lsns | |
15 | lists information about all the currently accessible namespaces or about the | |
16 | given \fInamespace\fP. The \fInamespace\fP identifier is an inode number. | |
17 | ||
0e4f6b2a KZ |
18 | The default output is subject to change. So whenever possible, you should |
19 | avoid using default outputs in your scripts. Always explicitly define expected | |
5330b97e BS |
20 | columns by using the \fB\-\-output\fR option together with a columns list in |
21 | environments where a stable output is required. | |
0e4f6b2a | 22 | |
5330b97e BS |
23 | Note that \fBlsns\fR reads information directly from the /proc filesystem and |
24 | for non-root users it may return incomplete information. The current /proc | |
25 | filesystem may be unshared and affected by a PID namespace | |
26 | (see \fBunshare \-\-mount\-proc\fP for more details). | |
63549365 | 27 | .B lsns |
5330b97e BS |
28 | is not able to see persistent namespaces without processes where the namespace |
29 | instance is held by a bind mount to /proc/\fIpid\fR/ns/\fItype\fR. | |
1bb4fe24 KZ |
30 | |
31 | .SH OPTIONS | |
32 | .TP | |
33 | .BR \-J , " \-\-json" | |
34 | Use JSON output format. | |
35 | .TP | |
36 | .BR \-l , " \-\-list" | |
37 | Use list output format. | |
38 | .TP | |
39 | .BR \-n , " \-\-noheadings" | |
40 | Do not print a header line. | |
41 | .TP | |
42 | .BR \-o , " \-\-output " \fIlist\fP | |
5330b97e | 43 | Specify which output columns to print. Use \fB\-\-help\fR |
1bb4fe24 KZ |
44 | to get a list of all supported columns. |
45 | ||
46 | The default list of columns may be extended if \fIlist\fP is | |
5330b97e | 47 | specified in the format \fB+\fIlist\fP (e.g. \fBlsns \-o +PATH\fP). |
1bb4fe24 KZ |
48 | .TP |
49 | .BR \-p , " \-\-task " \fIpid\fP | |
d35df4db | 50 | Display only the namespaces held by the process with this \fIpid\fR. |
1bb4fe24 KZ |
51 | .TP |
52 | .BR \-r , " \-\-raw" | |
53 | Use the raw output format. | |
54 | .TP | |
55 | .BR \-t , " \-\-type " \fItype\fP | |
5330b97e | 56 | Display the specified \fItype\fP of namespaces only. The supported types are |
2b8889c4 MB |
57 | \fBmnt\fP, \fBnet\fP, \fBipc\fP, \fBuser\fP, \fBpid\fP, \fButs\fP and |
58 | \fBcgroup\fP. This option may be given more than once. | |
1bb4fe24 KZ |
59 | .TP |
60 | .BR \-u , " \-\-notruncate" | |
61 | Do not truncate text in columns. | |
62 | .TP | |
63 | .BR \-V , " \-\-version" | |
64 | Display version information and exit. | |
65 | .TP | |
66 | .BR \-h , " \-\-help" | |
67 | Display help text and exit. | |
68 | ||
69 | .SH AUTHORS | |
70 | .nf | |
71 | Karel Zak <kzak@redhat.com> | |
72 | .fi | |
73 | ||
74 | .SH "SEE ALSO" | |
1bb4fe24 | 75 | .BR nsenter (1), |
f053ff1e | 76 | .BR unshare (1), |
d628c0d7 MK |
77 | .BR clone (2), |
78 | .BR namespaces (7) | |
1bb4fe24 KZ |
79 | |
80 | .SH AVAILABILITY | |
81 | The lsns command is part of the util-linux package and is available from | |
82 | ftp://ftp.kernel.org/pub/linux/utils/util-linux/. |