proc_sys_kernel(5)
โจ NAME โจ
/proc/sys/kernel/ โ bestie, this is where the kernel keeps the knobs that control a whole bunch of its parameters ๐
๐ DESCRIPTION ๐
๐ซถ /proc/sys/kernel/
Okay so this directory? It's literally the control room. It holds files that tune a whole range of kernel parameters, and I'm gonna walk you through every single one, no skips, no cap.
๐ /proc/sys/kernel/acct
This one's holding three numbers: highwater, lowwater, and frequency. When BSD-style process accounting is turned on, these three run the show.
Here's the tea โจ if the free space on the filesystem where the log lives drops below lowwater percent, accounting suspends ๐ด. If free space climbs back above highwater percent, accounting resumes ๐.
And frequency? That's how often the kernel checks how much free space there is โ value's in seconds.
The default values are 4, 2, and 30. So, translating that: suspend accounting if 2% or less space is free; resume it if 4% or more space is free; and treat the info about the amount of free space as valid for 30 seconds. Periodt.
๐ฆ /proc/sys/kernel/auto_msgmni (Linux 2.6.27 to Linux 3.18)
From Linux 2.6.27 to Linux 3.18, this file was the one controlling recomputing of the value in /proc/sys/kernel/msgmni whenever memory got added or removed, or when an IPC namespace got created or removed.
Echoing "1" into this file enabled msgmni automatic recomputing โ and it also triggered an immediate recomputation of msgmni based on the current amount of available memory and the number of IPC namespaces. Echoing "0" disabled automatic recomputing. (Oh, and heads up: automatic recomputing was also disabled if a value was explicitly assigned to /proc/sys/kernel/msgmni.) The default value in auto_msgmni was 1.
Since Linux 3.19, though? The content of this file has no effect (because msgmni defaults to near the maximum value possible), and reads from this file always return the value "0". It's giving retired icon ๐
๐ธ /proc/sys/kernel/cap_last_cap (since Linux 3.2)
Go read capabilities(7), bestie ๐
๐ /proc/sys/kernel/cap-bound (from Linux 2.2 to Linux 2.6.24)
This file holds the value of the kernel capability bounding set (expressed as a signed decimal number). This set gets ANDed against the capabilities permitted to a process during execve(2).
Starting with Linux 2.6.25, the system-wide capability bounding set disappeared, and got replaced by a per-thread bounding set โ see capabilities(7) for the glow-up ๐
โญ /proc/sys/kernel/core_pattern
Go read core(5) ๐ซถ
โญ /proc/sys/kernel/core_pipe_limit
Go read core(5) ๐ซถ
โญ /proc/sys/kernel/core_uses_pid
Go read core(5) ๐ซถ
๐ฅ /proc/sys/kernel/ctrl-alt-del
This file controls how Ctrl+Alt+Del from the keyboard gets handled.
- When the value in this file is
0, the key combo is trapped and sent to theinit(1)program so it can handle a graceful restart ๐ - When the value is greater than zero, Linux's reaction to a Vulcan Nerve Pinch (tm) will be an immediate reboot, without even syncing its dirty buffers ๐ญ
Note: when a program (like dosemu) has the keyboard in "raw" mode, the Ctrl+Alt+Del is intercepted by the program before it ever reaches the kernel tty layer โ and it's up to the program to decide what to do with it. So like, not even the kernel's business at that point ๐
๐ /proc/sys/kernel/dmesg_restrict (since Linux 2.6.37)
The value in this file decides who gets to see kernel syslog contents.
0โ no restrictions at all, come one come all โจ1โ only privileged users can read the kernel syslog ๐
(See syslog(2) for more details.) And since Linux 3.4, only users with the CAP_SYS_ADMIN capability may change the value in this file ๐
๐ง /proc/sys/kernel/domainname and /proc/sys/kernel/hostname
These two can set the NIS/YP domainname and the hostname of your box in exactly the same way as the commands domainname(1) and hostname(1). Like, watch this:
# echo 'darkstar' > /proc/sys/kernel/hostname
# echo 'mydomain' > /proc/sys/kernel/domainname
has the same effect as
# hostname 'darkstar'
# domainname 'mydomain'
But โ and this is the part people always fumble โ the classic darkstar.frop.org has the hostname "darkstar" and DNS (Internet Domain Name Server) domainname "frop.org". Do not confuse that with the NIS (Network Information Service) or YP (Yellow Pages) domainname. These two domain names are, in general, different. For a detailed discussion, see the hostname(1) man page. It's giving "two things, same name, different vibes" ๐ญ
๐ /proc/sys/kernel/hotplug
This file contains the pathname for the hotplug policy agent. The default value in this file is /sbin/hotplug ๐
๐ /proc/sys/kernel/htab-reclaim (before Linux 2.4.9.2)
(PowerPC only ๐) If this file is set to a nonzero value, the PowerPC htab (see kernel file Documentation/powerpc/ppc_htab.txt) gets pruned every single time the system hits the idle loop.
๐ /proc/sys/kernel/keys/
This directory holds a bunch of files that define parameters and limits for the key-management facility. Those files are described over in keyrings(7) ๐โจ
๐ /proc/sys/kernel/kptr_restrict (since Linux 2.6.38)
The value in this file decides whether kernel addresses get exposed via /proc files and other interfaces.
0โ no restrictions, no hiding ๐1โ kernel pointers printed using the%pKformat specifier will be replaced with zeros unless the user has theCAP_SYSLOGcapability2โ kernel pointers printed using the%pKformat specifier will be replaced with zeros regardless of the user's capabilities ๐
The initial default value for this file was 1, but the default got changed to 0 in Linux 2.6.39. And since Linux 3.4, only users with the CAP_SYS_ADMIN capability can change the value in this file ๐
๐ /proc/sys/kernel/l2cr
(PowerPC only ๐) This file contains a flag controlling the L2 cache of G3 processor boards. If 0, the cache is disabled. Enabled if nonzero.
๐ฆ /proc/sys/kernel/modprobe
This file contains the pathname for the kernel module loader. The default value is /sbin/modprobe.
Heads up though โ this file is present only if the kernel is built with the CONFIG_MODULES (CONFIG_KMOD in Linux 2.6.26 and earlier) option enabled. It's described by the Linux kernel source file Documentation/kmod.txt (present only in Linux 2.4 and earlier).
๐ /proc/sys/kernel/modules_disabled (since Linux 2.6.31)
A toggle value saying whether modules are allowed to be loaded in an otherwise modular kernel. This toggle defaults to off (0), but it can be set true (1).
Okay bestie, listen carefully because this one does not come back: once it's true, modules can be neither loaded nor unloaded, and the toggle cannot be set back to false. It's a one-way door ๐ฅ
The file is present only if the kernel is built with the CONFIG_MODULES option enabled.
โจ /proc/sys/kernel/msgmax (since Linux 2.2)
This file defines a system-wide limit specifying the maximum number of bytes in a single message written on a System V message queue ๐ฌ
โจ /proc/sys/kernel/msgmni (since Linux 2.4)
This file defines the system-wide limit on the number of message queue identifiers. See also /proc/sys/kernel/auto_msgmni ๐
โจ /proc/sys/kernel/msgmnb (since Linux 2.2)
This file defines a system-wide parameter used to initialize the msg_qbytes setting for message queues created afterwards. The msg_qbytes setting specifies the maximum number of bytes that may be written to the message queue ๐จ
๐ซถ /proc/sys/kernel/ngroups_max (since Linux 2.6.4)
This is a read-only file that displays the upper limit on the number of a process's group memberships ๐ฏโโ๏ธ
๐ /proc/sys/kernel/ns_last_pid (since Linux 3.3)
Go read pid_namespaces(7) ๐ซถ
๐ธ /proc/sys/kernel/ostype and /proc/sys/kernel/osrelease
These files give substrings of /proc/version ๐ง
๐ธ /proc/sys/kernel/overflowgid and /proc/sys/kernel/overflowuid
These files duplicate the files /proc/sys/fs/overflowgid and /proc/sys/fs/overflowuid. Literally twins, same energy ๐
๐ /proc/sys/kernel/panic
This file gives read/write access to the kernel variable panic_timeout.
- If this is zero, the kernel will loop on a panic ๐ตโ๐ซ
- If nonzero, it indicates the kernel should autoreboot after this number of seconds
When you use the software watchdog device driver, the recommended setting is 60 โฑ๏ธ
๐ฅ /proc/sys/kernel/panic_on_oops (since Linux 2.5.68)
This file controls the kernel's behavior when an oops or BUG is encountered.
- If this file contains
0, the system tries to continue operation ๐ซถ - If it contains
1, the system delays a few seconds (to giveklogdtime to record the oops output) and then panics ๐
And if the /proc/sys/kernel/panic file is also nonzero, then the machine will be rebooted ๐ญ
โญ /proc/sys/kernel/pid_max (since Linux 2.5.34)
This file specifies the value at which PIDs wrap around โ i.e., the value in this file is one greater than the maximum PID. PIDs greater than this value are not allocated, which means the value in this file also acts as a system-wide limit on the total number of processes and threads ๐
The default value for this file, 32768, results in the same range of PIDs as on earlier kernels. On 32-bit platforms, 32768 is the maximum value for pid_max. On 64-bit systems, pid_max can be set to any value up to 2^22 (PID_MAX_LIMIT, approximately 4 million) ๐ข
๐ /proc/sys/kernel/powersave-nap (PowerPC only)
This file contains a flag. If it's set, Linux-PPC will use the "nap" mode of powersaving; otherwise, the "doze" mode will be used ๐ดโจ
๐ /proc/sys/kernel/printk
Go read syslog(2) ๐ซถ
๐ฆ /proc/sys/kernel/pty (since Linux 2.6.4)
This directory contains two files relating to the number of UNIX 98 pseudoterminals (see pts(4)) on the system ๐
๐
/proc/sys/kernel/pty/max
This file defines the maximum number of pseudoterminals.
๐
/proc/sys/kernel/pty/nr
This read-only file indicates how many pseudoterminals are currently in use.
๐ /proc/sys/kernel/random/
This directory contains various parameters controlling the operation of the file /dev/random. See random(4) for further information ๐ฒโจ
๐ง /proc/sys/kernel/random/uuid (since Linux 2.4)
Each read from this read-only file returns a randomly generated 128-bit UUID, as a string in the standard UUID format ๐๐
/proc/sys/kernel/randomize_va_space (since Linux 2.6.12)
okay so this file picks the whole system's address space layout randomization (ASLR) policy โ but ONLY on architectures that actually support ASLR, bestie. Three values go in here:
0โ turns ASLR all the way off. This is the default for architectures that don't support ASLR, and also when the kernel gets booted with thenorandmapsparameter.1โ makes the addresses ofmmap(2)allocations, the stack, and the VDSO page randomized. Which means (among other lil things) shared libraries get loaded at randomized addresses, and the text segment of PIE-linked binaries also gets loaded at a randomized address. This value is the default if the kernel was configured withCONFIG_COMPAT_BRK.2โ (since Linux 2.6.25) also supports heap randomization โจ. This value is the default if the kernel was not configured withCONFIG_COMPAT_BRK.
/proc/sys/kernel/real-root-dev
fr this one is just documented in the Linux kernel source file Documentation/admin-guide/initrd.rst. That's the whole entry. periodt ๐
/proc/sys/kernel/reboot-cmd (Sparc only)
ngl this file seems to be a way to hand an argument over to the SPARC ROM/Flash boot loader. Maybe to tell it what to do after rebooting? ๐ the confidence is giving absolutely nothing and I respect it.
/proc/sys/kernel/rtsig-max
(up to and including Linux 2.6.7; see setrlimit(2)) you can use this file to tune the maximum number of POSIX real-time (queued) signals that can be outstanding in the system.
/proc/sys/kernel/rtsig-nr
(up to and including Linux 2.6.7.) this file shows you the number of POSIX real-time signals currently queued.
/proc/pid/sched_autogroup_enabled (since Linux 2.6.38)
See sched(7). go read the lore bestie ๐ฆ
/proc/sys/kernel/sched_child_runs_first (since Linux 2.6.23)
value zero in this file means that, after a fork(2), the parent gets scheduled on the CPU first. a nonzero value means the child gets scheduled first. (obvs on a multiprocessor system, the parent and the child might both immediately get scheduled on a CPU, no drama.)
/proc/sys/kernel/sched_rr_timeslice_ms (since Linux 3.9)
/proc/sys/kernel/sched_rt_period_us (since Linux 2.6.25)
See sched(7).
/proc/sys/kernel/sched_rt_runtime_us (since Linux 2.6.25)
See sched(7).
/proc/sys/kernel/seccomp/ (since Linux 4.14)
this directory serves up extra seccomp info and configuration. See seccomp(2) for the full tea โ
/proc/sys/kernel/sem (since Linux 2.4)
this file holds 4 numbers defining the limits for System V IPC semaphores. the fields, in order, are:
SEMMSLโ the maximum semaphores per semaphore set.SEMMNSโ a system-wide limit on the number of semaphores in all semaphore sets.SEMOPMโ the maximum number of operations that may be specified in asemop(2)call.SEMMNIโ a system-wide limit on the maximum number of semaphore identifiers.
/proc/sys/kernel/sg-big-buff
this file shows the size of the generic SCSI device (sg) buffer. You can't tune it just yet, but you could change it at compile time by editing include/scsi/sg.h and changing the value of SG_BIG_BUFF. However, there shouldn't be any reason to change this value. like, none. leave her alone ๐
/proc/sys/kernel/shm_rmid_forced (since Linux 3.1)
set this file to 1 and all System V shared memory segments get marked for destruction the moment the number of attached processes drops to zero. in other words, you can no longer create shared memory segments that exist independently of any attached process. she's clingy now ๐
the effect is as though a shmctl(2) IPC_RMID was performed on all existing segments and all segments created in the future (until this file is reset to 0). note that existing segments attached to no process get immediately destroyed when this file is set to 1. setting this option will also destroy segments that were created but never attached, upon termination of the process that created the segment with shmget(2).
setting this file to 1 gives you a way of ensuring that all System V shared memory segments are counted against the resource usage and resource limits (see the description of RLIMIT_AS in getrlimit(2)) of at least one process.
Because setting this file to 1 produces behavior that is nonstandard and could also break existing applications, the default value in this file is 0. Set this file to 1 only if you have a good understanding of the semantics of the applications using System V shared memory on your system.
okay this is the serious one ๐จ the default is 0 for a reason โ flipping it can break your apps. know what you're doing before you touch it.
/proc/sys/kernel/shmall (since Linux 2.2)
this file contains the system-wide limit on the total number of pages of System V shared memory.
/proc/sys/kernel/shmmax (since Linux 2.2)
you can use this file to query and set the run-time limit on the maximum (System V IPC) shared memory segment size that can be created. shared memory segments up to 1 GB are now supported in the kernel. this value defaults to SHMMAX.
/proc/sys/kernel/shmmni (since Linux 2.4)
this file specifies the system-wide maximum number of System V shared memory segments that can be created.
/proc/sys/kernel/sysctl_writes_strict (since Linux 3.16)
the value in this file decides how the file offset affects the behavior of updating entries in files under /proc/sys. three possible values, take your pick:
-1โ legacy handling, with noprintkwarnings. eachwrite(2)must fully contain the value to be written, and multiple writes on the same file descriptor will overwrite the entire value, regardless of the file position.0โ (default) same behavior as for-1, butprintkwarnings get written for processes that perform writes when the file offset is not 0.1โ respect the file offset when writing strings into/proc/sysfiles. multiple writes will append to the value buffer. anything written beyond the maximum length of the value buffer gets ignored. writes to numeric/proc/sysentries must always be at file offset 0 and the value must be fully contained in the buffer provided towrite(2).
/proc/sys/kernel/sysrq
this file controls the functions allowed to be invoked by the SysRq key. by default, the file contains 1, meaning every possible SysRq request is allowed (in older kernel versions, SysRq was disabled by default and you were required to specifically enable it at run-time, but that's not the case any more). possible values in this file:
0โ disable sysrq completely1โ enable all functions of sysrq> 1โ bit mask of allowed sysrq functions, as follows:2โ enable control of console logging level4โ enable control of keyboard (SAK, unraw)8โ enable debugging dumps of processes etc.16โ enable sync command32โ enable remount read-only64โ enable signaling of processes (term, kill, oom-kill)128โ allow reboot/poweroff256โ allow nicing of all real-time tasks
this file is present only if the CONFIG_MAGIC_SYSRQ kernel configuration option is enabled. for further details see the Linux kernel source file Documentation/admin-guide/sysrq.rst.
/proc/sys/kernel/version
this file contains a string such as:
#5 Wed Feb 25 21:49:24 MET 1998
the "#5" means that this is the fifth kernel built from this source base, and the date following it indicates the time the kernel was built. cute lil receipt ๐งพโจ
/proc/sys/kernel/threads-max (since Linux 2.3.11)
this file specifies the system-wide limit on the number of threads (tasks) that can be created on the system.
Since Linux 4.1, the value that can be written to threads-max is bounded. the minimum value you can write is 20. the maximum value you can write is given by the constant FUTEX_TID_MASK (0x3fffffff). if a value outside of this range is written to threads-max, the error EINVAL occurs.
the value written gets checked against the available RAM pages. if the thread structures would occupy too much (more than 1/8th) of the available RAM pages, threads-max is reduced accordingly.
/proc/sys/kernel/yama/ptrace_scope (since Linux 3.5)
See ptrace(2).
/proc/sys/kernel/zero-paged (PowerPC only)
this file contains a flag. when it's enabled (nonzero), Linux-PPC will pre-zero pages in the idle loop, possibly speeding up get_free_pages. power efficiency slay ๐ฅ
๐ SEE ALSO ๐
and that's a wrap bestie ๐ this whole documentation moment came to you courtesy of Linux man-pages 6.20, dated 2026-02-08. go forth, read your /proc, and stay hydrated ๐ซถ๐
โจ
๐ฆ where this page comes from
- arch rolling: man-pages 6.20-1 ยท BSD-2-Clause AND BSD-3-Clause AND BSD-4.3TAHOE AND BSD-4-Clause-UC AND GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-3.0-linking-exception AND LGPL-3.0-or-later AND LicenseRef-Public-Domain AND LicenseRef-UltraPermissive AND Linux-man-pages-1-para AND Linux-man-pages-copyleft AND Linux-man-pages-copyleft-2-para AND Linux-man-pages-copyleft-var AND MIT AND Spencer-94
- nixpkgs unstable: man-pages 6.20
- ๐ the page's license: GPL-3.0-or-later
- Copyright 1994-1995, Daniel Quinlan <Daniel.Quinlan@linux.org>
- Copyright 2002-2017, Michael Kerrisk <mtk.manpages@gmail.com>
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms