From: Hans Weber <hwe.kernel@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Hans Weber <hwe.kernel@gmail.com>
Subject: [PATCH 3/3] patch : first example not showing umask field from Table 1-2
Date: Sun, 20 Feb 2022 17:30:47 +0100 [thread overview]
Message-ID: <20220220163047.117864-1-hwe.kernel@gmail.com> (raw)
Signe-off-by: Hans Weber <hwe.kernel@gmail.com>
---
Documentation/filesystems/proc.rst | 105 ++++++++++++++++-------------
1 file changed, 58 insertions(+), 47 deletions(-)
diff --git a/Documentation/filesystems/proc.rst b/Documentation/filesystems/proc.rst
index b9d1c6764266..40ca0f9087db 100644
--- a/Documentation/filesystems/proc.rst
+++ b/Documentation/filesystems/proc.rst
@@ -138,7 +138,7 @@ usually fail with ESRCH.
/proc (as of 5.10.0)
======================================================================================
- Name T Content
+ Name T Content
======================================================================================
arch_status f Task architecture specific information
attr d API for security modules
@@ -213,52 +213,63 @@ usually fail with ESRCH.
For example, to get the status information of a process, all you have to do is
read the file /proc/PID/status::
- >cat /proc/self/status
- Name: cat
- State: R (running)
- Tgid: 5452
- Pid: 5452
- PPid: 743
- TracerPid: 0 (2.4)
- Uid: 501 501 501 501
- Gid: 100 100 100 100
- FDSize: 256
- Groups: 100 14 16
- VmPeak: 5004 kB
- VmSize: 5004 kB
- VmLck: 0 kB
- VmHWM: 476 kB
- VmRSS: 476 kB
- RssAnon: 352 kB
- RssFile: 120 kB
- RssShmem: 4 kB
- VmData: 156 kB
- VmStk: 88 kB
- VmExe: 68 kB
- VmLib: 1412 kB
- VmPTE: 20 kb
- VmSwap: 0 kB
- HugetlbPages: 0 kB
- CoreDumping: 0
- THP_enabled: 1
- Threads: 1
- SigQ: 0/28578
- SigPnd: 0000000000000000
- ShdPnd: 0000000000000000
- SigBlk: 0000000000000000
- SigIgn: 0000000000000000
- SigCgt: 0000000000000000
- CapInh: 00000000fffffeff
- CapPrm: 0000000000000000
- CapEff: 0000000000000000
- CapBnd: ffffffffffffffff
- CapAmb: 0000000000000000
- NoNewPrivs: 0
- Seccomp: 0
- Speculation_Store_Bypass: thread vulnerable
- SpeculationIndirectBranch: conditional enabled
- voluntary_ctxt_switches: 0
- nonvoluntary_ctxt_switches: 1
+>cat /proc/self/status
+Name: cat
+Umask: 0022
+State: R (running)
+Tgid: 19633
+Ngid: 0
+Pid: 19633
+PPid: 13898
+TracerPid: 0
+Uid: 1000 1000 1000 1000
+Gid: 1000 1000 1000 1000
+FDSize: 256
+Groups: 24 25 27 29 30 44 46 108 113 114 119 1000
+NStgid: 19633
+NSpid: 19633
+NSpgid: 19633
+NSsid: 13898
+VmPeak: 5440 kB
+VmSize: 5440 kB
+VmLck: 0 kB
+VmPin: 0 kB
+VmHWM: 520 kB
+VmRSS: 520 kB
+RssAnon: 68 kB
+RssFile: 452 kB
+RssShmem: 0 kB
+VmData: 316 kB
+VmStk: 132 kB
+VmExe: 20 kB
+VmLib: 1460 kB
+VmPTE: 44 kB
+VmSwap: 0 kB
+HugetlbPages: 0 kB
+CoreDumping: 0
+THP_enabled: 1
+Threads: 1
+SigQ: 0/47433
+SigPnd: 0000000000000000
+ShdPnd: 0000000000000000
+SigBlk: 0000000000000000
+SigIgn: 0000000000000000
+SigCgt: 0000000000000000
+CapInh: 0000000000000000
+CapPrm: 0000000000000000
+CapEff: 0000000000000000
+CapBnd: 000001ffffffffff
+CapAmb: 0000000000000000
+NoNewPrivs: 0
+Seccomp: 0
+Seccomp_filters: 0
+Speculation_Store_Bypass: vulnerable
+Cpus_allowed: ff
+Cpus_allowed_list: 0-7
+Mems_allowed: 00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000000,00000001
+Mems_allowed_list: 0
+voluntary_ctxt_switches: 0
+nonvoluntary_ctxt_switches: 0
This shows you nearly the same information you would get if you viewed it with
the ps command. In fact, ps uses the proc file system to obtain its
--
2.30.2
next reply other threads:[~2022-02-20 16:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-20 16:30 Hans Weber [this message]
2022-02-20 17:39 ` [PATCH 3/3] patch : first example not showing umask field from Table 1-2 Randy Dunlap
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220220163047.117864-1-hwe.kernel@gmail.com \
--to=hwe.kernel@gmail.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.