diff options
| author | Michael Kerrisk <mtk.manpages@gmail.com> | 2013-02-28 12:02:28 +0100 |
|---|---|---|
| committer | Michael Kerrisk <mtk.manpages@gmail.com> | 2014-09-13 20:16:00 -0700 |
| commit | 6c3db754793fc446e8de69e438e384eff739859a (patch) | |
| tree | fa9abc7c8f9b5d72d3c321b1b9fd299f9d774f3a /man7/pid_namespaces.7 | |
| parent | 6e377abf9c61b4fd1605fa9528b68c380de5d5bf (diff) | |
| download | man-pages-6c3db754793fc446e8de69e438e384eff739859a.tar.gz | |
pid_namespaces.7: readlink(2) on /proc/self gives the caller's PID in the pidns of /proc
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Diffstat (limited to 'man7/pid_namespaces.7')
| -rw-r--r-- | man7/pid_namespaces.7 | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/man7/pid_namespaces.7 b/man7/pid_namespaces.7 index 5e49633cc2..b1a40f1f96 100644 --- a/man7/pid_namespaces.7 +++ b/man7/pid_namespaces.7 @@ -234,6 +234,13 @@ then it isn't necessary to change the root directory: a new procfs instance can be mounted directly over .IR /proc .) +Calling +.BR readlink (2) +on the path +.I /proc/self +yields the process ID of the caller in the PID namespace of the procfs mount +(i.e., the PID namespace of the process that mounted the procfs). + When a process ID is passed over a UNIX domain socket to a process in a different PID namespace (see the description of .B SCM_CREDENTIALS |
