GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing docs.kernel.org — Documentation for /proc/sys/kernel/ — The Linux Kernel documentation Documentation for /proc/sys/kernel/¶Copyright (c) 1998, 1999, Rik van Riel <riel@nl.linux.org> Copyright (c) 2009, Shen Feng<shen@cn.fujitsu.com> For general info and legal blurb, please look in Documentation for /proc/sys. This file contains documentation for the sysctl files in
The files in this directory can be used to tune and monitor miscellaneous and general things in the operation of the Linux kernel. Since some of the files can be used to screw up your system, it is advisable to read both documentation and source before actually making adjustments. Currently, these files might (depending on your configuration)
show up in acct¶highwater lowwater frequency If BSD-style process accounting is enabled these values control
its behaviour. If free space on filesystem where the log lives
goes below 4 2 30 That is, suspend accounting if free space drops below 2%; resume it if it increases to at least 4%; consider information about amount of free space valid for 30 seconds. acpi_video_flags¶See Video issues with S3 resume. This allows the video resume mode to be set,
in a similar fashion to the
arch¶The machine hardware name, the same output as auto_msgmni¶This variable has no effect and may be removed in future kernel releases. Reading it always returns 0. Up to Linux 3.17, it enabled/disabled automatic recomputing of msgmni upon memory add/remove or upon IPC namespace creation/removal. Echoing “1” into this file enabled msgmni automatic recomputing. Echoing “0” turned it off. The default value was 1. bootloader_type (x86 only)¶This gives the bootloader type number as indicated by the bootloader,
shifted left by 4, and OR’d with the low four bits of the bootloader
version. The reason for this encoding is that this used to match the
See the bootloader_version (x86 only)¶The complete bootloader version number. In the example above, this file will contain the value 564 = 0x234. See the bpf_stats_enabled¶Controls whether the kernel should collect statistics on BPF programs
(total time spent running, number of times run...). Enabling
statistics causes a slight reduction in performance on each program
run. The statistics can be seen using
cad_pid¶This is the pid which will be signalled on reboot (notably, by
Ctrl-Alt-Delete). Writing a value to this file which doesn’t
correspond to a running process will result in See also ctrl-alt-del. cap_last_cap¶Highest valid capability of the running kernel. Exports
core_pattern¶
core_pipe_limit¶This sysctl is only applicable when core_pattern is configured to
pipe core files to a user space helper (when the first character of
core_sort_vma¶The default coredump writes VMAs in address order. By setting
core_uses_pid¶The default coredump filename is “core”. By setting
ctrl-alt-del¶When the value in this file is 0, ctrl-alt-del is trapped and
sent to the
dmesg_restrict¶This toggle indicates whether unprivileged users are prevented
from using The kernel config option domainname & hostname¶These files can be used to set the NIS/YP domainname and the hostname of your box in exactly the same way as the commands domainname and hostname, i.e.: # echo "darkstar" > /proc/sys/kernel/hostname # echo "mydomain" > /proc/sys/kernel/domainname has the same effect as: # hostname "darkstar" # domainname "mydomain" Note, however, that the classic darkstar.frop.org has the
hostname “darkstar” and DNS (Internet Domain Name Server)
domainname “frop.org”, not to be confused 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 firmware_config¶See Fallback mechanisms. The entries in this directory allow the firmware loader helper fallback to be controlled:
ftrace_dump_on_oops¶Determines whether
Multiple instance dump is also supported, and instances are separated by commas. If global buffer also needs to be dumped, please specify the dump mode (1/2/orig_cpu) first for global buffer. So for example to dump “foo” and “bar” instance buffer on all CPUs, user can: echo "foo,bar" > /proc/sys/kernel/ftrace_dump_on_oops To dump global buffer and “foo” instance buffer on all CPUs along with the “bar” instance buffer on CPU that triggered the oops, user can: echo "1,foo,bar=2" > /proc/sys/kernel/ftrace_dump_on_oops ftrace_enabled, stack_tracer_enabled¶hardlockup_all_cpu_backtrace¶This value controls the hard lockup detector behavior when a hard lockup condition is detected as to whether or not to gather further debug information. If enabled, arch-specific all-CPU stack dumping will be initiated.
hardlockup_panic¶This parameter can be used to control whether the kernel panics when a hard lockup is detected.
See Softlockup detector and hardlockup detector (aka nmi_watchdog) for more information. This can also be set using the nmi_watchdog kernel parameter. hotplug¶Path for the hotplug policy agent.
Default value is This file only exists when hung_task_all_cpu_backtrace¶If this option is set, the kernel will send an NMI to all CPUs to dump their backtraces when a hung task is detected. This file shows up if CONFIG_DETECT_HUNG_TASK and CONFIG_SMP are enabled. 0: Won’t show all CPUs backtraces when a hung task is detected. This is the default behavior. 1: Will non-maskably interrupt all CPUs and dump their backtraces when a hung task is detected. hung_task_panic¶When set to a non-zero value, a kernel panic will be triggered if the
number of hung tasks found during a single scan reaches this value.
This file shows up if
hung_task_check_count¶The upper bound on the number of tasks that are checked.
This file shows up if hung_task_detect_count¶Indicates the total number of tasks that have been detected as hung since the system boot or since the counter was reset. The counter is zeroed when a value of 0 is written. This file shows up if hung_task_sys_info¶A comma separated list of extra system information to be dumped when hung task is detected, for example, “tasks,mem,timers,locks,...”. Refer ‘panic_sys_info’ section below for more details. hung_task_timeout_secs¶When a task in D state did not get scheduled
for more than this value report a warning.
This file shows up if 0 means infinite timeout, no checking is done. Possible values to set are in range {0: hung_task_check_interval_secs¶Hung task check interval. If hung task checking is enabled
(see hung_task_timeout_secs), the check is done every
0 (default) means use Possible values to set are in range {0: hung_task_warnings¶The maximum number of warnings to report. During a check interval
if a hung task is detected, the internal warning budget is decreased by 1.
When this budget reaches 0, no more detailed warnings will be reported. The
warning budget is reset to the configured limit when no hung task is found.
This file shows up if -1: report an infinite number of warnings. hyperv_record_panic_msg¶Controls whether the panic kmsg data should be reported to Hyper-V.
ignore-unaligned-usertrap¶On architectures where unaligned accesses cause traps, and where this
feature is supported (
See also unaligned-trap. io_uring_disabled¶Prevents all processes from creating new io_uring instances. Enabling this shrinks the kernel’s attack surface.
io_uring_group¶When io_uring_disabled is set to 1, a process must either be privileged (CAP_SYS_ADMIN) or be in the io_uring_group group in order to create an io_uring instance. If io_uring_group is set to -1 (the default), only processes with the CAP_SYS_ADMIN capability may create io_uring instances. kernel_sys_info¶A comma separated list of extra system information to be dumped when soft/hard lockup is detected, for example, “tasks,mem,timers,locks,...”. Refer ‘panic_sys_info’ section below for more details. It serves as the default kernel control knob, which will take effect
when a kernel module calls kexec_load_disabled¶A toggle indicating if the syscalls kexec_load_limit_panic¶This parameter specifies a limit to the number of times the syscalls
kexec_load_limit_reboot¶Similar functionality as kptr_restrict¶This toggle indicates whether restrictions are placed on
exposing kernel addresses via When When When For disabling these security restrictions early at boot time (and once
for all), use the softlockup_sys_info & hardlockup_sys_info¶A comma separated list of extra system information to be dumped when soft/hard lockup is detected, for example, “tasks,mem,timers,locks,...”. Refer ‘panic_sys_info’ section below for more details. modprobe¶The full path to the usermode helper for autoloading kernel modules,
by default This sysctl only affects module autoloading. It has no effect on the ability to explicitly insert modules. This sysctl can be used to debug module loading requests: echo '#! /bin/sh' > /tmp/modprobe echo 'echo "$@" >> /tmp/modprobe.log' >> /tmp/modprobe echo 'exec /sbin/modprobe "$@"' >> /tmp/modprobe chmod a+x /tmp/modprobe echo /tmp/modprobe > /proc/sys/kernel/modprobe Alternatively, if this sysctl is set to the empty string, then module autoloading is completely disabled. The kernel will not try to execute a usermode helper at all, nor will it call the kernel_module_request LSM hook. If CONFIG_STATIC_USERMODEHELPER=y is set in the kernel configuration, then the configured static usermode helper overrides this sysctl, except that the empty string is still accepted to completely disable module autoloading as described above. modules_disabled¶A toggle value indicating if modules are allowed to be loaded in an otherwise modular kernel. This toggle defaults to off (0), but can be set true (1). Once true, modules can be neither loaded nor unloaded, and the toggle cannot be set back to false. Generally used with the kexec_load_disabled toggle. msgmax, msgmnb, and msgmni¶
All of these parameters are set per ipc namespace. The maximum number of bytes
in POSIX message queues is limited by msg_next_id, sem_next_id, and shm_next_id (System V IPC)¶These three toggles allows to specify desired id for next allocated IPC object: message, semaphore or shared memory respectively. By default they are equal to -1, which means generic allocation logic.
Possible values to set are in range {0:
ngroups_max¶Maximum number of supplementary groups, _i.e._ the maximum size which
nmi_watchdog¶This parameter can be used to control the NMI watchdog (i.e. the hard lockup detector) on x86 systems.
The hard lockup detector monitors each CPU for its ability to respond to timer interrupts. The mechanism utilizes CPU performance counter registers that are programmed to generate Non-Maskable Interrupts (NMIs) periodically while a CPU is busy. Hence, the alternative name ‘NMI watchdog’. The NMI watchdog is disabled by default if the kernel is running as a guest in a KVM virtual machine. This default can be overridden by adding: nmi_watchdog=1 to the guest kernel command line (see The kernel’s command-line parameters). nmi_wd_lpm_factor (PPC only)¶Factor to apply to the NMI watchdog timeout (only when A value of 0 means no change. The default value is 200 meaning the NMI
watchdog is set to 30s (based on numa_balancing¶Enables/disables and configures automatic page fault based NUMA memory balancing. Memory is moved automatically to nodes that access it often. The value to set can be the result of ORing the following:
Or NUMA_BALANCING_NORMAL to optimize page placement among different NUMA nodes to reduce remote accessing. On NUMA machines, there is a performance penalty if remote memory is accessed by a CPU. When this feature is enabled the kernel samples what task thread is accessing memory by periodically unmapping pages and later trapping a page fault. At the time of the page fault, it is determined if the data being accessed should be migrated to a local memory node. The unmapping of pages and trapping faults incur additional overhead that ideally is offset by improved memory locality but there is no universal guarantee. If the target workload is already bound to NUMA nodes then this feature should be disabled. Or NUMA_BALANCING_MEMORY_TIERING to optimize page placement among different types of memory (represented as different NUMA nodes) to place the hot pages in the fast memory. This is implemented based on unmapping and page fault too. numa_balancing_promote_rate_limit_MBps¶Too high promotion/demotion throughput between different memory types may hurt application latency. This can be used to rate limit the promotion throughput. The per-node max promotion throughput in MB/s will be limited to be no more than the set value. A rule of thumb is to set this to less than 1/10 of the PMEM node write bandwidth. oops_all_cpu_backtrace¶If this option is set, the kernel will send an NMI to all CPUs to dump their backtraces when an oops event occurs. It should be used as a last resort in case a panic cannot be triggered (to protect VMs running, for example) or kdump can’t be collected. This file shows up if CONFIG_SMP is enabled. 0: Won’t show all CPUs backtraces when an oops is detected. This is the default behavior. 1: Will non-maskably interrupt all CPUs and dump their backtraces when an oops event is detected. oops_limit¶Number of kernel oopses after which the kernel should panic when
osrelease, ostype & version¶# cat osrelease 2.1.88 # cat ostype Linux # cat version #5 Wed Feb 25 21:49:24 MET 1998 The files overflowgid & overflowuid¶if your architecture did not always support 32-bit UIDs (i.e. arm, i386, m68k, sh, and sparc32), a fixed UID and GID will be returned to applications that use the old 16-bit UID/GID system calls, if the actual UID or GID would exceed 65535. These sysctls allow you to change the value of the fixed UID and GID. The default is 65534. panic¶The value in this file determines the behaviour of the kernel on a panic:
When you use the software watchdog, the recommended setting is 60. panic_on_io_nmi¶Controls the kernel’s behavior when a CPU receives an NMI caused by an IO error.
panic_on_oops¶Controls the kernel’s behaviour when an oops or BUG is encountered.
panic_on_stackoverflow¶Controls the kernel’s behavior when detecting the overflows of
kernel, IRQ and exception stacks except a user stack.
This file shows up if
panic_on_unrecovered_nmi¶The default Linux behaviour on an NMI of either memory or unknown is to continue operation. For many environments such as scientific computing it is preferable that the box is taken out and the error dealt with than an uncorrected parity/ECC error get propagated. A small number of systems do generate NMIs for bizarre random reasons such as power management so the default is off. That sysctl works like the existing panic controls already in that directory. panic_on_warn¶Calls
panic_print¶Bitmask for printing system info when panic happens. User can chose combination of the following bits:
So for example to print tasks and memory info on panic, user can: echo 3 > /proc/sys/kernel/panic_print panic_sys_info¶A comma separated list of extra information to be dumped on panic, for example, “tasks,mem,timers,...”. It is a human readable alternative to ‘panic_print’. Possible values are:
panic_on_rcu_stall¶When set to 1, calls
max_rcu_stall_to_panic¶When When perf_cpu_time_max_percent¶Hints to the kernel how much CPU time it should be allowed to use to handle perf sampling events. If the perf subsystem is informed that its samples are exceeding this limit, it will drop its sampling frequency to attempt to reduce its CPU usage. Some perf sampling happens in NMIs. If these samples unexpectedly take too long to execute, the NMIs can become stacked up next to each other so much that nothing else is allowed to execute.
perf_event_paranoid¶Controls use of the performance events system by unprivileged users (without CAP_PERFMON). The default value is 2. For backward compatibility reasons access to system performance monitoring and observability remains open for CAP_SYS_ADMIN privileged processes but CAP_SYS_ADMIN usage for secure system performance monitoring and observability operations is discouraged with respect to CAP_PERFMON use cases.
perf_event_max_stack¶Controls maximum number of stack frames to copy for ( This can only be done when no events are in use that have callchains
enabled, otherwise writing to this file will return The default value is 127. perf_event_mlock_kb¶Control size of per-cpu ring buffer not counted against mlock limit. The default value is 512 + 1 page perf_event_max_contexts_per_stack¶Controls maximum number of stack frame context entries for
( This can only be done when no events are in use that have callchains
enabled, otherwise writing to this file will return The default value is 8. perf_user_access (arm64 and riscv only)¶Controls user space access for reading perf event counters.
pid_max¶PID allocation wrap value. When the kernel’s next PID value
reaches this value, it wraps back to a minimum PID value.
PIDs of value ns_last_pid¶The last pid allocated in the current (the one task using this sysctl lives in) pid namespace. When selecting a pid for a next task on fork kernel tries to allocate a number starting from this one. powersave-nap (PPC only)¶If set, Linux-PPC will use the ‘nap’ mode of powersaving, otherwise the ‘doze’ mode will be used. printk¶The four values in printk denote: These values influence
printk_delay¶Delay each printk message in Value from 0 - 10000 is allowed. printk_ratelimit¶Some warning messages are rate limited. A value of 0 will disable rate limiting. printk_ratelimit_burst¶While long term we enforce one message per printk_ratelimit
seconds, we do allow a burst of messages to pass through.
The default value is 10 messages. printk_devkmsg¶Control the logging to
The kernel command line parameter pty¶random¶This is a directory, with the following entries:
randomize_va_space¶This option can be used to select the type of process address space randomization that is used in the system, for architectures that support this feature.
reboot-cmd (SPARC only)¶??? This seems to be a way to give an argument to the Sparc ROM/Flash boot loader. Maybe to tell it what to do after rebooting. ??? sched_energy_aware¶Enables/disables Energy Aware Scheduling (EAS). EAS starts automatically on platforms where it can run (that is, platforms with asymmetric CPU topologies and having an Energy Model available). If your platform happens to meet the requirements for EAS but you do not want to use it, change this value to 0. On Non-EAS platforms, write operation fails and read doesn’t return anything. task_delayacct¶Enables/disables task delay accounting (see Delay accounting. Enabling this feature incurs a small amount of overhead in the scheduler but is useful for debugging and performance tuning. It is required by some tools such as iotop. sched_schedstats¶Enables/disables scheduler statistics. Enabling this feature incurs a small amount of overhead in the scheduler but is useful for debugging and performance tuning. sched_util_clamp_min¶Max allowed minimum utilization. Default value is 1024, which is the maximum possible value. It means that any requested uclamp.min value cannot be greater than sched_util_clamp_min, i.e., it is restricted to the range [0:sched_util_clamp_min]. sched_util_clamp_max¶Max allowed maximum utilization. Default value is 1024, which is the maximum possible value. It means that any requested uclamp.max value cannot be greater than sched_util_clamp_max, i.e., it is restricted to the range [0:sched_util_clamp_max]. sched_util_clamp_min_rt_default¶By default Linux is tuned for performance. Which means that RT tasks always run at the highest frequency and most capable (highest capacity) CPU (in heterogeneous systems). Uclamp achieves this by setting the requested uclamp.min of all RT tasks to 1024 by default, which effectively boosts the tasks to run at the highest frequency and biases them to run on the biggest CPU. This knob allows admins to change the default behavior when uclamp is being used. In battery powered devices particularly, running at the maximum capacity and frequency will increase energy consumption and shorten the battery life. This knob is only effective for RT tasks which the user hasn’t modified their
requested uclamp.min value via This knob will not escape the range constraint imposed by sched_util_clamp_min defined above. For example if
Then the boost will be clamped to 600 because 800 is outside of the permissible range of [0:600]. This could happen for instance if a powersave mode will restrict all boosts temporarily by modifying sched_util_clamp_min. As soon as this restriction is lifted, the requested sched_util_clamp_min_rt_default will take effect. seccomp¶shmall¶This parameter sets the total amount of shared memory pages that can be used
inside ipc namespace. The shared memory pages counting occurs for each ipc
namespace separately and is not inherited. Hence, If you are not sure what the default # getconf PAGE_SIZE To reduce or disable the ability to allocate shared memory, you must create a new ipc namespace, set this parameter to the required value and prohibit the creation of a new ipc namespace in the current user namespace or cgroups can be used. shmmax¶This value can be used to query and set the run time limit
on the maximum shared memory segment size that can be created.
Shared memory segments up to 1Gb are now supported in the
kernel. This value defaults to shmmni¶This value determines the maximum number of shared memory segments.
4096 by default ( shm_rmid_forced¶Linux lets you set resource limits, including how much memory one
process can consume, via Note that if you change this from 0 to 1, already created segments without users and with a dead originative process will be destroyed. syscall_user_dispatch¶Controls whether userspace may arm Syscall User Dispatch via
Only present when the kernel is built with sysctl_writes_strict¶Control how file position affects the behavior of updating sysctl values
via the
softlockup_all_cpu_backtrace¶This value controls the soft lockup detector thread’s behavior when a soft lockup condition is detected as to whether or not to gather further debug information. If enabled, each cpu will be issued an NMI and instructed to capture stack trace. This feature is only applicable for architectures which support NMI.
softlockup_panic¶This parameter can be used to control whether the kernel panics when a soft lockup is detected.
This can also be set using the softlockup_panic kernel parameter. soft_watchdog¶This parameter can be used to control the soft lockup detector.
The soft lockup detector monitors CPUs for threads that are hogging the CPUs without rescheduling voluntarily, and thus prevent the ‘migration/N’ threads from running, causing the watchdog work fail to execute. The mechanism depends on the CPUs ability to respond to timer interrupts which are needed for the watchdog work to be queued by the watchdog timer function, otherwise the NMI watchdog — if enabled — can detect a hard lockup condition. split_lock_mitigate (x86 only)¶On x86, each “split lock” imposes a system-wide performance penalty. On larger systems, large numbers of split locks from unprivileged users can result in denials of service to well-behaved and potentially more important users. The kernel mitigates these bad users by detecting split locks and imposing penalties: forcing them to wait and only allowing one core to execute split locks at a time. These mitigations can make those bad applications unbearably slow. Setting split_lock_mitigate=0 may restore some application performance, but will also increase system exposure to denial of service attacks from split lock users.
stack_erasing¶This parameter can be used to control kernel stack erasing at the end
of syscalls for kernels built with That erasing reduces the information which kernel stack leak bugs can reveal and blocks some uninitialized stack variable attacks. The tradeoff is the performance impact: on a single CPU system kernel compilation sees a 1% slowdown, other systems and workloads may vary.
stop-a (SPARC only)¶Controls Stop-A:
Stop-A is always enabled on a panic, so that the user can return to the boot PROM. sysrq¶tainted¶Non-zero if the kernel has been tainted. Numeric values, which can be ORed together. The letters are seen in “Tainted” line of Oops reports.
See Tainted kernels for more information.
threads-max¶This value controls the maximum number of threads that can be created
using During initialization the kernel sets this value such that even if the maximum number of threads is created, the thread structures occupy only a part (1/8th) of the available RAM pages. The minimum value that can be written to The maximum value that can be written to If a value outside of this range is written to timer_migration¶When set to a non-zero value, attempt to migrate high-resolution timers from nohz isolated (nohz_full) to housekeeping CPUs. See CPU Isolation and The kernel’s command-line parameters. Default is set (1). traceoff_on_warning¶When set, disables tracing (see ftrace - Function Tracer) when a
tracepoint_printk¶When tracepoints are sent to echo 0 > /proc/sys/kernel/tracepoint_printk will stop tracepoints from being sent to echo 1 > /proc/sys/kernel/tracepoint_printk will send them to This only works if the kernel was booted with See The kernel’s command-line parameters and Boot-time tracing. unaligned-trap¶On architectures where unaligned accesses cause traps, and where this
feature is supported (
See also ignore-unaligned-usertrap. unknown_nmi_panic¶The value in this file affects behavior of handling NMI. When the value is non-zero, unknown NMI is trapped and then panic occurs. At that time, kernel debugging information is displayed on console. NMI switch that most IA32 servers have fires unknown NMI up, for example. If a system hangs up, try pressing the NMI switch. unprivileged_bpf_disabled¶Writing 1 to this entry will disable unprivileged calls to Writing 2 to this entry will also disable unprivileged calls to If
warn_limit¶Number of kernel warnings after which the kernel should panic when
watchdog¶This parameter can be used to disable or enable the soft lockup detector and the NMI watchdog (i.e. the hard lockup detector) at the same time.
The soft lockup detector and the NMI watchdog can also be disabled or
enabled individually, using the cat /proc/sys/kernel/watchdog the output of this command (0 or 1) shows the logical OR of
watchdog_cpumask¶This value can be used to control on which cpus the watchdog may run.
The default cpumask is all possible cores, but if Typically this value would only be touched in the The argument value is the standard cpulist format for cpumasks, so for example to enable the watchdog on cores 0, 2, 3, and 4 you might say: echo 0,2-4 > /proc/sys/kernel/watchdog_cpumask watchdog_thresh¶This value can be used to control the frequency of hrtimer and NMI events and the soft and hard lockup thresholds. The default threshold is 10 seconds. The softlockup threshold is ( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |