€•Œsphinx.addnodes”Œdocument”“”)�”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)�”}”(hhh]”(hŒ pending_xref”“”)�”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…”�”}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ1/translations/zh_CN/admin-guide/mm/memory-hotplug”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)�”}”(hhh]”hŒChinese (Traditional)”…”�”}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/zh_TW/admin-guide/mm/memory-hotplug”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒItalian”…”�”}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/it_IT/admin-guide/mm/memory-hotplug”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒJapanese”…”�”}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/ja_JP/admin-guide/mm/memory-hotplug”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒKorean”…”�”}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/ko_KR/admin-guide/mm/memory-hotplug”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒPortuguese (Brazilian)”…”�”}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/pt_BR/admin-guide/mm/memory-hotplug”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒSpanish”…”�”}”hh–sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/sp_SP/admin-guide/mm/memory-hotplug”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒsection”“”)�”}”(hhh]”(hŒtitle”“”)�”}”(hŒMemory Hot(Un)Plug”h]”hŒMemory Hot(Un)Plug”…”�”}”(hh¼h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhh·h²hh³ŒK/var/lib/git/docbuild/linux/Documentation/admin-guide/mm/memory-hotplug.rst”h´KubhŒ paragraph”“”)�”}”(hŒ€This document describes generic Linux support for memory hot(un)plug with a focus on System RAM, including ZONE_MOVABLE support.”h]”hŒ€This document describes generic Linux support for memory hot(un)plug with a focus on System RAM, including ZONE_MOVABLE support.”…”�”}”(hhÍh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khh·h²hubhŒtopic”“”)�”}”(hhh]”hŒ bullet_list”“”)�”}”(hhh]”(hŒ list_item”“”)�”}”(hhh]”(hÌ)�”}”(hhh]”hŒ reference”“”)�”}”(hhh]”hŒ Introduction”…”�”}”(hhïh²hh³Nh´Nubah}”(h]”Œid1”ah ]”h"]”h$]”h&]”Œrefid”Œ introduction”uh1híhhêubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhhçubhá)�”}”(hhh]”(hæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒMemory Hot(Un)Plug Granularity”…”�”}”(hjh²hh³Nh´Nubah}”(h]”Œid2”ah ]”h"]”h$]”h&]”Œrefid”Œmemory-hot-un-plug-granularity”uh1híhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒPhases of Memory Hotplug”…”�”}”(hj0h²hh³Nh´Nubah}”(h]”Œid3”ah ]”h"]”h$]”h&]”Œrefid”Œphases-of-memory-hotplug”uh1híhj-ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhj*ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒPhases of Memory Hotunplug”…”�”}”(hjRh²hh³Nh´Nubah}”(h]”Œid4”ah ]”h"]”h$]”h&]”Œrefid”Œphases-of-memory-hotunplug”uh1híhjOubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjLubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjubeh}”(h]”h ]”h"]”h$]”h&]”uh1hàhhçubeh}”(h]”h ]”h"]”h$]”h&]”uh1håhhâubhæ)�”}”(hhh]”(hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒMemory Hotplug Notifications”…”�”}”(hj€h²hh³Nh´Nubah}”(h]”Œid5”ah ]”h"]”h$]”h&]”Œrefid”Œmemory-hotplug-notifications”uh1híhj}ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjzubhá)�”}”(hhh]”(hæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒACPI Notifications”…”�”}”(hjŸh²hh³Nh´Nubah}”(h]”Œid6”ah ]”h"]”h$]”h&]”Œrefid”Œacpi-notifications”uh1híhjœubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhj™ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj–ubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒManual Probing”…”�”}”(hjÁh²hh³Nh´Nubah}”(h]”Œid7”ah ]”h"]”h$]”h&]”Œrefid”Œmanual-probing”uh1híhj¾ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhj»ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj–ubeh}”(h]”h ]”h"]”h$]”h&]”uh1hàhjzubeh}”(h]”h ]”h"]”h$]”h&]”uh1håhhâubhæ)�”}”(hhh]”(hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒ$Onlining and Offlining Memory Blocks”…”�”}”(hjïh²hh³Nh´Nubah}”(h]”Œid8”ah ]”h"]”h$]”h&]”Œrefid”Œ$onlining-and-offlining-memory-blocks”uh1híhjìubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjéubhá)�”}”(hhh]”(hæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒOnlining Memory Blocks Manually”…”�”}”(hjh²hh³Nh´Nubah}”(h]”Œid9”ah ]”h"]”h$]”h&]”Œrefid”Œonlining-memory-blocks-manually”uh1híhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒ$Onlining Memory Blocks Automatically”…”�”}”(hj0h²hh³Nh´Nubah}”(h]”Œid10”ah ]”h"]”h$]”h&]”Œrefid”Œ$onlining-memory-blocks-automatically”uh1híhj-ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhj*ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒOfflining Memory Blocks”…”�”}”(hjRh²hh³Nh´Nubah}”(h]”Œid11”ah ]”h"]”h$]”h&]”Œrefid”Œofflining-memory-blocks”uh1híhjOubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjLubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒ$Observing the State of Memory Blocks”…”�”}”(hjth²hh³Nh´Nubah}”(h]”Œid12”ah ]”h"]”h$]”h&]”Œrefid”Œ$observing-the-state-of-memory-blocks”uh1híhjqubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjnubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjubeh}”(h]”h ]”h"]”h$]”h&]”uh1hàhjéubeh}”(h]”h ]”h"]”h$]”h&]”uh1håhhâubhæ)�”}”(hhh]”(hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒConfiguring Memory Hot(Un)Plug”…”�”}”(hj¢h²hh³Nh´Nubah}”(h]”Œid13”ah ]”h"]”h$]”h&]”Œrefid”Œconfiguring-memory-hot-un-plug”uh1híhjŸubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjœubhá)�”}”(hhh]”(hæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒ*Memory Hot(Un)Plug Configuration via Sysfs”…”�”}”(hjÁh²hh³Nh´Nubah}”(h]”Œid14”ah ]”h"]”h$]”h&]”Œrefid”Œ*memory-hot-un-plug-configuration-via-sysfs”uh1híhj¾ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhj»ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj¸ubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒ$Memory Block Configuration via Sysfs”…”�”}”(hjãh²hh³Nh´Nubah}”(h]”Œid15”ah ]”h"]”h$]”h&]”Œrefid”Œ$memory-block-configuration-via-sysfs”uh1híhjàubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjÝubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj¸ubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒCommand Line Parameters”…”�”}”(hjh²hh³Nh´Nubah}”(h]”Œid16”ah ]”h"]”h$]”h&]”Œrefid”Œcommand-line-parameters”uh1híhjubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjÿubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj¸ubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒModule Parameters”…”�”}”(hj'h²hh³Nh´Nubah}”(h]”Œid17”ah ]”h"]”h$]”h&]”Œrefid”Œmodule-parameters”uh1híhj$ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhj!ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj¸ubeh}”(h]”h ]”h"]”h$]”h&]”uh1hàhjœubeh}”(h]”h ]”h"]”h$]”h&]”uh1håhhâubhæ)�”}”(hhh]”(hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒ ZONE_MOVABLE”…”�”}”(hjUh²hh³Nh´Nubah}”(h]”Œid18”ah ]”h"]”h$]”h&]”Œrefid”Œ zone-movable”uh1híhjRubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjOubhá)�”}”(hhh]”(hæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒZone Imbalances”…”�”}”(hjth²hh³Nh´Nubah}”(h]”Œid19”ah ]”h"]”h$]”h&]”Œrefid”Œzone-imbalances”uh1híhjqubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhjnubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjkubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒ"ZONE_MOVABLE Sizing Considerations”…”�”}”(hj–h²hh³Nh´Nubah}”(h]”Œid20”ah ]”h"]”h$]”h&]”Œrefid”Œ"zone-movable-sizing-considerations”uh1híhj“ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhj�ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjkubhæ)�”}”(hhh]”hÌ)�”}”(hhh]”hî)�”}”(hhh]”hŒ!Memory Offlining and ZONE_MOVABLE”…”�”}”(hj¸h²hh³Nh´Nubah}”(h]”Œid21”ah ]”h"]”h$]”h&]”Œrefid”Œ!memory-offlining-and-zone-movable”uh1híhjµubah}”(h]”h ]”h"]”h$]”h&]”uh1hËhj²ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjkubeh}”(h]”h ]”h"]”h$]”h&]”uh1hàhjOubeh}”(h]”h ]”h"]”h$]”h&]”uh1håhhâubeh}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³Nh´Nubah}”(h]”Œcontents”ah ]”(Œcontents”Œlocal”eh"]”Œcontents”ah$]”h&]”uh1hÛh³hÊh´Khh·h²hubh¶)�”}”(hhh]”(h»)�”}”(hŒ Introduction”h]”hŒ Introduction”…”�”}”(hjóh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefid”høuh1hºhjðh²hh³hÊh´K ubhÌ)�”}”(hŒ÷Memory hot(un)plug allows for increasing and decreasing the size of physical memory available to a machine at runtime. In the simplest case, it consists of physically plugging or unplugging a DIMM at runtime, coordinated with the operating system.”h]”hŒ÷Memory hot(un)plug allows for increasing and decreasing the size of physical memory available to a machine at runtime. In the simplest case, it consists of physically plugging or unplugging a DIMM at runtime, coordinated with the operating system.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K hjðh²hubhÌ)�”}”(hŒ0Memory hot(un)plug is used for various purposes:”h]”hŒ0Memory hot(un)plug is used for various purposes:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khjðh²hubhá)�”}”(hhh]”(hæ)�”}”(hŒýThe physical memory available to a machine can be adjusted at runtime, up- or downgrading the memory capacity. This dynamic memory resizing, sometimes referred to as "capacity on demand", is frequently used with virtual machines and logical partitions. ”h]”hÌ)�”}”(hŒüThe physical memory available to a machine can be adjusted at runtime, up- or downgrading the memory capacity. This dynamic memory resizing, sometimes referred to as "capacity on demand", is frequently used with virtual machines and logical partitions.”h]”hXThe physical memory available to a machine can be adjusted at runtime, up- or downgrading the memory capacity. This dynamic memory resizing, sometimes referred to as “capacity on demandâ€�, is frequently used with virtual machines and logical partitions.”…”�”}”(hj%h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khj!ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjh²hh³hÊh´Nubhæ)�”}”(hŒzReplacing hardware, such as DIMMs or whole NUMA nodes, without downtime. One example is replacing failing memory modules. ”h]”hÌ)�”}”(hŒyReplacing hardware, such as DIMMs or whole NUMA nodes, without downtime. One example is replacing failing memory modules.”h]”hŒyReplacing hardware, such as DIMMs or whole NUMA nodes, without downtime. One example is replacing failing memory modules.”…”�”}”(hj=h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khj9ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjh²hh³hÊh´Nubhæ)�”}”(hŒŒReducing energy consumption either by physically unplugging memory modules or by logically unplugging (parts of) memory modules from Linux. ”h]”hÌ)�”}”(hŒ‹Reducing energy consumption either by physically unplugging memory modules or by logically unplugging (parts of) memory modules from Linux.”h]”hŒ‹Reducing energy consumption either by physically unplugging memory modules or by logically unplugging (parts of) memory modules from Linux.”…”�”}”(hjUh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KhjQubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjh²hh³hÊh´Nubeh}”(h]”h ]”h"]”h$]”h&]”Œbullet”Œ-”uh1hàh³hÊh´Khjðh²hubhÌ)�”}”(hŒÕFurther, the basic memory hot(un)plug infrastructure in Linux is nowadays also used to expose persistent memory, other performance-differentiated memory and reserved memory regions as ordinary system RAM to Linux.”h]”hŒÕFurther, the basic memory hot(un)plug infrastructure in Linux is nowadays also used to expose persistent memory, other performance-differentiated memory and reserved memory regions as ordinary system RAM to Linux.”…”�”}”(hjqh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khjðh²hubhÌ)�”}”(hŒpLinux only supports memory hot(un)plug on selected 64 bit architectures, such as x86_64, arm64, ppc64 and s390x.”h]”hŒpLinux only supports memory hot(un)plug on selected 64 bit architectures, such as x86_64, arm64, ppc64 and s390x.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K#hjðh²hubh¶)�”}”(hhh]”(h»)�”}”(hŒMemory Hot(Un)Plug Granularity”h]”hŒMemory Hot(Un)Plug Granularity”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jjuh1hºhj�h²hh³hÊh´K'ubhÌ)�”}”(hX Memory hot(un)plug in Linux uses the SPARSEMEM memory model, which divides the physical memory address space into chunks of the same size: memory sections. The size of a memory section is architecture dependent. For example, x86_64 uses 128 MiB and ppc64 uses 16 MiB.”h]”hX Memory hot(un)plug in Linux uses the SPARSEMEM memory model, which divides the physical memory address space into chunks of the same size: memory sections. The size of a memory section is architecture dependent. For example, x86_64 uses 128 MiB and ppc64 uses 16 MiB.”…”�”}”(hjžh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K)hj�h²hubhÌ)�”}”(hX8Memory sections are combined into chunks referred to as "memory blocks". The size of a memory block is architecture dependent and corresponds to the smallest granularity that can be hot(un)plugged. The default size of a memory block is the same as memory section size, unless an architecture specifies otherwise.”h]”hX<Memory sections are combined into chunks referred to as “memory blocksâ€�. The size of a memory block is architecture dependent and corresponds to the smallest granularity that can be hot(un)plugged. The default size of a memory block is the same as memory section size, unless an architecture specifies otherwise.”…”�”}”(hj¬h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K.hj�h²hubhÌ)�”}”(hŒ%All memory blocks have the same size.”h]”hŒ%All memory blocks have the same size.”…”�”}”(hjºh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K3hj�h²hubeh}”(h]”jah ]”h"]”Œmemory hot(un)plug granularity”ah$]”h&]”uh1hµhjðh²hh³hÊh´K'ubh¶)�”}”(hhh]”(h»)�”}”(hŒPhases of Memory Hotplug”h]”hŒPhases of Memory Hotplug”…”�”}”(hjÒh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj9uh1hºhjÏh²hh³hÊh´K6ubhÌ)�”}”(hŒ&Memory hotplug consists of two phases:”h]”hŒ&Memory hotplug consists of two phases:”…”�”}”(hjàh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K8hjÏh²hubhŒenumerated_list”“”)�”}”(hhh]”(hæ)�”}”(hŒAdding the memory to Linux”h]”hÌ)�”}”(hjõh]”hŒAdding the memory to Linux”…”�”}”(hj÷h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K:hjóubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjðh²hh³hÊh´Nubhæ)�”}”(hŒOnlining memory blocks ”h]”hÌ)�”}”(hŒOnlining memory blocks”h]”hŒOnlining memory blocks”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K;hj ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjðh²hh³hÊh´Nubeh}”(h]”h ]”h"]”h$]”h&]”Œenumtype”Œarabic”Œprefix”Œ(”Œsuffix”Œ)”uh1jîhjÏh²hh³hÊh´K:ubhÌ)�”}”(hŒòIn the first phase, metadata, such as the memory map ("memmap") and page tables for the direct mapping, is allocated and initialized, and memory blocks are created; the latter also creates sysfs files for managing newly created memory blocks.”h]”hŒöIn the first phase, metadata, such as the memory map (“memmapâ€�) and page tables for the direct mapping, is allocated and initialized, and memory blocks are created; the latter also creates sysfs files for managing newly created memory blocks.”…”�”}”(hj.h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K=hjÏh²hubhÌ)�”}”(hŒ¯In the second phase, added memory is exposed to the page allocator. After this phase, the memory is visible in memory statistics, such as free and total memory, of the system.”h]”hŒ¯In the second phase, added memory is exposed to the page allocator. After this phase, the memory is visible in memory statistics, such as free and total memory, of the system.”…”�”}”(hj<h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KBhjÏh²hubeh}”(h]”j?ah ]”h"]”Œphases of memory hotplug”ah$]”h&]”uh1hµhjðh²hh³hÊh´K6ubh¶)�”}”(hhh]”(h»)�”}”(hŒPhases of Memory Hotunplug”h]”hŒPhases of Memory Hotunplug”…”�”}”(hjTh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj[uh1hºhjQh²hh³hÊh´KGubhÌ)�”}”(hŒ(Memory hotunplug consists of two phases:”h]”hŒ(Memory hotunplug consists of two phases:”…”�”}”(hjbh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KIhjQh²hubjï)�”}”(hhh]”(hæ)�”}”(hŒOfflining memory blocks”h]”hÌ)�”}”(hjuh]”hŒOfflining memory blocks”…”�”}”(hjwh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KKhjsubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjph²hh³hÊh´Nubhæ)�”}”(hŒRemoving the memory from Linux ”h]”hÌ)�”}”(hŒRemoving the memory from Linux”h]”hŒRemoving the memory from Linux”…”�”}”(hjŽh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KLhjŠubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjph²hh³hÊh´Nubeh}”(h]”h ]”h"]”h$]”h&]”j(j)j*j+j,j-uh1jîhjQh²hh³hÊh´KKubhÌ)�”}”(hXIn the first phase, memory is "hidden" from the page allocator again, for example, by migrating busy memory to other memory locations and removing all relevant free pages from the page allocator After this phase, the memory is no longer visible in memory statistics of the system.”h]”hXIn the first phase, memory is “hiddenâ€� from the page allocator again, for example, by migrating busy memory to other memory locations and removing all relevant free pages from the page allocator After this phase, the memory is no longer visible in memory statistics of the system.”…”�”}”(hj¨h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KNhjQh²hubhÌ)�”}”(hŒIIn the second phase, the memory blocks are removed and metadata is freed.”h]”hŒIIn the second phase, the memory blocks are removed and metadata is freed.”…”�”}”(hj¶h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KShjQh²hubeh}”(h]”jaah ]”h"]”Œphases of memory hotunplug”ah$]”h&]”uh1hµhjðh²hh³hÊh´KGubeh}”(h]”hþah ]”h"]”Œ introduction”ah$]”h&]”uh1hµhh·h²hh³hÊh´K ubh¶)�”}”(hhh]”(h»)�”}”(hŒMemory Hotplug Notifications”h]”hŒMemory Hotplug Notifications”…”�”}”(hjÕh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj‰uh1hºhjÒh²hh³hÊh´KVubhÌ)�”}”(hX There are various ways how Linux is notified about memory hotplug events such that it can start adding hotplugged memory. This description is limited to systems that support ACPI; mechanisms specific to other firmware interfaces or virtual machines are not described.”h]”hX There are various ways how Linux is notified about memory hotplug events such that it can start adding hotplugged memory. This description is limited to systems that support ACPI; mechanisms specific to other firmware interfaces or virtual machines are not described.”…”�”}”(hjãh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KXhjÒh²hubh¶)�”}”(hhh]”(h»)�”}”(hŒACPI Notifications”h]”hŒACPI Notifications”…”�”}”(hjôh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj¨uh1hºhjñh²hh³hÊh´K^ubhÌ)�”}”(hŒ_Platforms that support ACPI, such as x86_64, can support memory hotplug notifications via ACPI.”h]”hŒ_Platforms that support ACPI, such as x86_64, can support memory hotplug notifications via ACPI.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K`hjñh²hubhÌ)�”}”(hŒÃIn general, a firmware supporting memory hotplug defines a memory class object HID "PNP0C80". When notified about hotplug of a new memory device, the ACPI driver will hotplug the memory to Linux.”h]”hŒÇIn general, a firmware supporting memory hotplug defines a memory class object HID “PNP0C80â€�. When notified about hotplug of a new memory device, the ACPI driver will hotplug the memory to Linux.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kchjñh²hubhÌ)�”}”(hŒ×If the firmware supports hotplug of NUMA nodes, it defines an object _HID "ACPI0004", "PNP0A05", or "PNP0A06". When notified about an hotplug event, all assigned memory devices are added to Linux by the ACPI driver.”h]”hŒãIf the firmware supports hotplug of NUMA nodes, it defines an object _HID “ACPI0004â€�, “PNP0A05â€�, or “PNP0A06â€�. When notified about an hotplug event, all assigned memory devices are added to Linux by the ACPI driver.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kghjñh²hubhÌ)�”}”(hŒÙSimilarly, Linux can be notified about requests to hotunplug a memory device or a NUMA node via ACPI. The ACPI driver will try offlining all relevant memory blocks, and, if successful, hotunplug the memory from Linux.”h]”hŒÙSimilarly, Linux can be notified about requests to hotunplug a memory device or a NUMA node via ACPI. The ACPI driver will try offlining all relevant memory blocks, and, if successful, hotunplug the memory from Linux.”…”�”}”(hj,h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kkhjñh²hubeh}”(h]”j®ah ]”h"]”Œacpi notifications”ah$]”h&]”uh1hµhjÒh²hh³hÊh´K^ubh¶)�”}”(hhh]”(h»)�”}”(hŒManual Probing”h]”hŒManual Probing”…”�”}”(hjDh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jjÊuh1hºhjAh²hh³hÊh´KpubhÌ)�”}”(hŒ¯On some architectures, the firmware may not be able to notify the operating system about a memory hotplug event. Instead, the memory has to be manually probed from user space.”h]”hŒ¯On some architectures, the firmware may not be able to notify the operating system about a memory hotplug event. Instead, the memory has to be manually probed from user space.”…”�”}”(hjRh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KrhjAh²hubhÌ)�”}”(hŒ#The probe interface is located at::”h]”hŒ"The probe interface is located at:”…”�”}”(hj`h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KvhjAh²hubhŒ literal_block”“”)�”}”(hŒ /sys/devices/system/memory/probe”h]”hŒ /sys/devices/system/memory/probe”…”�”}”hjpsbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1jnh³hÊh´KxhjAh²hubhÌ)�”}”(hŒŒOnly complete memory blocks can be probed. Individual memory blocks are probed by providing the physical start address of the memory block::”h]”hŒ‹Only complete memory blocks can be probed. Individual memory blocks are probed by providing the physical start address of the memory block:”…”�”}”(hj€h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KzhjAh²hubjo)�”}”(hŒ.% echo addr > /sys/devices/system/memory/probe”h]”hŒ.% echo addr > /sys/devices/system/memory/probe”…”�”}”hjŽsbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´K}hjAh²hubhÌ)�”}”(hŒ]Which results in a memory block for the range [addr, addr + memory_block_size) being created.”h]”hŒ]Which results in a memory block for the range [addr, addr + memory_block_size) being created.”…”�”}”(hjœh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KhjAh²hubhŒnote”“”)�”}”(hŒ¤Using the probe interface is discouraged as it is easy to crash the kernel, because Linux cannot validate user input; this interface might be removed in the future.”h]”hÌ)�”}”(hŒ¤Using the probe interface is discouraged as it is easy to crash the kernel, because Linux cannot validate user input; this interface might be removed in the future.”h]”hŒ¤Using the probe interface is discouraged as it is easy to crash the kernel, because Linux cannot validate user input; this interface might be removed in the future.”…”�”}”(hj°h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K„hj¬ubah}”(h]”h ]”h"]”h$]”h&]”uh1jªhjAh²hh³hÊh´Nubeh}”(h]”jÐah ]”h"]”Œmanual probing”ah$]”h&]”uh1hµhjÒh²hh³hÊh´Kpubeh}”(h]”j�ah ]”h"]”Œmemory hotplug notifications”ah$]”h&]”uh1hµhh·h²hh³hÊh´KVubh¶)�”}”(hhh]”(h»)�”}”(hŒ$Onlining and Offlining Memory Blocks”h]”hŒ$Onlining and Offlining Memory Blocks”…”�”}”(hjÕh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jjøuh1hºhjÒh²hh³hÊh´K‰ubhÌ)�”}”(hŒ‹After a memory block has been created, Linux has to be instructed to actually make use of that memory: the memory block has to be "online".”h]”hŒ�After a memory block has been created, Linux has to be instructed to actually make use of that memory: the memory block has to be “onlineâ€�.”…”�”}”(hjãh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K‹hjÒh²hubhÌ)�”}”(hŒ‰Before a memory block can be removed, Linux has to stop using any memory part of the memory block: the memory block has to be "offlined".”h]”hŒ�Before a memory block can be removed, Linux has to stop using any memory part of the memory block: the memory block has to be “offlinedâ€�.”…”�”}”(hjñh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KŽhjÒh²hubhÌ)�”}”(hX?The Linux kernel can be configured to automatically online added memory blocks and drivers automatically trigger offlining of memory blocks when trying hotunplug of memory. Memory blocks can only be removed once offlining succeeded and drivers may trigger offlining of memory blocks when attempting hotunplug of memory.”h]”hX?The Linux kernel can be configured to automatically online added memory blocks and drivers automatically trigger offlining of memory blocks when trying hotunplug of memory. Memory blocks can only be removed once offlining succeeded and drivers may trigger offlining of memory blocks when attempting hotunplug of memory.”…”�”}”(hjÿh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K‘hjÒh²hubh¶)�”}”(hhh]”(h»)�”}”(hŒOnlining Memory Blocks Manually”h]”hŒOnlining Memory Blocks Manually”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jjuh1hºhj h²hh³hÊh´K˜ubhÌ)�”}”(hŒ®If auto-onlining of memory blocks isn't enabled, user-space has to manually trigger onlining of memory blocks. Often, udev rules are used to automate this task in user space.”h]”hŒ°If auto-onlining of memory blocks isn’t enabled, user-space has to manually trigger onlining of memory blocks. Often, udev rules are used to automate this task in user space.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kšhj h²hubhÌ)�”}”(hŒ1Onlining of a memory block can be triggered via::”h]”hŒ0Onlining of a memory block can be triggered via:”…”�”}”(hj,h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kžhj h²hubjo)�”}”(hŒ:% echo online > /sys/devices/system/memory/memoryXXX/state”h]”hŒ:% echo online > /sys/devices/system/memory/memoryXXX/state”…”�”}”hj:sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´K hj h²hubhÌ)�”}”(hŒOr alternatively::”h]”hŒOr alternatively:”…”�”}”(hjHh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K¢hj h²hubjo)�”}”(hŒ6% echo 1 > /sys/devices/system/memory/memoryXXX/online”h]”hŒ6% echo 1 > /sys/devices/system/memory/memoryXXX/online”…”�”}”hjVsbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´K¤hj h²hubhÌ)�”}”(hŒdThe kernel will select the target zone automatically, depending on the configured ``online_policy``.”h]”(hŒRThe kernel will select the target zone automatically, depending on the configured ”…”�”}”(hjdh²hh³Nh´NubhŒliteral”“”)�”}”(hŒ``online_policy``”h]”hŒ online_policy”…”�”}”(hjnh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjdubhŒ.”…”�”}”(hjdh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K¦hj h²hubhÌ)�”}”(hŒVOne can explicitly request to associate an offline memory block with ZONE_MOVABLE by::”h]”hŒUOne can explicitly request to associate an offline memory block with ZONE_MOVABLE by:”…”�”}”(hj†h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K©hj h²hubjo)�”}”(hŒB% echo online_movable > /sys/devices/system/memory/memoryXXX/state”h]”hŒB% echo online_movable > /sys/devices/system/memory/memoryXXX/state”…”�”}”hj”sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´K¬hj h²hubhÌ)�”}”(hŒFOr one can explicitly request a kernel zone (usually ZONE_NORMAL) by::”h]”hŒEOr one can explicitly request a kernel zone (usually ZONE_NORMAL) by:”…”�”}”(hj¢h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K®hj h²hubjo)�”}”(hŒA% echo online_kernel > /sys/devices/system/memory/memoryXXX/state”h]”hŒA% echo online_kernel > /sys/devices/system/memory/memoryXXX/state”…”�”}”hj°sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´K°hj h²hubhÌ)�”}”(hŒ¾In any case, if onlining succeeds, the state of the memory block is changed to be "online". If it fails, the state of the memory block will remain unchanged and the above commands will fail.”h]”hŒÂIn any case, if onlining succeeds, the state of the memory block is changed to be “onlineâ€�. If it fails, the state of the memory block will remain unchanged and the above commands will fail.”…”�”}”(hj¾h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K²hj h²hubeh}”(h]”jah ]”h"]”Œonlining memory blocks manually”ah$]”h&]”uh1hµhjÒh²hh³hÊh´K˜ubh¶)�”}”(hhh]”(h»)�”}”(hŒ$Onlining Memory Blocks Automatically”h]”hŒ$Onlining Memory Blocks Automatically”…”�”}”(hjÖh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj9uh1hºhjÓh²hh³hÊh´K·ubhÌ)�”}”(hŒºThe kernel can be configured to try auto-onlining of newly added memory blocks. If this feature is disabled, the memory blocks will stay offline until explicitly onlined from user space.”h]”hŒºThe kernel can be configured to try auto-onlining of newly added memory blocks. If this feature is disabled, the memory blocks will stay offline until explicitly onlined from user space.”…”�”}”(hjäh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K¹hjÓh²hubhÌ)�”}”(hŒ9The configured auto-online behavior can be observed via::”h]”hŒ8The configured auto-online behavior can be observed via:”…”�”}”(hjòh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K½hjÓh²hubjo)�”}”(hŒ3% cat /sys/devices/system/memory/auto_online_blocks”h]”hŒ3% cat /sys/devices/system/memory/auto_online_blocks”…”�”}”hjsbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´K¿hjÓh²hubhÌ)�”}”(hŒpAuto-onlining can be enabled by writing ``online``, ``online_kernel`` or ``online_movable`` to that file, like::”h]”(hŒ(Auto-onlining can be enabled by writing ”…”�”}”(hjh²hh³Nh´Nubjm)�”}”(hŒ ``online``”h]”hŒonline”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjubhŒ, ”…”�”}”(hjh²hh³Nh´Nubjm)�”}”(hŒ``online_kernel``”h]”hŒ online_kernel”…”�”}”(hj(h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjubhŒ or ”…”�”}”(hjh²hh³Nh´Nubjm)�”}”(hŒ``online_movable``”h]”hŒonline_movable”…”�”}”(hj:h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjubhŒ to that file, like:”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KÁhjÓh²hubjo)�”}”(hŒ=% echo online > /sys/devices/system/memory/auto_online_blocks”h]”hŒ=% echo online > /sys/devices/system/memory/auto_online_blocks”…”�”}”hjRsbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´KÄhjÓh²hubhÌ)�”}”(hŒ’Similarly to manual onlining, with ``online`` the kernel will select the target zone automatically, depending on the configured ``online_policy``.”h]”(hŒ#Similarly to manual onlining, with ”…”�”}”(hj`h²hh³Nh´Nubjm)�”}”(hŒ ``online``”h]”hŒonline”…”�”}”(hjhh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj`ubhŒS the kernel will select the target zone automatically, depending on the configured ”…”�”}”(hj`h²hh³Nh´Nubjm)�”}”(hŒ``online_policy``”h]”hŒ online_policy”…”�”}”(hjzh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj`ubhŒ.”…”�”}”(hj`h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KÆhjÓh²hubhÌ)�”}”(hŒ^Modifying the auto-online behavior will only affect all subsequently added memory blocks only.”h]”hŒ^Modifying the auto-online behavior will only affect all subsequently added memory blocks only.”…”�”}”(hj’h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KÉhjÓh²hubj«)�”}”(hŒ‹In corner cases, auto-onlining can fail. The kernel won't retry. Note that auto-onlining is not expected to fail in default configurations.”h]”hÌ)�”}”(hŒ‹In corner cases, auto-onlining can fail. The kernel won't retry. Note that auto-onlining is not expected to fail in default configurations.”h]”hŒ�In corner cases, auto-onlining can fail. The kernel won’t retry. Note that auto-onlining is not expected to fail in default configurations.”…”�”}”(hj¤h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KÎhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1jªhjÓh²hh³hÊh´Nubj«)�”}”(hŒ�DLPAR on ppc64 ignores the ``offline`` setting and will still online added memory blocks; if onlining fails, memory blocks are removed again.”h]”hÌ)�”}”(hŒ�DLPAR on ppc64 ignores the ``offline`` setting and will still online added memory blocks; if onlining fails, memory blocks are removed again.”h]”(hŒDLPAR on ppc64 ignores the ”…”�”}”(hj¼h²hh³Nh´Nubjm)�”}”(hŒ ``offline``”h]”hŒoffline”…”�”}”(hjÄh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj¼ubhŒg setting and will still online added memory blocks; if onlining fails, memory blocks are removed again.”…”�”}”(hj¼h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KÓhj¸ubah}”(h]”h ]”h"]”h$]”h&]”uh1jªhjÓh²hh³hÊh´Nubeh}”(h]”j?ah ]”h"]”Œ$onlining memory blocks automatically”ah$]”h&]”uh1hµhjÒh²hh³hÊh´K·ubh¶)�”}”(hhh]”(h»)�”}”(hŒOfflining Memory Blocks”h]”hŒOfflining Memory Blocks”…”�”}”(hjìh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj[uh1hºhjéh²hh³hÊh´K×ubhÌ)�”}”(hX In the current implementation, Linux's memory offlining will try migrating all movable pages off the affected memory block. As most kernel allocations, such as page tables, are unmovable, page migration can fail and, therefore, inhibit memory offlining from succeeding.”h]”hXIn the current implementation, Linux’s memory offlining will try migrating all movable pages off the affected memory block. As most kernel allocations, such as page tables, are unmovable, page migration can fail and, therefore, inhibit memory offlining from succeeding.”…”�”}”(hjúh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KÙhjéh²hubhÌ)�”}”(hŒ¯Having the memory provided by memory block managed by ZONE_MOVABLE significantly increases memory offlining reliability; still, memory offlining can fail in some corner cases.”h]”hŒ¯Having the memory provided by memory block managed by ZONE_MOVABLE significantly increases memory offlining reliability; still, memory offlining can fail in some corner cases.”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KÞhjéh²hubhÌ)�”}”(hŒcFurther, memory offlining might retry for a long time (or even forever), until aborted by the user.”h]”hŒcFurther, memory offlining might retry for a long time (or even forever), until aborted by the user.”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kâhjéh²hubhÌ)�”}”(hŒ2Offlining of a memory block can be triggered via::”h]”hŒ1Offlining of a memory block can be triggered via:”…”�”}”(hj$ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kåhjéh²hubjo)�”}”(hŒ;% echo offline > /sys/devices/system/memory/memoryXXX/state”h]”hŒ;% echo offline > /sys/devices/system/memory/memoryXXX/state”…”�”}”hj2 sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´Kçhjéh²hubhÌ)�”}”(hŒOr alternatively::”h]”hŒOr alternatively:”…”�”}”(hj@ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kéhjéh²hubjo)�”}”(hŒ6% echo 0 > /sys/devices/system/memory/memoryXXX/online”h]”hŒ6% echo 0 > /sys/devices/system/memory/memoryXXX/online”…”�”}”hjN sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´Këhjéh²hubhÌ)�”}”(hŒÆIf offlining succeeds, the state of the memory block is changed to be "offline". If it fails, the state of the memory block will remain unchanged and the above commands will fail, for example, via::”h]”hŒÉIf offlining succeeds, the state of the memory block is changed to be “offlineâ€�. If it fails, the state of the memory block will remain unchanged and the above commands will fail, for example, via:”…”�”}”(hj\ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kíhjéh²hubjo)�”}”(hŒ0bash: echo: write error: Device or resource busy”h]”hŒ0bash: echo: write error: Device or resource busy”…”�”}”hjj sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´Kñhjéh²hubhÌ)�”}”(hŒor via::”h]”hŒor via:”…”�”}”(hjx h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kóhjéh²hubjo)�”}”(hŒ)bash: echo: write error: Invalid argument”h]”hŒ)bash: echo: write error: Invalid argument”…”�”}”hj† sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´Kõhjéh²hubeh}”(h]”jaah ]”h"]”Œofflining memory blocks”ah$]”h&]”uh1hµhjÒh²hh³hÊh´K×ubh¶)�”}”(hhh]”(h»)�”}”(hŒ$Observing the State of Memory Blocks”h]”hŒ$Observing the State of Memory Blocks”…”�”}”(hjž h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj}uh1hºhj› h²hh³hÊh´KøubhÌ)�”}”(hŒWThe state (online/offline/going-offline) of a memory block can be observed either via::”h]”hŒVThe state (online/offline/going-offline) of a memory block can be observed either via:”…”�”}”(hj¬ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kúhj› h²hubjo)�”}”(hŒ0% cat /sys/devices/system/memory/memoryXXX/state”h]”hŒ0% cat /sys/devices/system/memory/memoryXXX/state”…”�”}”hjº sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´Kýhj› h²hubhÌ)�”}”(hŒOr alternatively (1/0) via::”h]”hŒOr alternatively (1/0) via:”…”�”}”(hjÈ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Kÿhj› h²hubjo)�”}”(hŒ1% cat /sys/devices/system/memory/memoryXXX/online”h]”hŒ1% cat /sys/devices/system/memory/memoryXXX/online”…”�”}”hjÖ sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´Mhj› h²hubhÌ)�”}”(hŒCFor an online memory block, the managing zone can be observed via::”h]”hŒBFor an online memory block, the managing zone can be observed via:”…”�”}”(hjä h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhj› h²hubjo)�”}”(hŒ6% cat /sys/devices/system/memory/memoryXXX/valid_zones”h]”hŒ6% cat /sys/devices/system/memory/memoryXXX/valid_zones”…”�”}”hjò sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´Mhj› h²hubeh}”(h]”jƒah ]”h"]”Œ$observing the state of memory blocks”ah$]”h&]”uh1hµhjÒh²hh³hÊh´Køubeh}”(h]”jþah ]”h"]”Œ$onlining and offlining memory blocks”ah$]”h&]”uh1hµhh·h²hh³hÊh´K‰ubh¶)�”}”(hhh]”(h»)�”}”(hŒConfiguring Memory Hot(Un)Plug”h]”hŒConfiguring Memory Hot(Un)Plug”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj«uh1hºhj h²hh³hÊh´MubhÌ)�”}”(hŒŽThere are various ways how system administrators can configure memory hot(un)plug and interact with memory blocks, especially, to online them.”h]”hŒŽThere are various ways how system administrators can configure memory hot(un)plug and interact with memory blocks, especially, to online them.”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M hj h²hubh¶)�”}”(hhh]”(h»)�”}”(hŒ*Memory Hot(Un)Plug Configuration via Sysfs”h]”hŒ*Memory Hot(Un)Plug Configuration via Sysfs”…”�”}”(hj0 h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jjÊuh1hºhj- h²hh³hÊh´MubhÌ)�”}”(hŒPSome memory hot(un)plug properties can be configured or inspected via sysfs in::”h]”hŒOSome memory hot(un)plug properties can be configured or inspected via sysfs in:”…”�”}”(hj> h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhj- h²hubjo)�”}”(hŒ/sys/devices/system/memory/”h]”hŒ/sys/devices/system/memory/”…”�”}”hjL sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´Mhj- h²hubhÌ)�”}”(hŒ*The following files are currently defined:”h]”hŒ*The following files are currently defined:”…”�”}”(hjZ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhj- h²hubhŒtable”“”)�”}”(hhh]”hŒtgroup”“”)�”}”(hhh]”(hŒcolspec”“”)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”Kuh1jr hjo ubjs )�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K9uh1jr hjo ubhŒtbody”“”)�”}”(hhh]”(hŒrow”“”)�”}”(hhh]”(hŒentry”“”)�”}”(hhh]”hÌ)�”}”(hŒ``auto_online_blocks``”h]”jm)�”}”(hj™ h]”hŒauto_online_blocks”…”�”}”(hj› h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj— ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhj” ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj� ubj“ )�”}”(hhh]”(hÌ)�”}”(hŒWread-write: set or get the default state of new memory blocks; configure auto-onlining.”h]”hŒWread-write: set or get the default state of new memory blocks; configure auto-onlining.”…”�”}”(hj· h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhj´ ubhÌ)�”}”(hŒ]The default value depends on the CONFIG_MHP_DEFAULT_ONLINE_TYPE kernel configuration options.”h]”hŒ]The default value depends on the CONFIG_MHP_DEFAULT_ONLINE_TYPE kernel configuration options.”…”�”}”(hjÅ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhj´ ubhÌ)�”}”(hŒ8See the ``state`` property of memory blocks for details.”h]”(hŒSee the ”…”�”}”(hjÓ h²hh³Nh´Nubjm)�”}”(hŒ ``state``”h]”hŒstate”…”�”}”(hjÛ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjÓ ubhŒ' property of memory blocks for details.”…”�”}”(hjÓ h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhj´ ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj� ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hjŠ ubjŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ``block_size_bytes``”h]”jm)�”}”(hj h]”hŒblock_size_bytes”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjÿ ubj“ )�”}”(hhh]”hÌ)�”}”(hŒ/read-only: the size in bytes of a memory block.”h]”hŒ/read-only: the size in bytes of a memory block.”…”�”}”(hj% h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhj" ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjÿ ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hjŠ ubjŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ ``probe``”h]”jm)�”}”(hjG h]”hŒprobe”…”�”}”(hjI h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjE ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M hjB ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj? ubj“ )�”}”(hhh]”(hÌ)�”}”(hŒpwrite-only: add (probe) selected memory blocks manually from user space by supplying the physical start address.”h]”hŒpwrite-only: add (probe) selected memory blocks manually from user space by supplying the physical start address.”…”�”}”(hje h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M hjb ubhÌ)�”}”(hŒQAvailability depends on the CONFIG_ARCH_MEMORY_PROBE kernel configuration option.”h]”hŒQAvailability depends on the CONFIG_ARCH_MEMORY_PROBE kernel configuration option.”…”�”}”(hjs h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M#hjb ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj? ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hjŠ ubjŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ ``uevent``”h]”jm)�”}”(hj• h]”hŒuevent”…”�”}”(hj— h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj“ ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M%hj� ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj� ubj“ )�”}”(hhh]”hÌ)�”}”(hŒ4read-write: generic udev file for device subsystems.”h]”hŒ4read-write: generic udev file for device subsystems.”…”�”}”(hj³ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M%hj° ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj� ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hjŠ ubjŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ``crash_hotplug``”h]”jm)�”}”(hjÕ h]”hŒ crash_hotplug”…”�”}”(hj× h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjÓ ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M&hjÐ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjÍ ubj“ )�”}”(hhh]”(hÌ)�”}”(hX%read-only: when changes to the system memory map occur due to hot un/plug of memory, this file contains '1' if the kernel updates the kdump capture kernel memory map itself (via elfcorehdr and other relevant kexec segments), or '0' if userspace must update the kdump capture kernel memory map.”h]”hX-read-only: when changes to the system memory map occur due to hot un/plug of memory, this file contains ‘1’ if the kernel updates the kdump capture kernel memory map itself (via elfcorehdr and other relevant kexec segments), or ‘0’ if userspace must update the kdump capture kernel memory map.”…”�”}”(hjó h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M&hjð ubhÌ)�”}”(hŒNAvailability depends on the CONFIG_MEMORY_HOTPLUG kernel configuration option.”h]”hŒNAvailability depends on the CONFIG_MEMORY_HOTPLUG kernel configuration option.”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M-hjð ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjÍ ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hjŠ ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jˆ hjo ubeh}”(h]”h ]”h"]”h$]”h&]”Œcols”Kuh1jm hjj ubah}”(h]”h ]”h"]”h$]”h&]”uh1jh hj- h²hh³hÊh´Nubj«)�”}”(hXLWhen the CONFIG_MEMORY_FAILURE kernel configuration option is enabled, two additional files ``hard_offline_page`` and ``soft_offline_page`` are available to trigger hwpoisoning of pages, for example, for testing purposes. Note that this functionality is not really related to memory hot(un)plug or actual offlining of memory blocks.”h]”hÌ)�”}”(hXLWhen the CONFIG_MEMORY_FAILURE kernel configuration option is enabled, two additional files ``hard_offline_page`` and ``soft_offline_page`` are available to trigger hwpoisoning of pages, for example, for testing purposes. Note that this functionality is not really related to memory hot(un)plug or actual offlining of memory blocks.”h]”(hŒ\When the CONFIG_MEMORY_FAILURE kernel configuration option is enabled, two additional files ”…”�”}”(hj2 h²hh³Nh´Nubjm)�”}”(hŒ``hard_offline_page``”h]”hŒhard_offline_page”…”�”}”(hj: h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj2 ubhŒ and ”…”�”}”(hj2 h²hh³Nh´Nubjm)�”}”(hŒ``soft_offline_page``”h]”hŒsoft_offline_page”…”�”}”(hjL h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj2 ubhŒÁ are available to trigger hwpoisoning of pages, for example, for testing purposes. Note that this functionality is not really related to memory hot(un)plug or actual offlining of memory blocks.”…”�”}”(hj2 h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M3hj. ubah}”(h]”h ]”h"]”h$]”h&]”uh1jªhj- h²hh³hÊh´Nubeh}”(h]”jÐah ]”h"]”Œ*memory hot(un)plug configuration via sysfs”ah$]”h&]”uh1hµhj h²hh³hÊh´Mubh¶)�”}”(hhh]”(h»)�”}”(hŒ$Memory Block Configuration via Sysfs”h]”hŒ$Memory Block Configuration via Sysfs”…”�”}”(hjt h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jjìuh1hºhjq h²hh³hÊh´M:ubhÌ)�”}”(hŒêEach memory block is represented as a memory block device that can be onlined or offlined. All memory blocks have their device information located in sysfs. Each present memory block is listed under ``/sys/devices/system/memory`` as::”h]”(hŒÇEach memory block is represented as a memory block device that can be onlined or offlined. All memory blocks have their device information located in sysfs. Each present memory block is listed under ”…”�”}”(hj‚ h²hh³Nh´Nubjm)�”}”(hŒ``/sys/devices/system/memory``”h]”hŒ/sys/devices/system/memory”…”�”}”(hjŠ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj‚ ubhŒ as:”…”�”}”(hj‚ h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M<hjq h²hubjo)�”}”(hŒ$/sys/devices/system/memory/memoryXXX”h]”hŒ$/sys/devices/system/memory/memoryXXX”…”�”}”hj¢ sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´MAhjq h²hubhÌ)�”}”(hŒCwhere XXX is the memory block id; the number of digits is variable.”h]”hŒCwhere XXX is the memory block id; the number of digits is variable.”…”�”}”(hj° h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MChjq h²hubhÌ)�”}”(hŒ´A present memory block indicates that some memory in the range is present; however, a memory block might span memory holes. A memory block spanning memory holes cannot be offlined.”h]”hŒ´A present memory block indicates that some memory in the range is present; however, a memory block might span memory holes. A memory block spanning memory holes cannot be offlined.”…”�”}”(hj¾ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MEhjq h²hubhÌ)�”}”(hŒ†For example, assume 1 GiB memory block size. A device for a memory starting at 0x100000000 is ``/sys/devices/system/memory/memory4``::”h]”(hŒ^For example, assume 1 GiB memory block size. A device for a memory starting at 0x100000000 is ”…”�”}”(hjÌ h²hh³Nh´Nubjm)�”}”(hŒ&``/sys/devices/system/memory/memory4``”h]”hŒ"/sys/devices/system/memory/memory4”…”�”}”(hjÔ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjÌ ubhŒ:”…”�”}”(hjÌ h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MIhjq h²hubjo)�”}”(hŒ(0x100000000 / 1Gib = 4)”h]”hŒ(0x100000000 / 1Gib = 4)”…”�”}”hjì sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´MLhjq h²hubhÌ)�”}”(hŒ>This device covers address range [0x100000000 ... 0x140000000)”h]”hŒ>This device covers address range [0x100000000 ... 0x140000000)”…”�”}”(hjú h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MNhjq h²hubhÌ)�”}”(hŒ*The following files are currently defined:”h]”hŒ*The following files are currently defined:”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MPhjq h²hubji )�”}”(hhh]”jn )�”}”(hhh]”(js )�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”Kuh1jr hj ubjs )�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K ../../memory/memory9 A backlink will also be created:: /sys/devices/system/memory/memory9/node0 -> ../../node/node0”h]”(hÌ)�”}”(hŒ¼If the CONFIG_NUMA kernel configuration option is enabled, the memoryXXX/ directories can also be accessed via symbolic links located in the ``/sys/devices/system/node/node*`` directories.”h]”(hŒ�If the CONFIG_NUMA kernel configuration option is enabled, the memoryXXX/ directories can also be accessed via symbolic links located in the ”…”�”}”(hjžh²hh³Nh´Nubjm)�”}”(hŒ"``/sys/devices/system/node/node*``”h]”hŒ/sys/devices/system/node/node*”…”�”}”(hj¦h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjžubhŒ directories.”…”�”}”(hjžh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M€hjšubhÌ)�”}”(hŒ For example::”h]”hŒ For example:”…”�”}”(hj¾h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M„hjšubjo)�”}”(hŒ>/sys/devices/system/node/node0/memory9 -> ../../memory/memory9”h]”hŒ>/sys/devices/system/node/node0/memory9 -> ../../memory/memory9”…”�”}”hjÌsbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´M†hjšubhÌ)�”}”(hŒ!A backlink will also be created::”h]”hŒ A backlink will also be created:”…”�”}”(hjÚh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mˆhjšubjo)�”}”(hŒ ../../node/node0”h]”hŒ ../../node/node0”…”�”}”hjèsbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´MŠhjšubeh}”(h]”h ]”h"]”h$]”h&]”uh1jªhjq h²hh³hÊh´Nubeh}”(h]”jòah ]”h"]”Œ$memory block configuration via sysfs”ah$]”h&]”uh1hµhj h²hh³hÊh´M:ubh¶)�”}”(hhh]”(h»)�”}”(hŒCommand Line Parameters”h]”hŒCommand Line Parameters”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jjuh1hºhjh²hh³hÊh´M�ubhÌ)�”}”(hŒtSome command line parameters affect memory hot(un)plug handling. The following command line parameters are relevant:”h]”hŒtSome command line parameters affect memory hot(un)plug handling. The following command line parameters are relevant:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M�hjh²hubji )�”}”(hhh]”jn )�”}”(hhh]”(js )�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”Kuh1jr hj%ubjs )�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K7uh1jr hj%ubj‰ )�”}”(hhh]”(jŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ``memhp_default_state``”h]”jm)�”}”(hjGh]”hŒmemhp_default_state”…”�”}”(hjIh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjEubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M“hjBubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj?ubj“ )�”}”(hhh]”hÌ)�”}”(hŒaconfigure auto-onlining by essentially setting ``/sys/devices/system/memory/auto_online_blocks``.”h]”(hŒ/configure auto-onlining by essentially setting ”…”�”}”(hjeh²hh³Nh´Nubjm)�”}”(hŒ1``/sys/devices/system/memory/auto_online_blocks``”h]”hŒ-/sys/devices/system/memory/auto_online_blocks”…”�”}”(hjmh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjeubhŒ.”…”�”}”(hjeh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M“hjbubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj?ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hj<ubjŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ``movable_node``”h]”jm)�”}”(hj™h]”hŒ movable_node”…”�”}”(hj›h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj—ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M•hj”ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj‘ubj“ )�”}”(hhh]”hÌ)�”}”(hŒÚconfigure automatic zone selection in the kernel when using the ``contig-zones`` online policy. When set, the kernel will default to ZONE_MOVABLE when onlining a memory block, unless other zones can be kept contiguous.”h]”(hŒ@configure automatic zone selection in the kernel when using the ”…”�”}”(hj·h²hh³Nh´Nubjm)�”}”(hŒ``contig-zones``”h]”hŒ contig-zones”…”�”}”(hj¿h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj·ubhŒŠ online policy. When set, the kernel will default to ZONE_MOVABLE when onlining a memory block, unless other zones can be kept contiguous.”…”�”}”(hj·h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M•hj´ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj‘ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hj<ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jˆ hj%ubeh}”(h]”h ]”h"]”h$]”h&]”Œcols”Kuh1jm hj"ubah}”(h]”h ]”h"]”h$]”h&]”uh1jh hjh²hh³hÊh´NubhÌ)�”}”(hŒtSee Documentation/admin-guide/kernel-parameters.txt for a more generic description of these command line parameters.”h]”hŒtSee Documentation/admin-guide/kernel-parameters.txt for a more generic description of these command line parameters.”…”�”}”(hjöh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mœhjh²hubeh}”(h]”jah ]”h"]”Œcommand line parameters”ah$]”h&]”uh1hµhj h²hh³hÊh´M�ubh¶)�”}”(hhh]”(h»)�”}”(hŒModule Parameters”h]”hŒModule Parameters”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj0uh1hºhj h²hh³hÊh´M ubhÌ)�”}”(hXInstead of additional command line parameters or sysfs files, the ``memory_hotplug`` subsystem now provides a dedicated namespace for module parameters. Module parameters can be set via the command line by predicating them with ``memory_hotplug.`` such as::”h]”(hŒBInstead of additional command line parameters or sysfs files, the ”…”�”}”(hjh²hh³Nh´Nubjm)�”}”(hŒ``memory_hotplug``”h]”hŒmemory_hotplug”…”�”}”(hj$h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjubhŒ� subsystem now provides a dedicated namespace for module parameters. Module parameters can be set via the command line by predicating them with ”…”�”}”(hjh²hh³Nh´Nubjm)�”}”(hŒ``memory_hotplug.``”h]”hŒmemory_hotplug.”…”�”}”(•|¦hj6h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjubhŒ such as:”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M¢hj h²hubjo)�”}”(hŒ!memory_hotplug.memmap_on_memory=1”h]”hŒ!memory_hotplug.memmap_on_memory=1”…”�”}”hjNsbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´M§hj h²hubhÌ)�”}”(hŒBand they can be observed (and some even modified at runtime) via::”h]”hŒAand they can be observed (and some even modified at runtime) via:”…”�”}”(hj\h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M©hj h²hubjo)�”}”(hŒ&/sys/module/memory_hotplug/parameters/”h]”hŒ&/sys/module/memory_hotplug/parameters/”…”�”}”hjjsbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´M«hj h²hubhÌ)�”}”(hŒ6The following module parameters are currently defined:”h]”hŒ6The following module parameters are currently defined:”…”�”}”(hjxh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M­hj h²hubji )�”}”(hhh]”jn )�”}”(hhh]”(js )�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K uh1jr hj‰ubjs )�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K/uh1jr hj‰ubj‰ )�”}”(hhh]”(jŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ``memmap_on_memory``”h]”jm)�”}”(hj«h]”hŒmemmap_on_memory”…”�”}”(hj­h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj©ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M°hj¦ubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj£ubj“ )�”}”(hhh]”(hÌ)�”}”(hŒæread-write: Allocate memory for the memmap from the added memory block itself. Even if enabled, actual support depends on various other system properties and should only be regarded as a hint whether the behavior would be desired.”h]”hŒæread-write: Allocate memory for the memmap from the added memory block itself. Even if enabled, actual support depends on various other system properties and should only be regarded as a hint whether the behavior would be desired.”…”�”}”(hjÉh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M°hjÆubhÌ)�”}”(hXWhile allocating the memmap from the memory block itself makes memory hotplug less likely to fail and keeps the memmap on the same NUMA node in any case, it can fragment physical memory in a way that huge pages in bigger granularity cannot be formed on hotplugged memory.”h]”hXWhile allocating the memmap from the memory block itself makes memory hotplug less likely to fail and keeps the memmap on the same NUMA node in any case, it can fragment physical memory in a way that huge pages in bigger granularity cannot be formed on hotplugged memory.”…”�”}”(hj×h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M¶hjÆubhÌ)�”}”(hX­With value "force" it could result in memory wastage due to memmap size limitations. For example, if the memmap for a memory block requires 1 MiB, but the pageblock size is 2 MiB, 1 MiB of hotplugged memory will be wasted. Note that there are still cases where the feature cannot be enforced: for example, if the memmap is smaller than a single page, or if the architecture does not support the forced mode in all configurations.”h]”hX±With value “forceâ€� it could result in memory wastage due to memmap size limitations. For example, if the memmap for a memory block requires 1 MiB, but the pageblock size is 2 MiB, 1 MiB of hotplugged memory will be wasted. Note that there are still cases where the feature cannot be enforced: for example, if the memmap is smaller than a single page, or if the architecture does not support the forced mode in all configurations.”…”�”}”(hjåh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M¾hjÆubeh}”(h]”h ]”h"]”h$]”h&]”uh1j’ hj£ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hj ubjŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ``online_policy``”h]”jm)�”}”(hjh]”hŒ online_policy”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MÉhjubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjÿubj“ )�”}”(hhh]”(hÌ)�”}”(hX5read-write: Set the basic policy used for automatic zone selection when onlining memory blocks without specifying a target zone. ``contig-zones`` has been the kernel default before this parameter was added. After an online policy was configured and memory was online, the policy should not be changed anymore.”h]”(hŒ�read-write: Set the basic policy used for automatic zone selection when onlining memory blocks without specifying a target zone. ”…”�”}”(hj%h²hh³Nh´Nubjm)�”}”(hŒ``contig-zones``”h]”hŒ contig-zones”…”�”}”(hj-h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj%ubhŒ¤ has been the kernel default before this parameter was added. After an online policy was configured and memory was online, the policy should not be changed anymore.”…”�”}”(hj%h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MÉhj"ubhÌ)�”}”(hX7When set to ``contig-zones``, the kernel will try keeping zones contiguous. If a memory block intersects multiple zones or no zone, the behavior depends on the ``movable_node`` kernel command line parameter: default to ZONE_MOVABLE if set, default to the applicable kernel zone (usually ZONE_NORMAL) if not set.”h]”(hŒ When set to ”…”�”}”(hjEh²hh³Nh´Nubjm)�”}”(hŒ``contig-zones``”h]”hŒ contig-zones”…”�”}”(hjMh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjEubhŒ„, the kernel will try keeping zones contiguous. If a memory block intersects multiple zones or no zone, the behavior depends on the ”…”�”}”(hjEh²hh³Nh´Nubjm)�”}”(hŒ``movable_node``”h]”hŒ movable_node”…”�”}”(hj_h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjEubhŒ‡ kernel command line parameter: default to ZONE_MOVABLE if set, default to the applicable kernel zone (usually ZONE_NORMAL) if not set.”…”�”}”(hjEh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MÒhj"ubhÌ)�”}”(hXWhen set to ``auto-movable``, the kernel will try onlining memory blocks to ZONE_MOVABLE if possible according to the configuration and memory device details. With this policy, one can avoid zone imbalances when eventually hotplugging a lot of memory later and still wanting to be able to hotunplug as much as possible reliably, very desirable in virtualized environments. This policy ignores the ``movable_node`` kernel command line parameter and isn't really applicable in environments that require it (e.g., bare metal with hotunpluggable nodes) where hotplugged memory might be exposed via the firmware-provided memory map early during boot to the system instead of getting detected, added and onlined later during boot (such as done by virtio-mem or by some hypervisors implementing emulated DIMMs). As one example, a hotplugged DIMM will be onlined either completely to ZONE_MOVABLE or completely to ZONE_NORMAL, not a mixture. As another example, as many memory blocks belonging to a virtio-mem device will be onlined to ZONE_MOVABLE as possible, special-casing units of memory blocks that can only get hotunplugged together. *This policy does not protect from setups that are problematic with ZONE_MOVABLE and does not change the zone of memory blocks dynamically after they were onlined.*”h]”(hŒ When set to ”…”�”}”(hjwh²hh³Nh´Nubjm)�”}”(hŒ``auto-movable``”h]”hŒ auto-movable”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjwubhXq, the kernel will try onlining memory blocks to ZONE_MOVABLE if possible according to the configuration and memory device details. With this policy, one can avoid zone imbalances when eventually hotplugging a lot of memory later and still wanting to be able to hotunplug as much as possible reliably, very desirable in virtualized environments. This policy ignores the ”…”�”}”(hjwh²hh³Nh´Nubjm)�”}”(hŒ``movable_node``”h]”hŒ movable_node”…”�”}”(hj‘h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjwubhXÓ kernel command line parameter and isn’t really applicable in environments that require it (e.g., bare metal with hotunpluggable nodes) where hotplugged memory might be exposed via the firmware-provided memory map early during boot to the system instead of getting detected, added and onlined later during boot (such as done by virtio-mem or by some hypervisors implementing emulated DIMMs). As one example, a hotplugged DIMM will be onlined either completely to ZONE_MOVABLE or completely to ZONE_NORMAL, not a mixture. As another example, as many memory blocks belonging to a virtio-mem device will be onlined to ZONE_MOVABLE as possible, special-casing units of memory blocks that can only get hotunplugged together. ”…”�”}”(hjwh²hh³Nh´NubhŒemphasis”“”)�”}”(hŒ¤*This policy does not protect from setups that are problematic with ZONE_MOVABLE and does not change the zone of memory blocks dynamically after they were onlined.*”h]”hŒ¢This policy does not protect from setups that are problematic with ZONE_MOVABLE and does not change the zone of memory blocks dynamically after they were onlined.”…”�”}”(hj¥h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j£hjwubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MÚhj"ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjÿubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hj ubjŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ``auto_movable_ratio``”h]”jm)�”}”(hjÍh]”hŒauto_movable_ratio”…”�”}”(hjÏh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjËubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MùhjÈubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjÅubj“ )�”}”(hhh]”(hÌ)�”}”(hŒùread-write: Set the maximum MOVABLE:KERNEL memory ratio in % for the ``auto-movable`` online policy. Whether the ratio applies only for the system across all NUMA nodes or also per NUMA nodes depends on the ``auto_movable_numa_aware`` configuration.”h]”(hŒEread-write: Set the maximum MOVABLE:KERNEL memory ratio in % for the ”…”�”}”(hjëh²hh³Nh´Nubjm)�”}”(hŒ``auto-movable``”h]”hŒ auto-movable”…”�”}”(hjóh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjëubhŒz online policy. Whether the ratio applies only for the system across all NUMA nodes or also per NUMA nodes depends on the ”…”�”}”(hjëh²hh³Nh´Nubjm)�”}”(hŒ``auto_movable_numa_aware``”h]”hŒauto_movable_numa_aware”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjëubhŒ configuration.”…”�”}”(hjëh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MùhjèubhÌ)�”}”(hX!All accounting is based on present memory pages in the zones combined with accounting per memory device. Memory dedicated to the CMA allocator is accounted as MOVABLE, although residing on one of the kernel zones. The possible ratio depends on the actual workload. The kernel default is "301" %, for example, allowing for hotplugging 24 GiB to a 8 GiB VM and automatically onlining all hotplugged memory to ZONE_MOVABLE in many setups. The additional 1% deals with some pages being not present, for example, because of some firmware allocations.”h]”hX%All accounting is based on present memory pages in the zones combined with accounting per memory device. Memory dedicated to the CMA allocator is accounted as MOVABLE, although residing on one of the kernel zones. The possible ratio depends on the actual workload. The kernel default is “301â€� %, for example, allowing for hotplugging 24 GiB to a 8 GiB VM and automatically onlining all hotplugged memory to ZONE_MOVABLE in many setups. The additional 1% deals with some pages being not present, for example, because of some firmware allocations.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MhjèubhÌ)�”}”(hXÅNote that ZONE_NORMAL memory provided by one memory device does not allow for more ZONE_MOVABLE memory for a different memory device. As one example, onlining memory of a hotplugged DIMM to ZONE_NORMAL will not allow for another hotplugged DIMM to get onlined to ZONE_MOVABLE automatically. In contrast, memory hotplugged by a virtio-mem device that got onlined to ZONE_NORMAL will allow for more ZONE_MOVABLE memory within *the same* virtio-mem device.”h]”(hX¨Note that ZONE_NORMAL memory provided by one memory device does not allow for more ZONE_MOVABLE memory for a different memory device. As one example, onlining memory of a hotplugged DIMM to ZONE_NORMAL will not allow for another hotplugged DIMM to get onlined to ZONE_MOVABLE automatically. In contrast, memory hotplugged by a virtio-mem device that got onlined to ZONE_NORMAL will allow for more ZONE_MOVABLE memory within ”…”�”}”(hj+h²hh³Nh´Nubj¤)�”}”(hŒ *the same*”h]”hŒthe same”…”�”}”(hj3h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j£hj+ubhŒ virtio-mem device.”…”�”}”(hj+h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mhjèubeh}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjÅubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hj ubjŽ )�”}”(hhh]”(j“ )�”}”(hhh]”hÌ)�”}”(hŒ``auto_movable_numa_aware``”h]”jm)�”}”(hj_h]”hŒauto_movable_numa_aware”…”�”}”(hjah²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj]ubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MhjZubah}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjWubj“ )�”}”(hhh]”(hÌ)�”}”(hŒËread-write: Configure whether the ``auto_movable_ratio`` in the ``auto-movable`` online policy also applies per NUMA node in addition to the whole system across all NUMA nodes. The kernel default is "Y".”h]”(hŒ"read-write: Configure whether the ”…”�”}”(hj}h²hh³Nh´Nubjm)�”}”(hŒ``auto_movable_ratio``”h]”hŒauto_movable_ratio”…”�”}”(hj…h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj}ubhŒ in the ”…”�”}”(hj}h²hh³Nh´Nubjm)�”}”(hŒ``auto-movable``”h]”hŒ auto-movable”…”�”}”(hj—h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj}ubhŒ online policy also applies per NUMA node in addition to the whole system across all NUMA nodes. The kernel default is “Yâ€�.”…”�”}”(hj}h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MhjzubhÌ)�”}”(hŒ¸Disabling NUMA awareness can be helpful when dealing with NUMA nodes that should be completely hotunpluggable, onlining the memory completely to ZONE_MOVABLE automatically if possible.”h]”hŒ¸Disabling NUMA awareness can be helpful when dealing with NUMA nodes that should be completely hotunpluggable, onlining the memory completely to ZONE_MOVABLE automatically if possible.”…”�”}”(hj¯h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MhjzubhÌ)�”}”(hŒ.Parameter availability depends on CONFIG_NUMA.”h]”hŒ.Parameter availability depends on CONFIG_NUMA.”…”�”}”(hj½h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M%hjzubeh}”(h]”h ]”h"]”h$]”h&]”uh1j’ hjWubeh}”(h]”h ]”h"]”h$]”h&]”uh1j� hj ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jˆ hj‰ubeh}”(h]”h ]”h"]”h$]”h&]”Œcols”Kuh1jm hj†ubah}”(h]”h ]”h"]”h$]”h&]”uh1jh hj h²hh³hÊh´Nubeh}”(h]”j6ah ]”h"]”Œmodule parameters”ah$]”h&]”uh1hµhj h²hh³hÊh´M ubeh}”(h]”j±ah ]”h"]”Œconfiguring memory hot(un)plug”ah$]”h&]”uh1hµhh·h²hh³hÊh´Mubh¶)�”}”(hhh]”(h»)�”}”(hŒ ZONE_MOVABLE”h]”hŒ ZONE_MOVABLE”…”�”}”(hjûh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj^uh1hºhjøh²hh³hÊh´M)ubhÌ)�”}”(hXZONE_MOVABLE is an important mechanism for more reliable memory offlining. Further, having system RAM managed by ZONE_MOVABLE instead of one of the kernel zones can increase the number of possible transparent huge pages and dynamically allocated huge pages.”h]”hXZONE_MOVABLE is an important mechanism for more reliable memory offlining. Further, having system RAM managed by ZONE_MOVABLE instead of one of the kernel zones can increase the number of possible transparent huge pages and dynamically allocated huge pages.”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M+hjøh²hubhÌ)�”}”(hŒÄMost kernel allocations are unmovable. Important examples include the memory map (usually 1/64ths of memory), page tables, and kmalloc(). Such allocations can only be served from the kernel zones.”h]”hŒÄMost kernel allocations are unmovable. Important examples include the memory map (usually 1/64ths of memory), page tables, and kmalloc(). Such allocations can only be served from the kernel zones.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M0hjøh²hubhÌ)�”}”(hŒ™Most user space pages, such as anonymous memory, and page cache pages are movable. Such allocations can be served from ZONE_MOVABLE and the kernel zones.”h]”hŒ™Most user space pages, such as anonymous memory, and page cache pages are movable. Such allocations can be served from ZONE_MOVABLE and the kernel zones.”…”�”}”(hj%h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M4hjøh²hubhÌ)�”}”(hŒèOnly movable allocations are served from ZONE_MOVABLE, resulting in unmovable allocations being limited to the kernel zones. Without ZONE_MOVABLE, there is absolutely no guarantee whether a memory block can be offlined successfully.”h]”hŒèOnly movable allocations are served from ZONE_MOVABLE, resulting in unmovable allocations being limited to the kernel zones. Without ZONE_MOVABLE, there is absolutely no guarantee whether a memory block can be offlined successfully.”…”�”}”(hj3h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M7hjøh²hubh¶)�”}”(hhh]”(h»)�”}”(hŒZone Imbalances”h]”hŒZone Imbalances”…”�”}”(hjDh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jj}uh1hºhjAh²hh³hÊh´M<ubhÌ)�”}”(hX)Having too much system RAM managed by ZONE_MOVABLE is called a zone imbalance, which can harm the system or degrade performance. As one example, the kernel might crash because it runs out of free memory for unmovable allocations, although there is still plenty of free memory left in ZONE_MOVABLE.”h]”hX)Having too much system RAM managed by ZONE_MOVABLE is called a zone imbalance, which can harm the system or degrade performance. As one example, the kernel might crash because it runs out of free memory for unmovable allocations, although there is still plenty of free memory left in ZONE_MOVABLE.”…”�”}”(hjRh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M>hjAh²hubhÌ)�”}”(hŒ’Usually, MOVABLE:KERNEL ratios of up to 3:1 or even 4:1 are fine. Ratios of 63:1 are definitely impossible due to the overhead for the memory map.”h]”hŒ’Usually, MOVABLE:KERNEL ratios of up to 3:1 or even 4:1 are fine. Ratios of 63:1 are definitely impossible due to the overhead for the memory map.”…”�”}”(hj`h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MChjAh²hubhÌ)�”}”(hŒ�Actual safe zone ratios depend on the workload. Extreme cases, like excessive long-term pinning of pages, might not be able to deal with ZONE_MOVABLE at all.”h]”hŒ�Actual safe zone ratios depend on the workload. Extreme cases, like excessive long-term pinning of pages, might not be able to deal with ZONE_MOVABLE at all.”…”�”}”(hjnh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MFhjAh²hubj«)�”}”(hŒ£CMA memory part of a kernel zone essentially behaves like memory in ZONE_MOVABLE and similar considerations apply, especially when combining CMA with ZONE_MOVABLE.”h]”hÌ)�”}”(hŒ£CMA memory part of a kernel zone essentially behaves like memory in ZONE_MOVABLE and similar considerations apply, especially when combining CMA with ZONE_MOVABLE.”h]”hŒ£CMA memory part of a kernel zone essentially behaves like memory in ZONE_MOVABLE and similar considerations apply, especially when combining CMA with ZONE_MOVABLE.”…”�”}”(hj€h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MKhj|ubah}”(h]”h ]”h"]”h$]”h&]”uh1jªhjAh²hh³hÊh´Nubeh}”(h]”jƒah ]”h"]”Œzone imbalances”ah$]”h&]”uh1hµhjøh²hh³hÊh´M<ubh¶)�”}”(hhh]”(h»)�”}”(hŒ"ZONE_MOVABLE Sizing Considerations”h]”hŒ"ZONE_MOVABLE Sizing Considerations”…”�”}”(hjžh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jjŸuh1hºhj›h²hh³hÊh´MPubhÌ)�”}”(hŒìWe usually expect that a large portion of available system RAM will actually be consumed by user space, either directly or indirectly via the page cache. In the normal case, ZONE_MOVABLE can be used when allocating such pages just fine.”h]”hŒìWe usually expect that a large portion of available system RAM will actually be consumed by user space, either directly or indirectly via the page cache. In the normal case, ZONE_MOVABLE can be used when allocating such pages just fine.”…”�”}”(hj¬h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MRhj›h²hubhÌ)�”}”(hŒÔWith that in mind, it makes sense that we can have a big portion of system RAM managed by ZONE_MOVABLE. However, there are some things to consider when using ZONE_MOVABLE, especially when fine-tuning zone ratios:”h]”hŒÔWith that in mind, it makes sense that we can have a big portion of system RAM managed by ZONE_MOVABLE. However, there are some things to consider when using ZONE_MOVABLE, especially when fine-tuning zone ratios:”…”�”}”(hjºh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MVhj›h²hubhá)�”}”(hhh]”(hæ)�”}”(hŒÆHaving a lot of offline memory blocks. Even offline memory blocks consume memory for metadata and page tables in the direct map; having a lot of offline memory blocks is not a typical case, though. ”h]”hÌ)�”}”(hŒÅHaving a lot of offline memory blocks. Even offline memory blocks consume memory for metadata and page tables in the direct map; having a lot of offline memory blocks is not a typical case, though.”h]”hŒÅHaving a lot of offline memory blocks. Even offline memory blocks consume memory for metadata and page tables in the direct map; having a lot of offline memory blocks is not a typical case, though.”…”�”}”(hjÏh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MZhjËubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjÈh²hh³hÊh´Nubhæ)�”}”(hXÎMemory ballooning without support for balloon memory migration is incompatible with ZONE_MOVABLE. Only some implementations, such as virtio-balloon and pseries CMM, fully support balloon memory migration. Further, the CONFIG_BALLOON_MIGRATION kernel configuration option might be disabled. In that case, balloon inflation will only perform unmovable allocations and silently create a zone imbalance, usually triggered by inflation requests from the hypervisor. ”h]”(hÌ)�”}”(hŒÌMemory ballooning without support for balloon memory migration is incompatible with ZONE_MOVABLE. Only some implementations, such as virtio-balloon and pseries CMM, fully support balloon memory migration.”h]”hŒÌMemory ballooning without support for balloon memory migration is incompatible with ZONE_MOVABLE. Only some implementations, such as virtio-balloon and pseries CMM, fully support balloon memory migration.”…”�”}”(hjçh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M^hjãubhÌ)�”}”(hŒÿFurther, the CONFIG_BALLOON_MIGRATION kernel configuration option might be disabled. In that case, balloon inflation will only perform unmovable allocations and silently create a zone imbalance, usually triggered by inflation requests from the hypervisor.”h]”hŒÿFurther, the CONFIG_BALLOON_MIGRATION kernel configuration option might be disabled. In that case, balloon inflation will only perform unmovable allocations and silently create a zone imbalance, usually triggered by inflation requests from the hypervisor.”…”�”}”(hjõh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mbhjãubeh}”(h]”h ]”h"]”h$]”h&]”uh1håhjÈh²hh³hÊh´Nubhæ)�”}”(hŒØGigantic pages are unmovable when an architecture does not support huge page migration and/or the ``movable_gigantic_pages`` sysctl is false. See Documentation/admin-guide/sysctl/vm.rst for more info on this sysctl. ”h]”hÌ)�”}”(hŒ×Gigantic pages are unmovable when an architecture does not support huge page migration and/or the ``movable_gigantic_pages`` sysctl is false. See Documentation/admin-guide/sysctl/vm.rst for more info on this sysctl.”h]”(hŒbGigantic pages are unmovable when an architecture does not support huge page migration and/or the ”…”�”}”(hj h²hh³Nh´Nubjm)�”}”(hŒ``movable_gigantic_pages``”h]”hŒmovable_gigantic_pages”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj ubhŒ[ sysctl is false. See Documentation/admin-guide/sysctl/vm.rst for more info on this sysctl.”…”�”}”(hj h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mghj ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjÈh²hh³hÊh´Nubhæ)�”}”(hŒŠHuge pages are unmovable when an architectures does not support huge page migration, resulting in a similar issue as with gigantic pages. ”h]”hÌ)�”}”(hŒ‰Huge pages are unmovable when an architectures does not support huge page migration, resulting in a similar issue as with gigantic pages.”h]”hŒ‰Huge pages are unmovable when an architectures does not support huge page migration, resulting in a similar issue as with gigantic pages.”…”�”}”(hj7h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mkhj3ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjÈh²hh³hÊh´Nubhæ)�”}”(hXxPage tables are unmovable. Excessive swapping, mapping extremely large files or ZONE_DEVICE memory can be problematic, although only really relevant in corner cases. When we manage a lot of user space memory that has been swapped out or is served from a file/persistent memory/... we still need a lot of page tables to manage that memory once user space accessed that memory. ”h]”hÌ)�”}”(hXwPage tables are unmovable. Excessive swapping, mapping extremely large files or ZONE_DEVICE memory can be problematic, although only really relevant in corner cases. When we manage a lot of user space memory that has been swapped out or is served from a file/persistent memory/... we still need a lot of page tables to manage that memory once user space accessed that memory.”h]”hXwPage tables are unmovable. Excessive swapping, mapping extremely large files or ZONE_DEVICE memory can be problematic, although only really relevant in corner cases. When we manage a lot of user space memory that has been swapped out or is served from a file/persistent memory/... we still need a lot of page tables to manage that memory once user space accessed that memory.”…”�”}”(hjOh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´MnhjKubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjÈh²hh³hÊh´Nubhæ)�”}”(hŒlIn certain DAX configurations the memory map for the device memory will be allocated from the kernel zones. ”h]”hÌ)�”}”(hŒkIn certain DAX configurations the memory map for the device memory will be allocated from the kernel zones.”h]”hŒkIn certain DAX configurations the memory map for the device memory will be allocated from the kernel zones.”…”�”}”(hjgh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mthjcubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjÈh²hh³hÊh´Nubhæ)�”}”(hŒ�KASAN can have a significant memory overhead, for example, consuming 1/8th of the total system memory size as (unmovable) tracking metadata. ”h]”hÌ)�”}”(hŒŒKASAN can have a significant memory overhead, for example, consuming 1/8th of the total system memory size as (unmovable) tracking metadata.”h]”hŒŒKASAN can have a significant memory overhead, for example, consuming 1/8th of the total system memory size as (unmovable) tracking metadata.”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mwhj{ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhjÈh²hh³hÊh´Nubhæ)�”}”(hXLong-term pinning of pages. Techniques that rely on long-term pinnings (especially, RDMA and vfio/mdev) are fundamentally problematic with ZONE_MOVABLE, and therefore, memory offlining. Pinned pages cannot reside on ZONE_MOVABLE as that would turn these pages unmovable. Therefore, they have to be migrated off that zone while pinning. Pinning a page can fail even if there is plenty of free memory in ZONE_MOVABLE. In addition, using ZONE_MOVABLE might make page pinning more expensive, because of the page migration overhead. ”h]”(hÌ)�”}”(hXŸLong-term pinning of pages. Techniques that rely on long-term pinnings (especially, RDMA and vfio/mdev) are fundamentally problematic with ZONE_MOVABLE, and therefore, memory offlining. Pinned pages cannot reside on ZONE_MOVABLE as that would turn these pages unmovable. Therefore, they have to be migrated off that zone while pinning. Pinning a page can fail even if there is plenty of free memory in ZONE_MOVABLE.”h]”hXŸLong-term pinning of pages. Techniques that rely on long-term pinnings (especially, RDMA and vfio/mdev) are fundamentally problematic with ZONE_MOVABLE, and therefore, memory offlining. Pinned pages cannot reside on ZONE_MOVABLE as that would turn these pages unmovable. Therefore, they have to be migrated off that zone while pinning. Pinning a page can fail even if there is plenty of free memory in ZONE_MOVABLE.”…”�”}”(hj—h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mzhj“ubhÌ)�”}”(hŒoIn addition, using ZONE_MOVABLE might make page pinning more expensive, because of the page migration overhead.”h]”hŒoIn addition, using ZONE_MOVABLE might make page pinning more expensive, because of the page migration overhead.”…”�”}”(hj¥h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M�hj“ubeh}”(h]”h ]”h"]”h$]”h&]”uh1håhjÈh²hh³hÊh´Nubeh}”(h]”h ]”h"]”h$]”h&]”jojpuh1hàh³hÊh´MZhj›h²hubhÌ)�”}”(hŒoBy default, all the memory configured at boot time is managed by the kernel zones and ZONE_MOVABLE is not used.”h]”hŒoBy default, all the memory configured at boot time is managed by the kernel zones and ZONE_MOVABLE is not used.”…”�”}”(hj¿h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M„hj›h²hubhÌ)�”}”(hX To enable ZONE_MOVABLE to include the memory present at boot and to control the ratio between movable and kernel zones there are two command line options: ``kernelcore=`` and ``movablecore=``. See Documentation/admin-guide/kernel-parameters.rst for their description.”h]”(hŒ›To enable ZONE_MOVABLE to include the memory present at boot and to control the ratio between movable and kernel zones there are two command line options: ”…”�”}”(hjÍh²hh³Nh´Nubjm)�”}”(hŒ``kernelcore=``”h]”hŒ kernelcore=”…”�”}”(hjÕh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjÍubhŒ and ”…”�”}”(hjÍh²hh³Nh´Nubjm)�”}”(hŒ``movablecore=``”h]”hŒ movablecore=”…”�”}”(hjçh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjÍubhŒL. See Documentation/admin-guide/kernel-parameters.rst for their description.”…”�”}”(hjÍh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M‡hj›h²hubeh}”(h]”j¥ah ]”h"]”Œ"zone_movable sizing considerations”ah$]”h&]”uh1hµhjøh²hh³hÊh´MPubh¶)�”}”(hhh]”(h»)�”}”(hŒ!Memory Offlining and ZONE_MOVABLE”h]”hŒ!Memory Offlining and ZONE_MOVABLE”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”jjÁuh1hºhjh²hh³hÊh´M�ubhÌ)�”}”(hŒ^Even with ZONE_MOVABLE, there are some corner cases where offlining a memory block might fail:”h]”hŒ^Even with ZONE_MOVABLE, there are some corner cases where offlining a memory block might fail:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M�hjh²hubhá)�”}”(hhh]”(hæ)�”}”(hŒªMemory blocks with memory holes; this applies to memory blocks present during boot and can apply to memory blocks hotplugged via the XEN balloon and the Hyper-V balloon. ”h]”hÌ)�”}”(hŒ©Memory blocks with memory holes; this applies to memory blocks present during boot and can apply to memory blocks hotplugged via the XEN balloon and the Hyper-V balloon.”h]”hŒ©Memory blocks with memory holes; this applies to memory blocks present during boot and can apply to memory blocks hotplugged via the XEN balloon and the Hyper-V balloon.”…”�”}”(hj,h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M’hj(ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj%h²hh³hÊh´Nubhæ)�”}”(hŒ�Mixed NUMA nodes and mixed zones within a single memory block prevent memory offlining; this applies to memory blocks present during boot only. ”h]”hÌ)�”}”(hŒ�Mixed NUMA nodes and mixed zones within a single memory block prevent memory offlining; this applies to memory blocks present during boot only.”h]”hŒ�Mixed NUMA nodes and mixed zones within a single memory block prevent memory offlining; this applies to memory blocks present during boot only.”…”�”}”(hjDh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M–hj@ubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj%h²hh³hÊh´Nubhæ)�”}”(hŒùSpecial memory blocks prevented by the system from getting offlined. Examples include any memory available during boot on arm64 or memory blocks spanning the crashkernel area on s390x; this usually applies to memory blocks present during boot only. ”h]”hÌ)�”}”(hŒøSpecial memory blocks prevented by the system from getting offlined. Examples include any memory available during boot on arm64 or memory blocks spanning the crashkernel area on s390x; this usually applies to memory blocks present during boot only.”h]”hŒøSpecial memory blocks prevented by the system from getting offlined. Examples include any memory available during boot on arm64 or memory blocks spanning the crashkernel area on s390x; this usually applies to memory blocks present during boot only.”…”�”}”(hj\h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M™hjXubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj%h²hh³hÊh´Nubhæ)�”}”(hŒuMemory blocks overlapping with CMA areas cannot be offlined, this applies to memory blocks present during boot only. ”h]”hÌ)�”}”(hŒtMemory blocks overlapping with CMA areas cannot be offlined, this applies to memory blocks present during boot only.”h]”hŒtMemory blocks overlapping with CMA areas cannot be offlined, this applies to memory blocks present during boot only.”…”�”}”(hjth²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mžhjpubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj%h²hh³hÊh´Nubhæ)�”}”(hŒ“Concurrent activity that operates on the same physical memory area, such as allocating gigantic pages, can result in temporary offlining failures. ”h]”hÌ)�”}”(hŒ’Concurrent activity that operates on the same physical memory area, such as allocating gigantic pages, can result in temporary offlining failures.”h]”hŒ’Concurrent activity that operates on the same physical memory area, such as allocating gigantic pages, can result in temporary offlining failures.”…”�”}”(hjŒh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M¡hjˆubah}”(h]”h ]”h"]”h$]”h&]”uh1håhj%h²hh³hÊh´Nubhæ)�”}”(hXÜWhen an admin sets the ``movable_gigantic_pages`` sysctl to true, gigantic pages are allowed in ZONE_MOVABLE. This only allows migratable gigantic pages to be allocated; however, if there are no eligible destination gigantic pages at offline, the offlining operation will fail. Users leveraging ``movable_gigantic_pages`` should weigh the value of ZONE_MOVABLE for increasing the reliability of gigantic page allocation against the potential loss of hot-unplug reliability. ”h]”(hÌ)�”}”(hXWhen an admin sets the ``movable_gigantic_pages`` sysctl to true, gigantic pages are allowed in ZONE_MOVABLE. This only allows migratable gigantic pages to be allocated; however, if there are no eligible destination gigantic pages at offline, the offlining operation will fail.”h]”(hŒWhen an admin sets the ”…”�”}”(hj¤h²hh³Nh´Nubjm)�”}”(hŒ``movable_gigantic_pages``”h]”hŒmovable_gigantic_pages”…”�”}”(hj¬h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhj¤ubhŒå sysctl to true, gigantic pages are allowed in ZONE_MOVABLE. This only allows migratable gigantic pages to be allocated; however, if there are no eligible destination gigantic pages at offline, the offlining operation will fail.”…”�”}”(hj¤h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M¤hj ubhÌ)�”}”(hŒÃUsers leveraging ``movable_gigantic_pages`` should weigh the value of ZONE_MOVABLE for increasing the reliability of gigantic page allocation against the potential loss of hot-unplug reliability.”h]”(hŒUsers leveraging ”…”�”}”(hjÄh²hh³Nh´Nubjm)�”}”(hŒ``movable_gigantic_pages``”h]”hŒmovable_gigantic_pages”…”�”}”(hjÌh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jlhjÄubhŒ˜ should weigh the value of ZONE_MOVABLE for increasing the reliability of gigantic page allocation against the potential loss of hot-unplug reliability.”…”�”}”(hjÄh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M©hj ubeh}”(h]”h ]”h"]”h$]”h&]”uh1håhj%h²hh³hÊh´Nubhæ)�”}”(hXIOut of memory when dissolving huge pages, especially when HugeTLB Vmemmap Optimization (HVO) is enabled. Offlining code may be able to migrate huge page contents, but may not be able to dissolve the source huge page because it fails allocating (unmovable) pages for the vmemmap, because the system might not have free memory in the kernel zones left. Users that depend on memory offlining to succeed for movable zones should carefully consider whether the memory savings gained from this feature are worth the risk of possibly not being able to offline memory in certain situations. ”h]”(hÌ)�”}”(hŒhOut of memory when dissolving huge pages, especially when HugeTLB Vmemmap Optimization (HVO) is enabled.”h]”hŒhOut of memory when dissolving huge pages, especially when HugeTLB Vmemmap Optimization (HVO) is enabled.”…”�”}”(hjîh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M­hjêubhÌ)�”}”(hŒõOfflining code may be able to migrate huge page contents, but may not be able to dissolve the source huge page because it fails allocating (unmovable) pages for the vmemmap, because the system might not have free memory in the kernel zones left.”h]”hŒõOfflining code may be able to migrate huge page contents, but may not be able to dissolve the source huge page because it fails allocating (unmovable) pages for the vmemmap, because the system might not have free memory in the kernel zones left.”…”�”}”(hjüh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M°hjêubhÌ)�”}”(hŒçUsers that depend on memory offlining to succeed for movable zones should carefully consider whether the memory savings gained from this feature are worth the risk of possibly not being able to offline memory in certain situations.”h]”hŒçUsers that depend on memory offlining to succeed for movable zones should carefully consider whether the memory savings gained from this feature are worth the risk of possibly not being able to offline memory in certain situations.”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mµhjêubeh}”(h]”h ]”h"]”h$]”h&]”uh1håhj%h²hh³hÊh´Nubeh}”(h]”h ]”h"]”h$]”h&]”jojpuh1hàh³hÊh´M’hjh²hubhÌ)�”}”(hŒáFurther, when running into out of memory situations while migrating pages, or when still encountering permanently unmovable pages within ZONE_MOVABLE (-> BUG), memory offlining will keep retrying until it eventually succeeds.”h]”hŒáFurther, when running into out of memory situations while migrating pages, or when still encountering permanently unmovable pages within ZONE_MOVABLE (-> BUG), memory offlining will keep retrying until it eventually succeeds.”…”�”}”(hj$h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Mºhjh²hubhÌ)�”}”(hŒ£When offlining is triggered from user space, the offlining context can be terminated by sending a signal. A timeout based offlining can easily be implemented via::”h]”hŒ¢When offlining is triggered from user space, the offlining context can be terminated by sending a signal. A timeout based offlining can easily be implemented via:”…”�”}”(hj2h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´M¾hjh²hubjo)�”}”(hŒ3% timeout $TIMEOUT offline_block | failure_handling”h]”hŒ3% timeout $TIMEOUT offline_block | failure_handling”…”�”}”hj@sbah}”(h]”h ]”h"]”h$]”h&]”j~juh1jnh³hÊh´MÂhjh²hubeh}”(h]”jÇah ]”h"]”Œ!memory offlining and zone_movable”ah$]”h&]”uh1hµhjøh²hh³hÊh´M�ubeh}”(h]”jdah ]”h"]”Œ zone_movable”ah$]”h&]”uh1hµhh·h²hh³hÊh´M)ubeh}”(h]”Œmemory-hot-un-plug”ah ]”h"]”Œmemory hot(un)plug”ah$]”h&]”uh1hµhhh²hh³hÊh´Kubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”hÊuh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)�”}”(hºNŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”j’ Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”j†Œerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”hÊŒ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”Œnameids”}”(jaj^jíjèjÏhþjÌjjNj?jÈjajÏj�j>j®jÈjÐj jþjÐjjæj?j˜ jaj jƒjõj±jn jÐjjòjjjîj6jYjdj˜jƒjj¥jRjÇuŒ nametypes”}”(ja‰jí‰jωj̉jN‰jȉjωj>‰jȉj ‰jЉjæ‰j˜ ‰j ‰jõ‰jn ‰j‰j‰jî‰jY‰j˜‰j‰jR‰uh}”(j^h·jèhÝhþjðjj�j?jÏjajQj�jÒj®jñjÐjAjþjÒjj j?jÓjajéjƒj› j±j jÐj- jòjq jjj6j jdjøjƒjAj¥j›jÇjhøhïjjj9j0j[jRj‰j€j¨jŸjÊjÁjøjïjjj9j0j[jRj}jtj«j¢jÊjÁjìjãjjj0j'j^jUj}jtjŸj–jÁj¸uŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”j”Ks…”R”Œparse_messages”]”Œtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nh²hub.