Lines Matching refs:proc
4 The /proc Filesystem
8 /proc/sys Terrehon Bowden <terrehon@pacbell.net>, October 7 1999
11 move /proc/sys Shen Feng <shen@cn.fujitsu.com> April 1 2009
26 1.3 Networking info in /proc/net
28 1.5 Parallel port info in /proc/parport
29 1.6 TTY info in /proc/tty
30 1.7 Miscellaneous kernel statistics in /proc/stat
32 1.9 /proc/consoles - Shows registered system consoles
37 3.1 /proc/<pid>/oom_adj & /proc/<pid>/oom_score_adj - Adjust the oom-killer
39 3.2 /proc/<pid>/oom_score - Display current oom-killer score
40 3.3 /proc/<pid>/io - Display the IO accounting fields
41 3.4 /proc/<pid>/coredump_filter - Core dump filtering settings
42 3.5 /proc/<pid>/mountinfo - Information about mounts
43 3.6 /proc/<pid>/comm & /proc/<pid>/task/<tid>/comm
44 3.7 /proc/<pid>/task/<tid>/children - Information about task children
45 3.8 /proc/<pid>/fdinfo/<fd> - Information about opened file
46 3.9 /proc/<pid>/map_files - Information about memory mapped files
47 3.10 /proc/<pid>/timerslack_ns - Task timerslack value
48 3.11 /proc/<pid>/patch_state - Livepatch patch operation state
49 3.12 /proc/<pid>/arch_status - Task architecture specific information
50 3.13 /proc/<pid>/fd - List of symlinks to open files
51 3.14 /proc/<pid>/ksm_stat - Information about the process's ksm status.
73 https://www.kernel.org/doc/html/latest/filesystems/proc.html
87 * Investigating the properties of the pseudo file system /proc and its
89 * Examining /proc's structure
95 The proc file system acts as an interface to internal data structures in the
99 First, we'll take a look at the read-only parts of /proc. In Chapter 2, we
100 show you how you can use /proc/sys to change settings.
105 The directory /proc contains (among other things) one subdirectory for each
111 A process can read its own information from /proc/PID/* with no extra
112 permissions. When reading /proc/PID/* information for other processes, reading
119 to /proc/PID/mem for other processes.
121 Note that an open file descriptor to /proc/<pid> or to any of its
124 open /proc/<pid> file descriptors corresponding to dead processes
129 .. table:: Table 1-1: Process specific entries in /proc
160 read the file /proc/PID/status::
162 >cat /proc/self/status
211 the ps command. In fact, ps uses the proc file system to obtain its
213 file /proc/PID/status. It fields are described in table 1-2.
224 snapshot of a moment, you can see /proc/<pid>/smaps file and scan page table.
361 use /proc/PID/wchan instead)
382 The /proc/PID/maps file contains the currently mapped memory regions and
438 Starting with 6.11 kernel, /proc/PID/maps provides an alternative
447 The /proc/PID/smaps is an extension based on maps, showing the memory
479 the mapping in /proc/PID/maps. Following lines show the size of the
628 Note: reading /proc/PID/maps or /proc/PID/smaps is inherently racy (consistent
640 The /proc/PID/smaps_rollup file includes the same fields as /proc/PID/smaps,
654 The /proc/PID/clear_refs is used to reset the PG_Referenced and ACCESSED/YOUNG
660 > echo 1 > /proc/PID/clear_refs
664 > echo 2 > /proc/PID/clear_refs
668 > echo 3 > /proc/PID/clear_refs
672 > echo 4 > /proc/PID/clear_refs
677 > echo 5 > /proc/PID/clear_refs
679 Any other value written to /proc/PID/clear_refs will have no effect.
681 The /proc/pid/pagemap gives the PFN, which can be used to find the pageflags
682 using /proc/kpageflags and number of times a page is mapped using
683 /proc/kpagecount. For detailed explanation, see
686 The /proc/pid/numa_maps is an extension based on maps, showing the memory
730 /proc and are listed in Table 1-5. Not all of these will be present in your
734 .. table:: Table 1-5: Kernel info in /proc
783 pci Deprecated info of PCI bus (new way -> /proc/bus/pci/,
801 they are used for by looking in the file /proc/interrupts::
803 > cat /proc/interrupts
822 > cat /proc/interrupts
851 In 2.6.2* /proc/interrupts was expanded again. This time the goal was for
852 /proc/interrupts to display every IRQ vector in use by the system, not
883 Of some interest is the introduction of the /proc/irq directory to 2.4.
890 > ls /proc/irq/
893 > ls /proc/irq/0/
899 > echo 1 > /proc/irq/10/smp_affinity
906 > cat /proc/irq/0/smp_affinity
912 > cat /proc/irq/0/smp_affinity_list
917 /proc/irq/[0-9]* directory.
929 There are three more important subdirectories in /proc: net, scsi, and sys.
942 > cat /proc/buddyinfo
961 > cat /proc/pagetypeinfo
1028 > tail -n +3 /proc/allocinfo | sort -rn
1052 /proc/net/sockstat for TCP memory allocations.
1058 > cat /proc/meminfo
1326 > cat /proc/vmallocinfo
1359 > cat /proc/softirqs
1371 1.3 Networking info in /proc/net
1374 The subdirectory /proc/net follows the usual pattern. Table 1-8 shows the
1379 .. table:: Table 1-8: IPv6 info in /proc/net
1395 .. table:: Table 1-9: Network info in /proc/net
1432 > cat /proc/net/dev
1446 example, the bond0 device will have a directory called /proc/net/bond0/.
1455 subdirectory named after the driver for this adapter in /proc/scsi.
1456 You'll also see a list of all recognized SCSI devices in /proc/scsi::
1458 >cat /proc/scsi/scsi
1474 > cat /proc/scsi/aic7xxx/0
1514 1.5 Parallel port info in /proc/parport
1517 The directory /proc/parport contains information about the parallel ports of
1524 .. table:: Table 1-10: Files in /proc/parport
1539 1.6 TTY info in /proc/tty
1543 directory /proc/tty. You'll find entries for drivers and line disciplines in
1547 .. table:: Table 1-11: Files in /proc/tty
1558 /proc/tty/drivers::
1560 > cat /proc/tty/drivers
1574 1.7 Miscellaneous kernel statistics in /proc/stat
1578 /proc/stat file. All of the numbers reported in this file are aggregates
1581 > cat /proc/stat
1612 3. The value of iowait field in /proc/stat will decrease in certain
1615 So, the iowait is not reliable by reading from /proc/stat.
1653 /proc/fs/ext4. Each mounted filesystem will have a directory in
1654 /proc/fs/ext4 based on its device name (i.e., /proc/fs/ext4/hdc or
1655 /proc/fs/ext4/sda9 or /proc/fs/ext4/dm-0). The files in each per-device
1658 .. table:: Table 1-12: Files in /proc/fs/ext4/<devname>
1665 1.9 /proc/consoles
1670 /dev/console, you may simply look into the file /proc/consoles::
1672 > cat /proc/consoles
1699 The /proc file system serves information about the running system. It not only
1703 The directory structure of /proc reflects the types of information and makes
1712 * Modifying kernel parameters by writing into files found in /proc/sys
1714 * Review of the /proc/sys file tree
1718 A very interesting part of /proc is the directory /proc/sys. This is not only
1730 The files in /proc/sys can be used to fine tune and monitor miscellaneous and
1734 very careful when writing to any of these files. The entries in /proc may
1748 /proc/sys tree can not only be read, but also modified. You can use the echo
1756 3.1 /proc/<pid>/oom_adj & /proc/<pid>/oom_score_adj- Adjust the oom-killer score
1778 The value of /proc/<pid>/oom_score_adj is added to the badness score before it
1787 consider for each task. Setting a /proc/<pid>/oom_score_adj value of +500, for
1794 For backwards compatibility with previous kernels, /proc/<pid>/oom_adj may also
1798 scaled linearly with /proc/<pid>/oom_score_adj.
1800 The value of /proc/<pid>/oom_score_adj may be reduced no lower than the last
1805 3.2 /proc/<pid>/oom_score - Display current oom-killer score
1809 any given <pid>. Use it together with /proc/<pid>/oom_score_adj to tune which
1816 3.3 /proc/<pid>/io - Display the IO accounting fields
1829 test:/tmp # cat /proc/3828/io
1912 if process A reads process B's /proc/pid/io while process B is updating one
1919 3.4 /proc/<pid>/coredump_filter - Core dump filtering settings
1927 /proc/<pid>/coredump_filter allows you to customize which memory segments
1955 write 0x31 to the process's proc file::
1957 $ echo 0x31 > /proc/1234/coredump_filter
1963 $ echo 0x7 > /proc/self/coredump_filter
1970 3.5 /proc/<pid>/mountinfo - Information about mounts
2010 3.6 /proc/<pid>/comm & /proc/<pid>/task/<tid>/comm
2019 3.7 /proc/<pid>/task/<tid>/children - Information about task children
2026 not be listed here; one needs to read /proc/<children-pid>/task/<tid>/children
2036 3.8 /proc/<pid>/fdinfo/<fd> - Information about opened file
2044 /proc/<pid>/mountinfo for details]. 'ino' represents the inode number of
2207 3.9 /proc/<pid>/map_files - Information about memory mapped files
2223 files in a fast way instead of parsing /proc/<pid>/maps or
2224 /proc/<pid>/smaps, both of which contain many more records. At the same
2229 3.10 /proc/<pid>/timerslack_ns - Task timerslack value
2245 3.11 /proc/<pid>/patch_state - Livepatch patch operation state
2262 3.12 /proc/<pid>/arch_status - task architecture specific status
2272 $ cat /proc/6753/arch_status
2307 3.13 /proc/<pid>/fd - List of symlinks to open files
2319 of stat() output for /proc/<pid>/fd for fast access.
2322 3.14 /proc/<pid>/ksm_stat - Information about the process's ksm status
2332 / # cat /proc/self/ksm_stat
2362 /proc/<pid>/ksm_merging_pages shows.
2400 hidepid= Set /proc/<pid>/ access mode.
2407 /proc/<pid>/ directories (default).
2409 hidepid=noaccess or hidepid=1 means users may not access any /proc/<pid>/
2413 behaviour). As an additional bonus, as /proc/<pid>/cmdline is unaccessible for
2417 hidepid=invisible or hidepid=2 means hidepid=1 plus all /proc/<pid>/ will be
2421 stat()'ing /proc/<pid>/ otherwise. It greatly complicates an intruder's task of
2427 /proc/<pid>/ directories that the caller can ptrace.
2439 `/proc/$pid/ns/pid`, or a file descriptor when using `FSCONFIG_SET_FD`) that
2469 # grep ^proc /proc/mounts
2470 proc /proc proc rw,relatime,hidepid=2 0 0
2472 # strace -e mount mount -o hidepid=1 -t proc proc /tmp/proc
2473 mount("proc", "/tmp/proc", "proc", 0, "hidepid=1") = 0
2476 # grep ^proc /proc/mounts
2477 proc /proc proc rw,relatime,hidepid=2 0 0
2478 proc /tmp/proc proc rw,relatime,hidepid=2 0 0
2483 # mount -o remount,hidepid=1 -t proc proc /tmp/proc
2485 # grep ^proc /proc/mounts
2486 proc /proc proc rw,relatime,hidepid=1 0 0
2487 proc /tmp/proc proc rw,relatime,hidepid=1 0 0
2496 # mount -o hidepid=invisible -t proc proc /proc
2497 # mount -o hidepid=noaccess -t proc proc /tmp/proc
2498 # grep ^proc /proc/mounts
2499 proc /proc proc rw,relatime,hidepid=invisible 0 0
2500 proc /tmp/proc proc rw,relatime,hidepid=noaccess 0 0