/proc filesystem
A virtual folder the Linux kernel fills with live information about processes and the system.
In more detail
Nothing in /proc is on disk: reading /proc/self/ns lists the namespaces of the reading process, and /proc/1/status describes PID 1. Tools such as ps read their data from here.
Examples
readlink /proc/self/ns/pidNothing in /proc is stored on disk: each numbered directory describes the process with that PID, and files such as /proc/cmdline and /proc/meminfo describe the running kernel. Contents can change between two reads because they reflect live state. Tools such as ps read their data from here.cat /proc/cmdline prints the kernel command line the machine booted with.Related terms
- namespace (Linux) — A Linux kernel feature that controls what a process can see, such as which other processes, network or host name.
- process ID — The number the kernel gives each running process so it can be told apart from all the others.
- control group — A Linux kernel feature that limits how much memory, processor time and other resources a group of processes may use.
- sysfs — A virtual filesystem mounted at /sys where the kernel exposes devices, drivers and their settings as files.
- /dev — The directory holding device nodes: special files through which programs reach disks, terminals and other devices.
- everything is a file — The Unix design idea that many kinds of objects, such as devices, processes and kernel settings, are reached through the same open, read and write operations as files.
Taught in
- Container Hardening: Distroless & Rootless — Cloud Security & DevSecOps Engineering
- Runtime Anomaly Detection with Falco & eBPF — Cloud Security & DevSecOps Engineering
- Namespaces And Cgroups: Isolation And Limits — Docker Architecture & Production Containers
- Environment, Secret Files And Runtime Restrictions — Docker Architecture & Production Containers
- Harden And Deliver The Complete Service Stack — Docker Architecture & Production Containers
- The Filesystem Hierarchy — Linux Fundamentals & Systems Administration
- Everything Is A File: proc, sys And dev — Linux Fundamentals & Systems Administration
- Swap And New Volumes Without Losing Data — Red Hat Certified System Administrator (EX200) Exam Prep
- Host Names And Name Resolution — Red Hat Certified System Administrator (EX200) Exam Prep
- SELinux Modes, And Why setenforce Is Not Enough — Red Hat Certified System Administrator (EX200) Exam Prep
- Mock Exam, Part 2: Real Machines And The Ten Costly Mistakes — Red Hat Certified System Administrator (EX200) Exam Prep
- The App In /bin That Vanished: The FHS, Distributions And Licences — CompTIA Linux+ (XK0-006) Exam Prep
- Which RAID, Which File System? Disks That Fail And Inodes That Run Out — CompTIA Linux+ (XK0-006) Exam Prep
- The Upload That Ran: Mount Options, Swap And Network Shares — CompTIA Linux+ (XK0-006) Exam Prep
- Two Hours, Twenty Hosts, One Reboot — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- Kernel Parameters: Now, At Boot, And Which File Wins — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- Recovering From Boot, File System And Disk Failures — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- SELinux: Modes, Labels, Ports And Booleans That Last — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- Addresses, Gateways And Names On Both Stacks — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- Bridges And Bonds: Two Links, One Interface — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- LVM End To End: Pools, Volumes And Online Growth — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- The Virtual File System: /proc, /sys, Binds And tmpfs — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- Storage Performance: Busy, Slow, Or Both — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- Performance Triage: Processor, Memory Or Disk? — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- Constraints: Limits, Control Groups And Listeners — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- Disk Full At Three In The Morning — Linux Foundation Certified System Administrator (LFCS) Exam Prep
- Exam 101 Strategy: Weights, Blanks And Ninety Minutes — LPIC-1 Linux Administrator (101-500 and 102-500) Exam Prep