kernel.txt 9.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314
  1. Documentation for /proc/sys/kernel/* kernel version 2.2.10
  2. (c) 1998, 1999, Rik van Riel <riel@nl.linux.org>
  3. For general info and legal blurb, please look in README.
  4. ==============================================================
  5. This file contains documentation for the sysctl files in
  6. /proc/sys/kernel/ and is valid for Linux kernel version 2.2.
  7. The files in this directory can be used to tune and monitor
  8. miscellaneous and general things in the operation of the Linux
  9. kernel. Since some of the files _can_ be used to screw up your
  10. system, it is advisable to read both documentation and source
  11. before actually making adjustments.
  12. Currently, these files might (depending on your configuration)
  13. show up in /proc/sys/kernel:
  14. - acct
  15. - core_pattern
  16. - core_uses_pid
  17. - ctrl-alt-del
  18. - dentry-state
  19. - domainname
  20. - hostname
  21. - hotplug
  22. - java-appletviewer [ binfmt_java, obsolete ]
  23. - java-interpreter [ binfmt_java, obsolete ]
  24. - l2cr [ PPC only ]
  25. - modprobe ==> Documentation/kmod.txt
  26. - msgmax
  27. - msgmnb
  28. - msgmni
  29. - osrelease
  30. - ostype
  31. - overflowgid
  32. - overflowuid
  33. - panic
  34. - pid_max
  35. - powersave-nap [ PPC only ]
  36. - printk
  37. - real-root-dev ==> Documentation/initrd.txt
  38. - reboot-cmd [ SPARC only ]
  39. - rtsig-max
  40. - rtsig-nr
  41. - sem
  42. - sg-big-buff [ generic SCSI device (sg) ]
  43. - shmall
  44. - shmmax [ sysv ipc ]
  45. - shmmni
  46. - stop-a [ SPARC only ]
  47. - sysrq ==> Documentation/sysrq.txt
  48. - tainted
  49. - threads-max
  50. - version
  51. ==============================================================
  52. acct:
  53. highwater lowwater frequency
  54. If BSD-style process accounting is enabled these values control
  55. its behaviour. If free space on filesystem where the log lives
  56. goes below <lowwater>% accounting suspends. If free space gets
  57. above <highwater>% accounting resumes. <Frequency> determines
  58. how often do we check the amount of free space (value is in
  59. seconds). Default:
  60. 4 2 30
  61. That is, suspend accounting if there left <= 2% free; resume it
  62. if we got >=4%; consider information about amount of free space
  63. valid for 30 seconds.
  64. ==============================================================
  65. core_pattern:
  66. core_pattern is used to specify a core dumpfile pattern name.
  67. . max length 64 characters; default value is "core"
  68. . core_pattern is used as a pattern template for the output filename;
  69. certain string patterns (beginning with '%') are substituted with
  70. their actual values.
  71. . backward compatibility with core_uses_pid:
  72. If core_pattern does not include "%p" (default does not)
  73. and core_uses_pid is set, then .PID will be appended to
  74. the filename.
  75. . corename format specifiers:
  76. %<NUL> '%' is dropped
  77. %% output one '%'
  78. %p pid
  79. %u uid
  80. %g gid
  81. %s signal number
  82. %t UNIX time of dump
  83. %h hostname
  84. %e executable filename
  85. %<OTHER> both are dropped
  86. ==============================================================
  87. core_uses_pid:
  88. The default coredump filename is "core". By setting
  89. core_uses_pid to 1, the coredump filename becomes core.PID.
  90. If core_pattern does not include "%p" (default does not)
  91. and core_uses_pid is set, then .PID will be appended to
  92. the filename.
  93. ==============================================================
  94. ctrl-alt-del:
  95. When the value in this file is 0, ctrl-alt-del is trapped and
  96. sent to the init(1) program to handle a graceful restart.
  97. When, however, the value is > 0, Linux's reaction to a Vulcan
  98. Nerve Pinch (tm) will be an immediate reboot, without even
  99. syncing its dirty buffers.
  100. Note: when a program (like dosemu) has the keyboard in 'raw'
  101. mode, the ctrl-alt-del is intercepted by the program before it
  102. ever reaches the kernel tty layer, and it's up to the program
  103. to decide what to do with it.
  104. ==============================================================
  105. domainname & hostname:
  106. These files can be used to set the NIS/YP domainname and the
  107. hostname of your box in exactly the same way as the commands
  108. domainname and hostname, i.e.:
  109. # echo "darkstar" > /proc/sys/kernel/hostname
  110. # echo "mydomain" > /proc/sys/kernel/domainname
  111. has the same effect as
  112. # hostname "darkstar"
  113. # domainname "mydomain"
  114. Note, however, that the classic darkstar.frop.org has the
  115. hostname "darkstar" and DNS (Internet Domain Name Server)
  116. domainname "frop.org", not to be confused with the NIS (Network
  117. Information Service) or YP (Yellow Pages) domainname. These two
  118. domain names are in general different. For a detailed discussion
  119. see the hostname(1) man page.
  120. ==============================================================
  121. hotplug:
  122. Path for the hotplug policy agent.
  123. Default value is "/sbin/hotplug".
  124. ==============================================================
  125. l2cr: (PPC only)
  126. This flag controls the L2 cache of G3 processor boards. If
  127. 0, the cache is disabled. Enabled if nonzero.
  128. ==============================================================
  129. osrelease, ostype & version:
  130. # cat osrelease
  131. 2.1.88
  132. # cat ostype
  133. Linux
  134. # cat version
  135. #5 Wed Feb 25 21:49:24 MET 1998
  136. The files osrelease and ostype should be clear enough. Version
  137. needs a little more clarification however. The '#5' means that
  138. this is the fifth kernel built from this source base and the
  139. date behind it indicates the time the kernel was built.
  140. The only way to tune these values is to rebuild the kernel :-)
  141. ==============================================================
  142. overflowgid & overflowuid:
  143. if your architecture did not always support 32-bit UIDs (i.e. arm, i386,
  144. m68k, sh, and sparc32), a fixed UID and GID will be returned to
  145. applications that use the old 16-bit UID/GID system calls, if the actual
  146. UID or GID would exceed 65535.
  147. These sysctls allow you to change the value of the fixed UID and GID.
  148. The default is 65534.
  149. ==============================================================
  150. panic:
  151. The value in this file represents the number of seconds the
  152. kernel waits before rebooting on a panic. When you use the
  153. software watchdog, the recommended setting is 60.
  154. ==============================================================
  155. panic_on_oops:
  156. Controls the kernel's behaviour when an oops or BUG is encountered.
  157. 0: try to continue operation
  158. 1: delay a few seconds (to give klogd time to record the oops output) and
  159. then panic. If the `panic' sysctl is also non-zero then the machine will
  160. be rebooted.
  161. ==============================================================
  162. pid_max:
  163. PID allocation wrap value. When the kenrel's next PID value
  164. reaches this value, it wraps back to a minimum PID value.
  165. PIDs of value pid_max or larger are not allocated.
  166. ==============================================================
  167. powersave-nap: (PPC only)
  168. If set, Linux-PPC will use the 'nap' mode of powersaving,
  169. otherwise the 'doze' mode will be used.
  170. ==============================================================
  171. printk:
  172. The four values in printk denote: console_loglevel,
  173. default_message_loglevel, minimum_console_loglevel and
  174. default_console_loglevel respectively.
  175. These values influence printk() behavior when printing or
  176. logging error messages. See 'man 2 syslog' for more info on
  177. the different loglevels.
  178. - console_loglevel: messages with a higher priority than
  179. this will be printed to the console
  180. - default_message_level: messages without an explicit priority
  181. will be printed with this priority
  182. - minimum_console_loglevel: minimum (highest) value to which
  183. console_loglevel can be set
  184. - default_console_loglevel: default value for console_loglevel
  185. ==============================================================
  186. printk_ratelimit:
  187. Some warning messages are rate limited. printk_ratelimit specifies
  188. the minimum length of time between these messages (in jiffies), by
  189. default we allow one every 5 seconds.
  190. A value of 0 will disable rate limiting.
  191. ==============================================================
  192. printk_ratelimit_burst:
  193. While long term we enforce one message per printk_ratelimit
  194. seconds, we do allow a burst of messages to pass through.
  195. printk_ratelimit_burst specifies the number of messages we can
  196. send before ratelimiting kicks in.
  197. ==============================================================
  198. reboot-cmd: (Sparc only)
  199. ??? This seems to be a way to give an argument to the Sparc
  200. ROM/Flash boot loader. Maybe to tell it what to do after
  201. rebooting. ???
  202. ==============================================================
  203. rtsig-max & rtsig-nr:
  204. The file rtsig-max can be used to tune the maximum number
  205. of POSIX realtime (queued) signals that can be outstanding
  206. in the system.
  207. rtsig-nr shows the number of RT signals currently queued.
  208. ==============================================================
  209. sg-big-buff:
  210. This file shows the size of the generic SCSI (sg) buffer.
  211. You can't tune it just yet, but you could change it on
  212. compile time by editing include/scsi/sg.h and changing
  213. the value of SG_BIG_BUFF.
  214. There shouldn't be any reason to change this value. If
  215. you can come up with one, you probably know what you
  216. are doing anyway :)
  217. ==============================================================
  218. shmmax:
  219. This value can be used to query and set the run time limit
  220. on the maximum shared memory segment size that can be created.
  221. Shared memory segments up to 1Gb are now supported in the
  222. kernel. This value defaults to SHMMAX.
  223. ==============================================================
  224. tainted:
  225. Non-zero if the kernel has been tainted. Numeric values, which
  226. can be ORed together:
  227. 1 - A module with a non-GPL license has been loaded, this
  228. includes modules with no license.
  229. Set by modutils >= 2.4.9 and module-init-tools.
  230. 2 - A module was force loaded by insmod -f.
  231. Set by modutils >= 2.4.9 and module-init-tools.
  232. 4 - Unsafe SMP processors: SMP with CPUs not designed for SMP.