| 1 |
.\" Copyright 2017, Michael Kerrisk <[email protected]> |
| 2 |
.\" Copyright, the authors of the Linux man-pages project |
| 3 |
.\" |
| 4 |
.\" SPDX-License-Identifier: Linux-man-pages-copyleft |
| 5 |
.\" |
| 6 |
.TH ioctl_nsfs 2 2026-02-08 "Linux man-pages 6.18" |
| 7 |
.SH NAME |
| 8 |
ioctl_nsfs |
| 9 |
\- |
| 10 |
ioctl() operations for Linux namespaces |
| 11 |
.SH SYNOPSIS |
| 12 |
.nf |
| 13 |
.BR "#include <linux/nsfs.h>" " /* Definition of " NS_* " constants */" |
| 14 |
.B #include <sys/ioctl.h> |
| 15 |
.P |
| 16 |
.BI "int ioctl(int " fd ", unsigned long " op ", ...);" |
| 17 |
.fi |
| 18 |
.SH DESCRIPTION |
| 19 |
.SS Discovering namespace relationships |
| 20 |
.TP |
| 21 |
.BR NS_GET_USERNS (2const) |
| 22 |
.TQ |
| 23 |
.BR NS_GET_PARENT (2const) |
| 24 |
.SS Discovering the namespace type |
| 25 |
.TP |
| 26 |
.BR NS_GET_NSTYPE (2const) |
| 27 |
.SS Discovering the owner of a user namespace |
| 28 |
.TP |
| 29 |
.BR NS_GET_OWNER_UID (2const) |
| 30 |
.SH ERRORS |
| 31 |
.TP |
| 32 |
.B ENOTTY |
| 33 |
.I fd |
| 34 |
does not refer to a |
| 35 |
.IR /proc/ pid /ns/ * |
| 36 |
file. |
| 37 |
.SH STANDARDS |
| 38 |
Linux. |
| 39 |
.SH SEE ALSO |
| 40 |
.BR ioctl (2), |
| 41 |
.BR fstat (2), |
| 42 |
.BR proc (5), |
| 43 |
.BR namespaces (7) |