vm.txt 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699
  1. Documentation for /proc/sys/vm/* kernel version 2.6.29
  2. (c) 1998, 1999, Rik van Riel <riel@nl.linux.org>
  3. (c) 2008 Peter W. Morreale <pmorreale@novell.com>
  4. For general info and legal blurb, please look in README.
  5. ==============================================================
  6. This file contains the documentation for the sysctl files in
  7. /proc/sys/vm and is valid for Linux kernel version 2.6.29.
  8. The files in this directory can be used to tune the operation
  9. of the virtual memory (VM) subsystem of the Linux kernel and
  10. the writeout of dirty data to disk.
  11. Default values and initialization routines for most of these
  12. files can be found in mm/swap.c.
  13. Currently, these files are in /proc/sys/vm:
  14. - block_dump
  15. - compact_memory
  16. - dirty_background_bytes
  17. - dirty_background_ratio
  18. - dirty_bytes
  19. - dirty_expire_centisecs
  20. - dirty_ratio
  21. - dirty_writeback_centisecs
  22. - drop_caches
  23. - extfrag_threshold
  24. - hugepages_treat_as_movable
  25. - hugetlb_shm_group
  26. - laptop_mode
  27. - legacy_va_layout
  28. - lowmem_reserve_ratio
  29. - max_map_count
  30. - memory_failure_early_kill
  31. - memory_failure_recovery
  32. - min_free_kbytes
  33. - min_slab_ratio
  34. - min_unmapped_ratio
  35. - mmap_min_addr
  36. - nr_hugepages
  37. - nr_overcommit_hugepages
  38. - nr_trim_pages (only if CONFIG_MMU=n)
  39. - numa_zonelist_order
  40. - oom_dump_tasks
  41. - oom_kill_allocating_task
  42. - overcommit_memory
  43. - overcommit_ratio
  44. - page-cluster
  45. - panic_on_oom
  46. - percpu_pagelist_fraction
  47. - stat_interval
  48. - swappiness
  49. - vfs_cache_pressure
  50. - zone_reclaim_mode
  51. ==============================================================
  52. block_dump
  53. block_dump enables block I/O debugging when set to a nonzero value. More
  54. information on block I/O debugging is in Documentation/laptops/laptop-mode.txt.
  55. ==============================================================
  56. compact_memory
  57. Available only when CONFIG_COMPACTION is set. When 1 is written to the file,
  58. all zones are compacted such that free memory is available in contiguous
  59. blocks where possible. This can be important for example in the allocation of
  60. huge pages although processes will also directly compact memory as required.
  61. ==============================================================
  62. dirty_background_bytes
  63. Contains the amount of dirty memory at which the background kernel
  64. flusher threads will start writeback.
  65. Note: dirty_background_bytes is the counterpart of dirty_background_ratio. Only
  66. one of them may be specified at a time. When one sysctl is written it is
  67. immediately taken into account to evaluate the dirty memory limits and the
  68. other appears as 0 when read.
  69. ==============================================================
  70. dirty_background_ratio
  71. Contains, as a percentage of total system memory, the number of pages at which
  72. the background kernel flusher threads will start writing out dirty data.
  73. ==============================================================
  74. dirty_bytes
  75. Contains the amount of dirty memory at which a process generating disk writes
  76. will itself start writeback.
  77. Note: dirty_bytes is the counterpart of dirty_ratio. Only one of them may be
  78. specified at a time. When one sysctl is written it is immediately taken into
  79. account to evaluate the dirty memory limits and the other appears as 0 when
  80. read.
  81. Note: the minimum value allowed for dirty_bytes is two pages (in bytes); any
  82. value lower than this limit will be ignored and the old configuration will be
  83. retained.
  84. ==============================================================
  85. dirty_expire_centisecs
  86. This tunable is used to define when dirty data is old enough to be eligible
  87. for writeout by the kernel flusher threads. It is expressed in 100'ths
  88. of a second. Data which has been dirty in-memory for longer than this
  89. interval will be written out next time a flusher thread wakes up.
  90. ==============================================================
  91. dirty_ratio
  92. Contains, as a percentage of total system memory, the number of pages at which
  93. a process which is generating disk writes will itself start writing out dirty
  94. data.
  95. ==============================================================
  96. dirty_writeback_centisecs
  97. The kernel flusher threads will periodically wake up and write `old' data
  98. out to disk. This tunable expresses the interval between those wakeups, in
  99. 100'ths of a second.
  100. Setting this to zero disables periodic writeback altogether.
  101. ==============================================================
  102. drop_caches
  103. Writing to this will cause the kernel to drop clean caches, dentries and
  104. inodes from memory, causing that memory to become free.
  105. To free pagecache:
  106. echo 1 > /proc/sys/vm/drop_caches
  107. To free dentries and inodes:
  108. echo 2 > /proc/sys/vm/drop_caches
  109. To free pagecache, dentries and inodes:
  110. echo 3 > /proc/sys/vm/drop_caches
  111. As this is a non-destructive operation and dirty objects are not freeable, the
  112. user should run `sync' first.
  113. ==============================================================
  114. extfrag_threshold
  115. This parameter affects whether the kernel will compact memory or direct
  116. reclaim to satisfy a high-order allocation. /proc/extfrag_index shows what
  117. the fragmentation index for each order is in each zone in the system. Values
  118. tending towards 0 imply allocations would fail due to lack of memory,
  119. values towards 1000 imply failures are due to fragmentation and -1 implies
  120. that the allocation will succeed as long as watermarks are met.
  121. The kernel will not compact memory in a zone if the
  122. fragmentation index is <= extfrag_threshold. The default value is 500.
  123. ==============================================================
  124. hugepages_treat_as_movable
  125. This parameter is only useful when kernelcore= is specified at boot time to
  126. create ZONE_MOVABLE for pages that may be reclaimed or migrated. Huge pages
  127. are not movable so are not normally allocated from ZONE_MOVABLE. A non-zero
  128. value written to hugepages_treat_as_movable allows huge pages to be allocated
  129. from ZONE_MOVABLE.
  130. Once enabled, the ZONE_MOVABLE is treated as an area of memory the huge
  131. pages pool can easily grow or shrink within. Assuming that applications are
  132. not running that mlock() a lot of memory, it is likely the huge pages pool
  133. can grow to the size of ZONE_MOVABLE by repeatedly entering the desired value
  134. into nr_hugepages and triggering page reclaim.
  135. ==============================================================
  136. hugetlb_shm_group
  137. hugetlb_shm_group contains group id that is allowed to create SysV
  138. shared memory segment using hugetlb page.
  139. ==============================================================
  140. laptop_mode
  141. laptop_mode is a knob that controls "laptop mode". All the things that are
  142. controlled by this knob are discussed in Documentation/laptops/laptop-mode.txt.
  143. ==============================================================
  144. legacy_va_layout
  145. If non-zero, this sysctl disables the new 32-bit mmap layout - the kernel
  146. will use the legacy (2.4) layout for all processes.
  147. ==============================================================
  148. lowmem_reserve_ratio
  149. For some specialised workloads on highmem machines it is dangerous for
  150. the kernel to allow process memory to be allocated from the "lowmem"
  151. zone. This is because that memory could then be pinned via the mlock()
  152. system call, or by unavailability of swapspace.
  153. And on large highmem machines this lack of reclaimable lowmem memory
  154. can be fatal.
  155. So the Linux page allocator has a mechanism which prevents allocations
  156. which _could_ use highmem from using too much lowmem. This means that
  157. a certain amount of lowmem is defended from the possibility of being
  158. captured into pinned user memory.
  159. (The same argument applies to the old 16 megabyte ISA DMA region. This
  160. mechanism will also defend that region from allocations which could use
  161. highmem or lowmem).
  162. The `lowmem_reserve_ratio' tunable determines how aggressive the kernel is
  163. in defending these lower zones.
  164. If you have a machine which uses highmem or ISA DMA and your
  165. applications are using mlock(), or if you are running with no swap then
  166. you probably should change the lowmem_reserve_ratio setting.
  167. The lowmem_reserve_ratio is an array. You can see them by reading this file.
  168. -
  169. % cat /proc/sys/vm/lowmem_reserve_ratio
  170. 256 256 32
  171. -
  172. Note: # of this elements is one fewer than number of zones. Because the highest
  173. zone's value is not necessary for following calculation.
  174. But, these values are not used directly. The kernel calculates # of protection
  175. pages for each zones from them. These are shown as array of protection pages
  176. in /proc/zoneinfo like followings. (This is an example of x86-64 box).
  177. Each zone has an array of protection pages like this.
  178. -
  179. Node 0, zone DMA
  180. pages free 1355
  181. min 3
  182. low 3
  183. high 4
  184. :
  185. :
  186. numa_other 0
  187. protection: (0, 2004, 2004, 2004)
  188. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  189. pagesets
  190. cpu: 0 pcp: 0
  191. :
  192. -
  193. These protections are added to score to judge whether this zone should be used
  194. for page allocation or should be reclaimed.
  195. In this example, if normal pages (index=2) are required to this DMA zone and
  196. watermark[WMARK_HIGH] is used for watermark, the kernel judges this zone should
  197. not be used because pages_free(1355) is smaller than watermark + protection[2]
  198. (4 + 2004 = 2008). If this protection value is 0, this zone would be used for
  199. normal page requirement. If requirement is DMA zone(index=0), protection[0]
  200. (=0) is used.
  201. zone[i]'s protection[j] is calculated by following expression.
  202. (i < j):
  203. zone[i]->protection[j]
  204. = (total sums of present_pages from zone[i+1] to zone[j] on the node)
  205. / lowmem_reserve_ratio[i];
  206. (i = j):
  207. (should not be protected. = 0;
  208. (i > j):
  209. (not necessary, but looks 0)
  210. The default values of lowmem_reserve_ratio[i] are
  211. 256 (if zone[i] means DMA or DMA32 zone)
  212. 32 (others).
  213. As above expression, they are reciprocal number of ratio.
  214. 256 means 1/256. # of protection pages becomes about "0.39%" of total present
  215. pages of higher zones on the node.
  216. If you would like to protect more pages, smaller values are effective.
  217. The minimum value is 1 (1/1 -> 100%).
  218. ==============================================================
  219. max_map_count:
  220. This file contains the maximum number of memory map areas a process
  221. may have. Memory map areas are used as a side-effect of calling
  222. malloc, directly by mmap and mprotect, and also when loading shared
  223. libraries.
  224. While most applications need less than a thousand maps, certain
  225. programs, particularly malloc debuggers, may consume lots of them,
  226. e.g., up to one or two maps per allocation.
  227. The default value is 65536.
  228. =============================================================
  229. memory_failure_early_kill:
  230. Control how to kill processes when uncorrected memory error (typically
  231. a 2bit error in a memory module) is detected in the background by hardware
  232. that cannot be handled by the kernel. In some cases (like the page
  233. still having a valid copy on disk) the kernel will handle the failure
  234. transparently without affecting any applications. But if there is
  235. no other uptodate copy of the data it will kill to prevent any data
  236. corruptions from propagating.
  237. 1: Kill all processes that have the corrupted and not reloadable page mapped
  238. as soon as the corruption is detected. Note this is not supported
  239. for a few types of pages, like kernel internally allocated data or
  240. the swap cache, but works for the majority of user pages.
  241. 0: Only unmap the corrupted page from all processes and only kill a process
  242. who tries to access it.
  243. The kill is done using a catchable SIGBUS with BUS_MCEERR_AO, so processes can
  244. handle this if they want to.
  245. This is only active on architectures/platforms with advanced machine
  246. check handling and depends on the hardware capabilities.
  247. Applications can override this setting individually with the PR_MCE_KILL prctl
  248. ==============================================================
  249. memory_failure_recovery
  250. Enable memory failure recovery (when supported by the platform)
  251. 1: Attempt recovery.
  252. 0: Always panic on a memory failure.
  253. ==============================================================
  254. min_free_kbytes:
  255. This is used to force the Linux VM to keep a minimum number
  256. of kilobytes free. The VM uses this number to compute a
  257. watermark[WMARK_MIN] value for each lowmem zone in the system.
  258. Each lowmem zone gets a number of reserved free pages based
  259. proportionally on its size.
  260. Some minimal amount of memory is needed to satisfy PF_MEMALLOC
  261. allocations; if you set this to lower than 1024KB, your system will
  262. become subtly broken, and prone to deadlock under high loads.
  263. Setting this too high will OOM your machine instantly.
  264. =============================================================
  265. min_slab_ratio:
  266. This is available only on NUMA kernels.
  267. A percentage of the total pages in each zone. On Zone reclaim
  268. (fallback from the local zone occurs) slabs will be reclaimed if more
  269. than this percentage of pages in a zone are reclaimable slab pages.
  270. This insures that the slab growth stays under control even in NUMA
  271. systems that rarely perform global reclaim.
  272. The default is 5 percent.
  273. Note that slab reclaim is triggered in a per zone / node fashion.
  274. The process of reclaiming slab memory is currently not node specific
  275. and may not be fast.
  276. =============================================================
  277. min_unmapped_ratio:
  278. This is available only on NUMA kernels.
  279. This is a percentage of the total pages in each zone. Zone reclaim will
  280. only occur if more than this percentage of pages are in a state that
  281. zone_reclaim_mode allows to be reclaimed.
  282. If zone_reclaim_mode has the value 4 OR'd, then the percentage is compared
  283. against all file-backed unmapped pages including swapcache pages and tmpfs
  284. files. Otherwise, only unmapped pages backed by normal files but not tmpfs
  285. files and similar are considered.
  286. The default is 1 percent.
  287. ==============================================================
  288. mmap_min_addr
  289. This file indicates the amount of address space which a user process will
  290. be restricted from mmapping. Since kernel null dereference bugs could
  291. accidentally operate based on the information in the first couple of pages
  292. of memory userspace processes should not be allowed to write to them. By
  293. default this value is set to 0 and no protections will be enforced by the
  294. security module. Setting this value to something like 64k will allow the
  295. vast majority of applications to work correctly and provide defense in depth
  296. against future potential kernel bugs.
  297. ==============================================================
  298. nr_hugepages
  299. Change the minimum size of the hugepage pool.
  300. See Documentation/vm/hugetlbpage.txt
  301. ==============================================================
  302. nr_overcommit_hugepages
  303. Change the maximum size of the hugepage pool. The maximum is
  304. nr_hugepages + nr_overcommit_hugepages.
  305. See Documentation/vm/hugetlbpage.txt
  306. ==============================================================
  307. nr_trim_pages
  308. This is available only on NOMMU kernels.
  309. This value adjusts the excess page trimming behaviour of power-of-2 aligned
  310. NOMMU mmap allocations.
  311. A value of 0 disables trimming of allocations entirely, while a value of 1
  312. trims excess pages aggressively. Any value >= 1 acts as the watermark where
  313. trimming of allocations is initiated.
  314. The default value is 1.
  315. See Documentation/nommu-mmap.txt for more information.
  316. ==============================================================
  317. numa_zonelist_order
  318. This sysctl is only for NUMA.
  319. 'where the memory is allocated from' is controlled by zonelists.
  320. (This documentation ignores ZONE_HIGHMEM/ZONE_DMA32 for simple explanation.
  321. you may be able to read ZONE_DMA as ZONE_DMA32...)
  322. In non-NUMA case, a zonelist for GFP_KERNEL is ordered as following.
  323. ZONE_NORMAL -> ZONE_DMA
  324. This means that a memory allocation request for GFP_KERNEL will
  325. get memory from ZONE_DMA only when ZONE_NORMAL is not available.
  326. In NUMA case, you can think of following 2 types of order.
  327. Assume 2 node NUMA and below is zonelist of Node(0)'s GFP_KERNEL
  328. (A) Node(0) ZONE_NORMAL -> Node(0) ZONE_DMA -> Node(1) ZONE_NORMAL
  329. (B) Node(0) ZONE_NORMAL -> Node(1) ZONE_NORMAL -> Node(0) ZONE_DMA.
  330. Type(A) offers the best locality for processes on Node(0), but ZONE_DMA
  331. will be used before ZONE_NORMAL exhaustion. This increases possibility of
  332. out-of-memory(OOM) of ZONE_DMA because ZONE_DMA is tend to be small.
  333. Type(B) cannot offer the best locality but is more robust against OOM of
  334. the DMA zone.
  335. Type(A) is called as "Node" order. Type (B) is "Zone" order.
  336. "Node order" orders the zonelists by node, then by zone within each node.
  337. Specify "[Nn]ode" for node order
  338. "Zone Order" orders the zonelists by zone type, then by node within each
  339. zone. Specify "[Zz]one" for zone order.
  340. Specify "[Dd]efault" to request automatic configuration. Autoconfiguration
  341. will select "node" order in following case.
  342. (1) if the DMA zone does not exist or
  343. (2) if the DMA zone comprises greater than 50% of the available memory or
  344. (3) if any node's DMA zone comprises greater than 60% of its local memory and
  345. the amount of local memory is big enough.
  346. Otherwise, "zone" order will be selected. Default order is recommended unless
  347. this is causing problems for your system/application.
  348. ==============================================================
  349. oom_dump_tasks
  350. Enables a system-wide task dump (excluding kernel threads) to be
  351. produced when the kernel performs an OOM-killing and includes such
  352. information as pid, uid, tgid, vm size, rss, nr_ptes, swapents,
  353. oom_score_adj score, and name. This is helpful to determine why the
  354. OOM killer was invoked, to identify the rogue task that caused it,
  355. and to determine why the OOM killer chose the task it did to kill.
  356. If this is set to zero, this information is suppressed. On very
  357. large systems with thousands of tasks it may not be feasible to dump
  358. the memory state information for each one. Such systems should not
  359. be forced to incur a performance penalty in OOM conditions when the
  360. information may not be desired.
  361. If this is set to non-zero, this information is shown whenever the
  362. OOM killer actually kills a memory-hogging task.
  363. The default value is 1 (enabled).
  364. ==============================================================
  365. oom_kill_allocating_task
  366. This enables or disables killing the OOM-triggering task in
  367. out-of-memory situations.
  368. If this is set to zero, the OOM killer will scan through the entire
  369. tasklist and select a task based on heuristics to kill. This normally
  370. selects a rogue memory-hogging task that frees up a large amount of
  371. memory when killed.
  372. If this is set to non-zero, the OOM killer simply kills the task that
  373. triggered the out-of-memory condition. This avoids the expensive
  374. tasklist scan.
  375. If panic_on_oom is selected, it takes precedence over whatever value
  376. is used in oom_kill_allocating_task.
  377. The default value is 0.
  378. ==============================================================
  379. overcommit_memory:
  380. This value contains a flag that enables memory overcommitment.
  381. When this flag is 0, the kernel attempts to estimate the amount
  382. of free memory left when userspace requests more memory.
  383. When this flag is 1, the kernel pretends there is always enough
  384. memory until it actually runs out.
  385. When this flag is 2, the kernel uses a "never overcommit"
  386. policy that attempts to prevent any overcommit of memory.
  387. This feature can be very useful because there are a lot of
  388. programs that malloc() huge amounts of memory "just-in-case"
  389. and don't use much of it.
  390. The default value is 0.
  391. See Documentation/vm/overcommit-accounting and
  392. security/commoncap.c::cap_vm_enough_memory() for more information.
  393. ==============================================================
  394. overcommit_ratio:
  395. When overcommit_memory is set to 2, the committed address
  396. space is not permitted to exceed swap plus this percentage
  397. of physical RAM. See above.
  398. ==============================================================
  399. page-cluster
  400. page-cluster controls the number of pages up to which consecutive pages
  401. are read in from swap in a single attempt. This is the swap counterpart
  402. to page cache readahead.
  403. The mentioned consecutivity is not in terms of virtual/physical addresses,
  404. but consecutive on swap space - that means they were swapped out together.
  405. It is a logarithmic value - setting it to zero means "1 page", setting
  406. it to 1 means "2 pages", setting it to 2 means "4 pages", etc.
  407. Zero disables swap readahead completely.
  408. The default value is three (eight pages at a time). There may be some
  409. small benefits in tuning this to a different value if your workload is
  410. swap-intensive.
  411. Lower values mean lower latencies for initial faults, but at the same time
  412. extra faults and I/O delays for following faults if they would have been part of
  413. that consecutive pages readahead would have brought in.
  414. =============================================================
  415. panic_on_oom
  416. This enables or disables panic on out-of-memory feature.
  417. If this is set to 0, the kernel will kill some rogue process,
  418. called oom_killer. Usually, oom_killer can kill rogue processes and
  419. system will survive.
  420. If this is set to 1, the kernel panics when out-of-memory happens.
  421. However, if a process limits using nodes by mempolicy/cpusets,
  422. and those nodes become memory exhaustion status, one process
  423. may be killed by oom-killer. No panic occurs in this case.
  424. Because other nodes' memory may be free. This means system total status
  425. may be not fatal yet.
  426. If this is set to 2, the kernel panics compulsorily even on the
  427. above-mentioned. Even oom happens under memory cgroup, the whole
  428. system panics.
  429. The default value is 0.
  430. 1 and 2 are for failover of clustering. Please select either
  431. according to your policy of failover.
  432. panic_on_oom=2+kdump gives you very strong tool to investigate
  433. why oom happens. You can get snapshot.
  434. =============================================================
  435. percpu_pagelist_fraction
  436. This is the fraction of pages at most (high mark pcp->high) in each zone that
  437. are allocated for each per cpu page list. The min value for this is 8. It
  438. means that we don't allow more than 1/8th of pages in each zone to be
  439. allocated in any single per_cpu_pagelist. This entry only changes the value
  440. of hot per cpu pagelists. User can specify a number like 100 to allocate
  441. 1/100th of each zone to each per cpu page list.
  442. The batch value of each per cpu pagelist is also updated as a result. It is
  443. set to pcp->high/4. The upper limit of batch is (PAGE_SHIFT * 8)
  444. The initial value is zero. Kernel does not use this value at boot time to set
  445. the high water marks for each per cpu page list.
  446. ==============================================================
  447. stat_interval
  448. The time interval between which vm statistics are updated. The default
  449. is 1 second.
  450. ==============================================================
  451. swappiness
  452. This control is used to define how aggressive the kernel will swap
  453. memory pages. Higher values will increase agressiveness, lower values
  454. decrease the amount of swap.
  455. The default value is 60.
  456. ==============================================================
  457. vfs_cache_pressure
  458. ------------------
  459. Controls the tendency of the kernel to reclaim the memory which is used for
  460. caching of directory and inode objects.
  461. At the default value of vfs_cache_pressure=100 the kernel will attempt to
  462. reclaim dentries and inodes at a "fair" rate with respect to pagecache and
  463. swapcache reclaim. Decreasing vfs_cache_pressure causes the kernel to prefer
  464. to retain dentry and inode caches. When vfs_cache_pressure=0, the kernel will
  465. never reclaim dentries and inodes due to memory pressure and this can easily
  466. lead to out-of-memory conditions. Increasing vfs_cache_pressure beyond 100
  467. causes the kernel to prefer to reclaim dentries and inodes.
  468. ==============================================================
  469. zone_reclaim_mode:
  470. Zone_reclaim_mode allows someone to set more or less aggressive approaches to
  471. reclaim memory when a zone runs out of memory. If it is set to zero then no
  472. zone reclaim occurs. Allocations will be satisfied from other zones / nodes
  473. in the system.
  474. This is value ORed together of
  475. 1 = Zone reclaim on
  476. 2 = Zone reclaim writes dirty pages out
  477. 4 = Zone reclaim swaps pages
  478. zone_reclaim_mode is set during bootup to 1 if it is determined that pages
  479. from remote zones will cause a measurable performance reduction. The
  480. page allocator will then reclaim easily reusable pages (those page
  481. cache pages that are currently not used) before allocating off node pages.
  482. It may be beneficial to switch off zone reclaim if the system is
  483. used for a file server and all of memory should be used for caching files
  484. from disk. In that case the caching effect is more important than
  485. data locality.
  486. Allowing zone reclaim to write out pages stops processes that are
  487. writing large amounts of data from dirtying pages on other nodes. Zone
  488. reclaim will write out dirty pages if a zone fills up and so effectively
  489. throttle the process. This may decrease the performance of a single process
  490. since it cannot use all of system memory to buffer the outgoing writes
  491. anymore but it preserve the memory on other nodes so that the performance
  492. of other processes running on other nodes will not be affected.
  493. Allowing regular swap effectively restricts allocations to the local
  494. node unless explicitly overridden by memory policies or cpuset
  495. configurations.
  496. ============ End of Document =================================