€• Œ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”Œ-/translations/zh_CN/admin-guide/blockdev/zram”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)�”}”(hhh]”hŒChinese (Traditional)”…”�”}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ-/translations/zh_TW/admin-guide/blockdev/zram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒItalian”…”�”}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ-/translations/it_IT/admin-guide/blockdev/zram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒJapanese”…”�”}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ-/translations/ja_JP/admin-guide/blockdev/zram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒKorean”…”�”}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ-/translations/ko_KR/admin-guide/blockdev/zram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒPortuguese (Brazilian)”…”�”}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ-/translations/pt_BR/admin-guide/blockdev/zram”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒSpanish”…”�”}”hh–sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ-/translations/sp_SP/admin-guide/blockdev/zram”Œ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Œ(zram: Compressed RAM-based block devices”h]”hŒ(zram: Compressed RAM-based block devices”…”�”}”(hh¼h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhh·h²hh³ŒG/var/lib/git/docbuild/linux/Documentation/admin-guide/blockdev/zram.rst”h´Kubh¶)�”}”(hhh]”(h»)�”}”(hŒ Introduction”h]”hŒ Introduction”…”�”}”(hhÎh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhhËh²hh³hÊh´KubhŒ paragraph”“”)�”}”(hXjThe zram module creates RAM-based block devices named /dev/zram ( = 0, 1, ...). Pages written to these disks are compressed and stored in memory itself. These disks allow very fast I/O and compression provides good amounts of memory savings. Some of the use cases include /tmp storage, use as swap disks, various caches under /var and maybe many more. :)”h]”hXjThe zram module creates RAM-based block devices named /dev/zram ( = 0, 1, ...). Pages written to these disks are compressed and stored in memory itself. These disks allow very fast I/O and compression provides good amounts of memory savings. Some of the use cases include /tmp storage, use as swap disks, various caches under /var and maybe many more. :)”…”�”}”(hhÞh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KhhËh²hubhÝ)�”}”(hŒ_Statistics for individual zram devices are exported through sysfs nodes at /sys/block/zram/”h]”hŒ_Statistics for individual zram devices are exported through sysfs nodes at /sys/block/zram/”…”�”}”(hhìh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KhhËh²hubeh}”(h]”Œ introduction”ah ]”h"]”Œ introduction”ah$]”h&]”uh1hµhh·h²hh³hÊh´Kubh¶)�”}”(hhh]”(h»)�”}”(hŒUsage”h]”hŒUsage”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjh²hh³hÊh´KubhÝ)�”}”(hŒ?There are several ways to configure and manage zram device(-s):”h]”hŒ?There are several ways to configure and manage zram device(-s):”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Khjh²hubhŒenumerated_list”“”)�”}”(hhh]”(hŒ list_item”“”)�”}”(hŒ,using zram and zram_control sysfs attributes”h]”hÝ)�”}”(hj*h]”hŒ,using zram and zram_control sysfs attributes”…”�”}”(hj,h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Khj(ubah}”(h]”h ]”h"]”h$]”h&]”uh1j&hj#h²hh³hÊh´Nubj')�”}”(hŒLusing zramctl utility, provided by util-linux (util-linux@vger.kernel.org). ”h]”hÝ)�”}”(hŒKusing zramctl utility, provided by util-linux (util-linux@vger.kernel.org).”h]”(hŒ/using zramctl utility, provided by util-linux (”…”�”}”(hjCh²hh³Nh´NubhŒ reference”“”)�”}”(hŒutil-linux@vger.kernel.org”h]”hŒutil-linux@vger.kernel.org”…”�”}”(hjMh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œ!mailto:util-linux@vger.kernel.org”uh1jKhjCubhŒ).”…”�”}”(hjCh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Khj?ubah}”(h]”h ]”h"]”h$]”h&]”uh1j&hj#h²hh³hÊh´Nubeh}”(h]”h ]”h"]”h$]”h&]”Œenumtype”Œ loweralpha”Œprefix”hŒsuffix”Œ)”uh1j!hjh²hh³hÊh´KubhÝ)�”}”(hŒvIn this document we will describe only 'manual' zram configuration steps, IOW, zram and zram_control sysfs attributes.”h]”hŒzIn this document we will describe only ‘manual’ zram configuration steps, IOW, zram and zram_control sysfs attributes.”…”�”}”(hjxh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Khjh²hubhÝ)�”}”(hXIn order to get a better idea about zramctl please consult util-linux documentation, zramctl man-page or `zramctl --help`. Please be informed that zram maintainers do not develop/maintain util-linux or zramctl, should you have any questions please contact util-linux@vger.kernel.org”h]”(hŒiIn order to get a better idea about zramctl please consult util-linux documentation, zramctl man-page or ”…”�”}”(hj†h²hh³Nh´NubhŒtitle_reference”“”)�”}”(hŒ`zramctl --help`”h]”hŒzramctl --help”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj†ubhŒ‡. Please be informed that zram maintainers do not develop/maintain util-linux or zramctl, should you have any questions please contact ”…”�”}”(hj†h²hh³Nh´NubjL)�”}”(hŒutil-linux@vger.kernel.org”h]”hŒutil-linux@vger.kernel.org”…”�”}”(hj¢h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œ!mailto:util-linux@vger.kernel.org”uh1jKhj†ubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Khjh²hubhÝ)�”}”(hŒ;Following shows a typical sequence of steps for using zram.”h]”hŒ;Following shows a typical sequence of steps for using zram.”…”�”}”(hj¸h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K!hjh²hubeh}”(h]”Œusage”ah ]”h"]”Œusage”ah$]”h&]”uh1hµhh·h²hh³hÊh´Kubh¶)�”}”(hhh]”(h»)�”}”(hŒWARNING”h]”hŒWARNING”…”�”}”(hjÑh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjÎh²hh³hÊh´K$ubhÝ)�”}”(hŒ�For the sake of simplicity we skip error checking parts in most of the examples below. However, it is your sole responsibility to handle errors.”h]”hŒ�For the sake of simplicity we skip error checking parts in most of the examples below. However, it is your sole responsibility to handle errors.”…”�”}”(hjßh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K&hjÎh²hubhÝ)�”}”(hŒizram sysfs attributes always return negative values in case of errors. The list of possible return codes:”h]”hŒizram sysfs attributes always return negative values in case of errors. The list of possible return codes:”…”�”}”(hjíh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K)hjÎh²hubhŒtable”“”)�”}”(hhh]”hŒtgroup”“”)�”}”(hhh]”(hŒcolspec”“”)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”Kuh1jhjubj)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K>uh1jhjubhŒtbody”“”)�”}”(hhh]”(hŒrow”“”)�”}”(hhh]”(hŒentry”“”)�”}”(hhh]”hÝ)�”}”(hŒ-EBUSY”h]”hŒ-EBUSY”…”�”}”(hj*h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K-hj'ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj"ubj&)�”}”(hhh]”hÝ)�”}”(hŒyan attempt to modify an attribute that cannot be changed once the device has been initialised. Please reset device first.”h]”hŒyan attempt to modify an attribute that cannot be changed once the device has been initialised. Please reset device first.”…”�”}”(hjAh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K-hj>ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj"ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ-ENOMEM”h]”hŒ-ENOMEM”…”�”}”(hjah²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K/hj^ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj[ubj&)�”}”(hhh]”hÝ)�”}”(hŒAzram was not able to allocate enough memory to fulfil your needs.”h]”hŒAzram was not able to allocate enough memory to fulfil your needs.”…”�”}”(hjxh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K/hjuubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj[ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ-EINVAL”h]”hŒ-EINVAL”…”�”}”(hj˜h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K1hj•ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj’ubj&)�”}”(hhh]”hÝ)�”}”(hŒ invalid input has been provided.”h]”hŒ invalid input has been provided.”…”�”}”(hj¯h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K1hj¬ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj’ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ-EAGAIN”h]”hŒ-EAGAIN”…”�”}”(hjÏh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K2hjÌubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÉubj&)�”}”(hhh]”hÝ)�”}”(hŒ]re-try operation later (e.g. when attempting to run recompress and writeback simultaneously).”h]”hŒ]re-try operation later (e.g. when attempting to run recompress and writeback simultaneously).”…”�”}”(hjæh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K2hjãubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÉubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1jhjubeh}”(h]”h ]”h"]”h$]”h&]”Œcols”Kuh1jhjýubah}”(h]”h ]”h"]”h$]”h&]”uh1jûhjÎh²hh³hÊh´NubhÝ)�”}”(hŒjIf you use 'echo', the returned value is set by the 'echo' utility, and, in general case, something like::”h]”hŒqIf you use ‘echo’, the returned value is set by the ‘echo’ utility, and, in general case, something like:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K6hjÎh²hubhŒ literal_block”“”)�”}”(hŒXecho foo > /sys/block/zram0/comp_algorithm if [ $? -ne 0 ]; then handle_error fi”h]”hŒXecho foo > /sys/block/zram0/comp_algorithm if [ $? -ne 0 ]; then handle_error fi”…”�”}”hj#sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1j!h³hÊh´K9hjÎh²hubhÝ)�”}”(hŒshould suffice.”h]”hŒshould suffice.”…”�”}”(hj3h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K>hjÎh²hubeh}”(h]”Œwarning”ah ]”h"]”Œwarning”ah$]”h&]”uh1hµhh·h²hh³hÊh´K$ubh¶)�”}”(hhh]”(h»)�”}”(hŒ Load Module”h]”hŒ Load Module”…”�”}”(hjLh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjIh²hh³hÊh´KAubj")�”}”(hŒmodprobe zram num_devices=4”h]”hŒmodprobe zram num_devices=4”…”�”}”hjZsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´KEhjIh²hubhÝ)�”}”(hŒ*This creates 4 devices: /dev/zram{0,1,2,3}”h]”hŒ*This creates 4 devices: /dev/zram{0,1,2,3}”…”�”}”(hjhh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KGhjIh²hubhÝ)�”}”(hŒdnum_devices parameter is optional and tells zram how many devices should be pre-created. Default: 1.”h]”hŒdnum_devices parameter is optional and tells zram how many devices should be pre-created. Default: 1.”…”�”}”(hjvh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KIhjIh²hubeh}”(h]”Œ load-module”ah ]”h"]”Œ load module”ah$]”h&]”uh1hµhh·h²hh³hÊh´KAubh¶)�”}”(hhh]”(h»)�”}”(hŒSelect compression algorithm”h]”hŒSelect compression algorithm”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjŒh²hh³hÊh´KMubhÝ)�”}”(hXUsing comp_algorithm device attribute one can see available and currently selected (shown in square brackets) compression algorithms, or change the selected compression algorithm (once the device is initialised there is no way to change compression algorithm).”h]”hXUsing comp_algorithm device attribute one can see available and currently selected (shown in square brackets) compression algorithms, or change the selected compression algorithm (once the device is initialised there is no way to change compression algorithm).”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KOhjŒh²hubhÝ)�”}”(hŒ Examples::”h]”hŒ Examples:”…”�”}”(hj«h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KThjŒh²hubj")�”}”(hŒ¢#show supported compression algorithms cat /sys/block/zram0/comp_algorithm lzo [lz4] #select lzo compression algorithm echo lzo > /sys/block/zram0/comp_algorithm”h]”hŒ¢#show supported compression algorithms cat /sys/block/zram0/comp_algorithm lzo [lz4] #select lzo compression algorithm echo lzo > /sys/block/zram0/comp_algorithm”…”�”}”hj¹sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´KVhjŒh²hubhÝ)�”}”(hŒnFor the time being, the `comp_algorithm` content shows only compression algorithms that are supported by zram.”h]”(hŒFor the time being, the ”…”�”}”(hjÇh²hh³Nh´Nubj�)�”}”(hŒ`comp_algorithm`”h]”hŒcomp_algorithm”…”�”}”(hjÏh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjÇubhŒF content shows only compression algorithms that are supported by zram.”…”�”}”(hjÇh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K]hjŒh²hubeh}”(h]”Œselect-compression-algorithm”ah ]”h"]”Œselect compression algorithm”ah$]”h&]”uh1hµhh·h²hh³hÊh´KMubh¶)�”}”(hhh]”(h»)�”}”(hŒ.Set compression algorithm parameters: Optional”h]”hŒ.Set compression algorithm parameters: Optional”…”�”}”(hjòh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjïh²hh³hÊh´KaubhÝ)�”}”(hŒÈCompression algorithms may support specific parameters which can be tweaked for particular dataset. ZRAM has an `algorithm_params` device attribute which provides a per-algorithm params configuration.”h]”(hŒpCompression algorithms may support specific parameters which can be tweaked for particular dataset. ZRAM has an ”…”�”}”(hjh²hh³Nh´Nubj�)�”}”(hŒ`algorithm_params`”h]”hŒalgorithm_params”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjubhŒF device attribute which provides a per-algorithm params configuration.”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kchjïh²hubhÝ)�”}”(hX[For example, several compression algorithms support `level` parameter. In addition, certain compression algorithms support pre-trained dictionaries, which significantly change algorithms' characteristics. In order to configure compression algorithm to use external pre-trained dictionary, pass full path to the `dict` along with other parameters::”h]”(hŒ4For example, several compression algorithms support ”…”�”}”(hj h²hh³Nh´Nubj�)�”}”(hŒ`level`”h]”hŒlevel”…”�”}”(hj(h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj ubhŒþ parameter. In addition, certain compression algorithms support pre-trained dictionaries, which significantly change algorithms’ characteristics. In order to configure compression algorithm to use external pre-trained dictionary, pass full path to the ”…”�”}”(hj h²hh³Nh´Nubj�)�”}”(hŒ`dict`”h]”hŒdict”…”�”}”(hj:h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj ubhŒ along with other parameters:”…”�”}”(hj h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kghjïh²hubj")�”}”(hXÊ#pass path to pre-trained zstd dictionary echo "algo=zstd dict=/etc/dictionary" > /sys/block/zram0/algorithm_params #pass path to pre-trained zstd dictionary and compression level echo "algo=zstd level=8 dict=/etc/dictionary" > \ /sys/block/zram0/algorithm_params #same, but using algorithm priority echo "algo=zstd priority=1" > /sys/block/zram0/recomp_algorithm echo "priority=1 dict=/etc/dictionary" > \ /sys/block/zram0/algorithm_params”h]”hXÊ#pass path to pre-trained zstd dictionary echo "algo=zstd dict=/etc/dictionary" > /sys/block/zram0/algorithm_params #pass path to pre-trained zstd dictionary and compression level echo "algo=zstd level=8 dict=/etc/dictionary" > \ /sys/block/zram0/algorithm_params #same, but using algorithm priority echo "algo=zstd priority=1" > /sys/block/zram0/recomp_algorithm echo "priority=1 dict=/etc/dictionary" > \ /sys/block/zram0/algorithm_params”…”�”}”hjRsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´Kmhjïh²hubhÝ)�”}”(hŒõEach write to `algorithm_params` replaces the entire set of parameters of the corresponding algorithm, parameters that are not listed in the write are reset to their default values. Configure all of the parameters of an algorithm in one write::”h]”(hŒEach write to ”…”�”}”(hj`h²hh³Nh´Nubj�)�”}”(hŒ`algorithm_params`”h]”hŒalgorithm_params”…”�”}”(hjhh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj`ubhŒÔ replaces the entire set of parameters of the corresponding algorithm, parameters that are not listed in the write are reset to their default values. Configure all of the parameters of an algorithm in one write:”…”�”}”(hj`h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kyhjïh²hubj")�”}”(hX*#WRONG: the second write resets level back to its default value echo "algo=zstd level=8" > /sys/block/zram0/algorithm_params echo "algo=zstd dict=/etc/dictionary" > /sys/block/zram0/algorithm_params #RIGHT echo "algo=zstd level=8 dict=/etc/dictionary" > \ /sys/block/zram0/algorithm_params”h]”hX*#WRONG: the second write resets level back to its default value echo "algo=zstd level=8" > /sys/block/zram0/algorithm_params echo "algo=zstd dict=/etc/dictionary" > /sys/block/zram0/algorithm_params #RIGHT echo "algo=zstd level=8 dict=/etc/dictionary" > \ /sys/block/zram0/algorithm_params”…”�”}”hj€sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´K~hjïh²hubhÝ)�”}”(hŒæSelect the compression algorithm before configuring its parameters. The parameters of one algorithm are not necessarily valid for another one, so changing the algorithm of a particular priority resets that priority's parameters::”h]”hŒçSelect the compression algorithm before configuring its parameters. The parameters of one algorithm are not necessarily valid for another one, so changing the algorithm of a particular priority resets that priority’s parameters:”…”�”}”(hjŽh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K†hjïh²hubj")�”}”(hX#WRONG: comp_algorithm write resets the previously configured level echo "level=8" > /sys/block/zram0/algorithm_params echo zstd > /sys/block/zram0/comp_algorithm #RIGHT echo zstd > /sys/block/zram0/comp_algorithm echo "algo=zstd level=8" > /sys/block/zram0/algorithm_params”h]”hX#WRONG: comp_algorithm write resets the previously configured level echo "level=8" > /sys/block/zram0/algorithm_params echo zstd > /sys/block/zram0/comp_algorithm #RIGHT echo zstd > /sys/block/zram0/comp_algorithm echo "algo=zstd level=8" > /sys/block/zram0/algorithm_params”…”�”}”hjœsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´K‹hjïh²hubhÝ)�”}”(hX¡Parameters are algorithm specific: not all algorithms support pre-trained dictionaries, not all algorithms support `level`. Furthermore, for certain algorithms `level` controls the compression level (the higher the value the better the compression ratio, it even can take negatives values for some algorithms), for other algorithms `level` is acceleration level (the higher the value the lower the compression ratio).”h]”(hŒsParameters are algorithm specific: not all algorithms support pre-trained dictionaries, not all algorithms support ”…”�”}”(hjªh²hh³Nh´Nubj�)�”}”(hŒ`level`”h]”hŒlevel”…”�”}”(hj²h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjªubhŒ&. Furthermore, for certain algorithms ”…”�”}”(hjªh²hh³Nh´Nubj�)�”}”(hŒ`level`”h]”hŒlevel”…”�”}”(hjÄh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjªubhŒ¥ controls the compression level (the higher the value the better the compression ratio, it even can take negatives values for some algorithms), for other algorithms ”…”�”}”(hjªh²hh³Nh´Nubj�)�”}”(hŒ`level`”h]”hŒlevel”…”�”}”(hjÖh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjªubhŒN is acceleration level (the higher the value the lower the compression ratio).”…”�”}”(hjªh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K“hjïh²hubhÝ)�”}”(hXParameters are handed over to the compression algorithm when the device is initialised, hence invalid parameters (or parameters that the selected algorithm does not support) are reported by the `disksize` write, and not by the `algorithm_params` write that has configured them.”h]”(hŒÂParameters are handed over to the compression algorithm when the device is initialised, hence invalid parameters (or parameters that the selected algorithm does not support) are reported by the ”…”�”}”(hjîh²hh³Nh´Nubj�)�”}”(hŒ `disksize`”h]”hŒdisksize”…”�”}”(hjöh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjîubhŒ write, and not by the ”…”�”}”(hjîh²hh³Nh´Nubj�)�”}”(hŒ`algorithm_params`”h]”hŒalgorithm_params”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjîubhŒ write that has configured them.”…”�”}”(hjîh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kšhjïh²hubeh}”(h]”Œ-set-compression-algorithm-parameters-optional”ah ]”h"]”Œ.set compression algorithm parameters: optional”ah$]”h&]”uh1hµhh·h²hh³hÊh´Kaubh¶)�”}”(hhh]”(h»)�”}”(hŒ Set Disksize”h]”hŒ Set Disksize”…”�”}”(hj+h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhj(h²hh³hÊh´K ubhÝ)�”}”(hŒ…Set disk size by writing the value to sysfs node 'disksize'. The value can be either in bytes or you can use mem suffixes. Examples::”h]”hŒˆSet disk size by writing the value to sysfs node ‘disksize’. The value can be either in bytes or you can use mem suffixes. Examples:”…”�”}”(hj9h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K¢hj(h²hubj")�”}”(hŒã# Initialize /dev/zram0 with 50MB disksize echo $((50*1024*1024)) > /sys/block/zram0/disksize # Using mem suffixes echo 256K > /sys/block/zram0/disksize echo 512M > /sys/block/zram0/disksize echo 1G > /sys/block/zram0/disksize”h]”hŒã# Initialize /dev/zram0 with 50MB disksize echo $((50*1024*1024)) > /sys/block/zram0/disksize # Using mem suffixes echo 256K > /sys/block/zram0/disksize echo 512M > /sys/block/zram0/disksize echo 1G > /sys/block/zram0/disksize”…”�”}”hjGsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´K¦hj(h²hubhÝ)�”}”(hŒàNote: There is little point creating a zram of greater than twice the size of memory since we expect a 2:1 compression ratio. Note that zram uses about 0.1% of the size of the disk when not in use so a huge zram is wasteful.”h]”hŒàNote: There is little point creating a zram of greater than twice the size of memory since we expect a 2:1 compression ratio. Note that zram uses about 0.1% of the size of the disk when not in use so a huge zram is wasteful.”…”�”}”(hjUh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K®hj(h²hubeh}”(h]”Œ set-disksize”ah ]”h"]”Œ set disksize”ah$]”h&]”uh1hµhh·h²hh³hÊh´K ubh¶)�”}”(hhh]”(h»)�”}”(hŒSet memory limit: Optional”h]”hŒSet memory limit: Optional”…”�”}”(hjnh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjkh²hh³hÊh´K´ubhÝ)�”}”(hŒ½Set memory limit by writing the value to sysfs node 'mem_limit'. The value can be either in bytes or you can use mem suffixes. In addition, you could change the value in runtime. Examples::”h]”hŒÀSet memory limit by writing the value to sysfs node ‘mem_limit’. The value can be either in bytes or you can use mem suffixes. In addition, you could change the value in runtime. Examples:”…”�”}”(hj|h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K¶hjkh²hubj")�”}”(hX# limit /dev/zram0 with 50MB memory echo $((50*1024*1024)) > /sys/block/zram0/mem_limit # Using mem suffixes echo 256K > /sys/block/zram0/mem_limit echo 512M > /sys/block/zram0/mem_limit echo 1G > /sys/block/zram0/mem_limit # To disable memory limit echo 0 > /sys/block/zram0/mem_limit”h]”hX# limit /dev/zram0 with 50MB memory echo $((50*1024*1024)) > /sys/block/zram0/mem_limit # Using mem suffixes echo 256K > /sys/block/zram0/mem_limit echo 512M > /sys/block/zram0/mem_limit echo 1G > /sys/block/zram0/mem_limit # To disable memory limit echo 0 > /sys/block/zram0/mem_limit”…”�”}”hjŠsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´K»hjkh²hubeh}”(h]”Œset-memory-limit-optional”ah ]”h"]”Œset memory limit: optional”ah$]”h&]”uh1hµhh·h²hh³hÊh´K´ubh¶)�”}”(hhh]”(h»)�”}”(hŒActivate”h]”hŒActivate”…”�”}”(hj£h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhj h²hh³hÊh´KÇubj")�”}”(hŒOmkswap /dev/zram0 swapon /dev/zram0 mkfs.ext4 /dev/zram1 mount /dev/zram1 /tmp”h]”hŒOmkswap /dev/zram0 swapon /dev/zram0 mkfs.ext4 /dev/zram1 mount /dev/zram1 /tmp”…”�”}”hj±sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´KËhj h²hubeh}”(h]”Œactivate”ah ]”h"]”Œactivate”ah$]”h&]”uh1hµhh·h²hh³hÊh´KÇubh¶)�”}”(hhh]”(h»)�”}”(hŒAdd/remove zram devices”h]”hŒAdd/remove zram devices”…”�”}”(hjÊh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjÇh²hh³hÊh´KÒubhÝ)�”}”(hŒazram provides a control interface, which enables dynamic (on-demand) device addition and removal.”h]”hŒazram provides a control interface, which enables dynamic (on-demand) device addition and removal.”…”�”}”(hjØh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KÔhjÇh²hubhÝ)�”}”(hŒÉIn order to add a new /dev/zramX device, perform a read operation on the hot_add attribute. This will return either the new device's device id (meaning that you can use /dev/zram) or an error code.”h]”hŒËIn order to add a new /dev/zramX device, perform a read operation on the hot_add attribute. This will return either the new device’s device id (meaning that you can use /dev/zram) or an error code.”…”�”}”(hjæh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´K×hjÇh²hubhÝ)�”}”(hŒ Example::”h]”hŒExample:”…”�”}”(hjôh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KÛhjÇh²hubj")�”}”(hŒ%cat /sys/class/zram-control/hot_add 1”h]”hŒ%cat /sys/class/zram-control/hot_add 1”…”�”}”hjsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´KÝhjÇh²hubhÝ)�”}”(hŒKTo remove the existing /dev/zramX device (where X is a device id) execute::”h]”hŒJTo remove the existing /dev/zramX device (where X is a device id) execute:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KàhjÇh²hubj")�”}”(hŒ+echo X > /sys/class/zram-control/hot_remove”h]”hŒ+echo X > /sys/class/zram-control/hot_remove”…”�”}”hjsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´KãhjÇh²hubeh}”(h]”Œadd-remove-zram-devices”ah ]”h"]”Œadd/remove zram devices”ah$]”h&]”uh1hµhh·h²hh³hÊh´KÒubh¶)�”}”(hhh]”(h»)�”}”(hŒStats”h]”hŒStats”…”�”}”(hj7h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhj4h²hh³hÊh´KæubhÝ)�”}”(hŒNPer-device statistics are exported as various nodes under /sys/block/zram/”h]”hŒNPer-device statistics are exported as various nodes under /sys/block/zram/”…”�”}”(hjEh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kèhj4h²hubhÝ)�”}”(hŒƒA brief description of exported device attributes follows. For more details please read Documentation/ABI/testing/sysfs-block-zram.”h]”hŒƒA brief description of exported device attributes follows. For more details please read Documentation/ABI/testing/sysfs-block-zram.”…”�”}”(hjSh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kêhj4h²hubjü)�”}”(hhh]”j)�”}”(hhh]”(j)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”Kuh1jhjdubj)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”Kuh1jhjdubj)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K/uh1jhjdubhŒthead”“”)�”}”(hhh]”j!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒName”h]”hŒName”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kîhj�ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjŠubj&)�”}”(hhh]”hÝ)�”}”(hŒaccess”h]”hŒaccess”…”�”}”(hj§h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kîhj¤ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjŠubj&)�”}”(hhh]”hÝ)�”}”(hŒ description”h]”hŒ description”…”�”}”(hj¾h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kîhj»ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjŠubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hj‡ubah}”(h]”h ]”h"]”h$]”h&]”uh1j…hjdubj)�”}”(hhh]”(j!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒdisksize”h]”hŒdisksize”…”�”}”(hjçh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kðhjäubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjáubj&)�”}”(hhh]”hÝ)�”}”(hŒRW”h]”hŒRW”…”�”}”(hjþh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kðhjûubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjáubj&)�”}”(hhh]”hÝ)�”}”(hŒ#show and set the device's disk size”h]”hŒ%show and set the device’s disk size”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kðhjubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjáubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ initstate”h]”hŒ initstate”…”�”}”(hj5h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kñhj2ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj/ubj&)�”}”(hhh]”hÝ)�”}”(hŒRO”h]”hŒRO”…”�”}”(hjLh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KñhjIubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj/ubj&)�”}”(hhh]”hÝ)�”}”(hŒ,shows the initialization state of the device”h]”hŒ,shows the initialization state of the device”…”�”}”(hjch²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kñhj`ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj/ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒreset”h]”hŒreset”…”�”}”(hjƒh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kòhj€ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj}ubj&)�”}”(hhh]”hÝ)�”}”(hŒWO”h]”hŒWO”…”�”}”(hjšh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kòhj—ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj}ubj&)�”}”(hhh]”hÝ)�”}”(hŒtrigger device reset”h]”hŒtrigger device reset”…”�”}”(hj±h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kòhj®ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj}ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ mem_used_max”h]”hŒ mem_used_max”…”�”}”(hjÑh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KóhjÎubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjËubj&)�”}”(hhh]”hÝ)�”}”(hŒWO”h]”hŒWO”…”�”}”(hjèh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kóhjåubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjËubj&)�”}”(hhh]”hÝ)�”}”(hŒ,reset the `mem_used_max` counter (see later)”h]”(hŒ reset the ”…”�”}”(hjÿh²hh³Nh´Nubj�)�”}”(hŒ`mem_used_max`”h]”hŒ mem_used_max”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjÿubhŒ counter (see later)”…”�”}”(hjÿh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kóhjüubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjËubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ mem_limit”h]”hŒ mem_limit”…”�”}”(hj1h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kôhj.ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj+ubj&)�”}”(hhh]”hÝ)�”}”(hŒWO”h]”hŒWO”…”�”}”(hjHh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KôhjEubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj+ubj&)�”}”(hhh]”hÝ)�”}”(hŒPspecifies the maximum amount of memory ZRAM can use to store the compressed data”h]”hŒPspecifies the maximum amount of memory ZRAM can use to store the compressed data”…”�”}”(hj_h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kôhj\ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj+ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒwriteback_limit”h]”hŒwriteback_limit”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Köhj|ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjyubj&)�”}”(hhh]”hÝ)�”}”(hŒWO”h]”hŒWO”…”�”}”(hj–h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Köhj“ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjyubj&)�”}”(hhh]”hÝ)�”}”(hŒYspecifies the maximum amount of write IO zram can write out to backing device as 4KB unit”h]”hŒYspecifies the maximum amount of write IO zram can write out to backing device as 4KB unit”…”�”}”(hj­h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Köhjªubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjyubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒwriteback_limit_enable”h]”hŒwriteback_limit_enable”…”�”}”(hjÍh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KøhjÊubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÇubj&)�”}”(hhh]”hÝ)�”}”(hŒRW”h]”hŒRW”…”�”}”(hjäh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Køhjáubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÇubj&)�”}”(hhh]”hÝ)�”}”(hŒ$show and set writeback_limit feature”h]”hŒ$show and set writeback_limit feature”…”�”}”(hjûh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Køhjøubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÇubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒwriteback_batch_size”h]”hŒwriteback_batch_size”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kùhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj ubj&)�”}”(hhh]”hÝ)�”}”(hŒRW”h]”hŒRW”…”�”}”(hj2 h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kùhj/ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj ubj&)�”}”(hhh]”hÝ)�”}”(hŒ=show and set maximum number of in-flight writeback operations”h]”hŒ=show and set maximum number of in-flight writeback operations”…”�”}”(hjI h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KùhjF ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒcompressed_writeback”h]”hŒcompressed_writeback”…”�”}”(hji h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kûhjf ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjc ubj&)�”}”(hhh]”hÝ)�”}”(hŒRW”h]”hŒRW”…”�”}”(hj€ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kûhj} ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjc ubj&)�”}”(hhh]”hÝ)�”}”(hŒ)show and set compressed writeback feature”h]”hŒ)show and set compressed writeback feature”…”�”}”(hj— h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kûhj” ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjc ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒcomp_algorithm”h]”hŒcomp_algorithm”…”�”}”(hj· h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kühj´ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj± ubj&)�”}”(hhh]”hÝ)�”}”(hŒRW”h]”hŒRW”…”�”}”(hjÎ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KühjË ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj± ubj&)�”}”(hhh]”hÝ)�”}”(hŒ)show and change the compression algorithm”h]”hŒ)show and change the compression algorithm”…”�”}”(hjå h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kühjâ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj± ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒalgorithm_params”h]”hŒalgorithm_params”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kýhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÿ ubj&)�”}”(hhh]”hÝ)�”}”(hŒWO”h]”hŒWO”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kýhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÿ ubj&)�”}”(hhh]”hÝ)�”}”(hŒ&setup compression algorithm parameters”h]”hŒ&setup compression algorithm parameters”…”�”}”(hj3 h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kýhj0 ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÿ ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒcompact”h]”hŒcompact”…”�”}”(hjS h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KþhjP ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjM ubj&)�”}”(hhh]”hÝ)�”}”(hŒWO”h]”hŒWO”…”�”}”(hjj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kþhjg ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjM ubj&)�”}”(hhh]”hÝ)�”}”(hŒtrigger memory compaction”h]”hŒtrigger memory compaction”…”�”}”(hj� h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kþhj~ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjM ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ debug_stat”h]”hŒ debug_stat”…”�”}”(hj¡ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kÿhjž ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj› ubj&)�”}”(hhh]”hÝ)�”}”(hŒRO”h]”hŒRO”…”�”}”(hj¸ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Kÿhjµ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj› ubj&)�”}”(hhh]”hÝ)�”}”(hŒ-this file is used for zram debugging purposes”h]”hŒ-this file is used for zram debugging purposes”…”�”}”(hjÏ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´KÿhjÌ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj› ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ backing_dev”h]”hŒ backing_dev”…”�”}”(hjï h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhjì ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjé ubj&)�”}”(hhh]”hÝ)�”}”(hŒRW”h]”hŒRW”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjé ubj&)�”}”(hhh]”hÝ)�”}”(hŒ,set up backend storage for zram to write out”h]”hŒ,set up backend storage for zram to write out”…”�”}”(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Œidle”h]”hŒidle”…”�”}”(hj= h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhj: ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj7 ubj&)�”}”(hhh]”hÝ)�”}”(hŒWO”h]”hŒWO”…”�”}”(hjT h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MhjQ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj7 ubj&)�”}”(hhh]”hÝ)�”}”(hŒmark allocated slot as idle”h]”hŒmark allocated slot as idle”…”�”}”(hjk h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhjh ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj7 ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjÞubeh}”(h]”h ]”h"]”h$]”h&]”uh1jhjdubeh}”(h]”h ]”h"]”h$]”h&]”Œcols”Kuh1jhjaubah}”(h]”h ]”h"]”h$]”h&]”uh1jûhj4h²hh³hÊh´NubhÝ)�”}”(hŒOUser space is advised to use the following files to read the device statistics.”h]”hŒOUser space is advised to use the following files to read the device statistics.”…”�”}”(hj˜ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhj4h²hubhÝ)�”}”(hŒFile /sys/block/zram/stat”h]”hŒFile /sys/block/zram/stat”…”�”}”(hj¦ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhj4h²hubhÝ)�”}”(hŒQRepresents block layer statistics. Read Documentation/block/stat.rst for details.”h]”hŒQRepresents block layer statistics. Read Documentation/block/stat.rst for details.”…”�”}”(hj´ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhj4h²hubhÝ)�”}”(hŒ File /sys/block/zram/io_stat”h]”hŒ File /sys/block/zram/io_stat”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M hj4h²hubhÝ)�”}”(hŒÜThe stat file represents device's I/O statistics not accounted by block layer and, thus, not available in zram/stat file. It consists of a single line of text and contains the following stats separated by whitespace:”h]”hŒÞThe stat file represents device’s I/O statistics not accounted by block layer and, thus, not available in zram/stat file. It consists of a single line of text and contains the following stats separated by whitespace:”…”�”}”(hjÐ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M hj4h²hubhŒ block_quote”“”)�”}”(hX°============= ============================================================= failed_reads The number of failed reads failed_writes The number of failed writes invalid_io The number of non-page-size-aligned I/O requests notify_free Depending on device usage scenario it may account a) the number of pages freed because of swap slot free notifications b) the number of pages freed because of REQ_OP_DISCARD requests sent by bio. The former ones are sent to a swap block device when a swap slot is freed, which implies that this disk is being used as a swap disk. The latter ones are sent by filesystem mounted with discard option, whenever some data blocks are getting discarded. ============= ============================================================= ”h]”jü)�”}”(hhh]”j)�”}”(hhh]”(j)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K uh1jhjç ubj)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K=uh1jhjç ubj)�”}”(hhh]”(j!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ failed_reads”h]”hŒ failed_reads”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhj ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj ubj&)�”}”(hhh]”hÝ)�”}”(hŒThe number of failed reads”h]”hŒThe number of failed reads”…”�”}”(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Œ failed_writes”h]”hŒ failed_writes”…”�”}”(hj> h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhj; ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj8 ubj&)�”}”(hhh]”hÝ)�”}”(hŒThe number of failed writes”h]”hŒThe number of failed writes”…”�”}”(hjU h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MhjR ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj8 ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjþ ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ invalid_io”h]”hŒ invalid_io”…”�”}”(hju h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhjr ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjo ubj&)�”}”(hhh]”hÝ)�”}”(hŒ0The number of non-page-size-aligned I/O requests”h]”hŒ0The number of non-page-size-aligned I/O requests”…”�”}”(hjŒ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhj‰ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjo ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjþ ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ notify_free”h]”hŒ notify_free”…”�”}”(hj¬ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhj© ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj¦ ubj&)�”}”(hhh]”(hÝ)�”}”(hŒ1Depending on device usage scenario it may account”h]”hŒ1Depending on device usage scenario it may account”…”�”}”(hjà h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MhjÀ ubj")�”}”(hhh]”(j')�”}”(hŒAthe number of pages freed because of swap slot free notifications”h]”hÝ)�”}”(hŒAthe number of pages freed because of swap slot free notifications”h]”hŒAthe number of pages freed because of swap slot free notifications”…”�”}”(hjØ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MhjÔ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j&hjÑ ubj')�”}”(hŒÐthe number of pages freed because of REQ_OP_DISCARD requests sent by bio. The former ones are sent to a swap block device when a swap slot is freed, which implies that this disk is being used as a swap disk. ”h]”hÝ)�”}”(hŒÏthe number of pages freed because of REQ_OP_DISCARD requests sent by bio. The former ones are sent to a swap block device when a swap slot is freed, which implies that this disk is being used as a swap disk.”h]”hŒÏthe number of pages freed because of REQ_OP_DISCARD requests sent by bio. The former ones are sent to a swap block device when a swap slot is freed, which implies that this disk is being used as a swap disk.”…”�”}”(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&]”jsjtjuhjvjwuh1j!hjÀ ubhÝ)�”}”(hŒtThe latter ones are sent by filesystem mounted with discard option, whenever some data blocks are getting discarded.”h]”hŒtThe latter ones are sent by filesystem mounted with discard option, whenever some data blocks are getting discarded.”…”�”}”(hj h²hh³Nh´Nubah}”(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þ ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jhjç ubeh}”(h]”h ]”h"]”h$]”h&]”Œcols”Kuh1jhjä ubah}”(h]”h ]”h"]”h$]”h&]”uh1jûhjà ubah}”(h]”h ]”h"]”h$]”h&]”uh1jÞ h³hÊh´Mhj4h²hubhÝ)�”}”(hŒ File /sys/block/zram/mm_stat”h]”hŒ File /sys/block/zram/mm_stat”…”�”}”(hj= h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M$hj4h²hubhÝ)�”}”(hŒ–The mm_stat file represents the device's mm statistics. It consists of a single line of text and contains the following stats separated by whitespace:”h]”hŒ˜The mm_stat file represents the device’s mm statistics. It consists of a single line of text and contains the following stats separated by whitespace:”…”�”}”(hjK h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M&hj4h²hubjß )�”}”(hX‚================ ============================================================= orig_data_size uncompressed size of data stored in this disk. Unit: bytes compr_data_size compressed size of data stored in this disk mem_used_total the amount of memory allocated for this disk. This includes allocator fragmentation and metadata overhead, allocated for this disk. So, allocator space efficiency can be calculated using compr_data_size and this statistic. Unit: bytes mem_limit the maximum amount of memory ZRAM can use to store the compressed data mem_used_max the maximum amount of memory zram has consumed to store the data same_pages the number of same element filled pages written to this disk. No memory is allocated for such pages. pages_compacted the number of pages freed during compaction huge_pages the number of incompressible pages huge_pages_since the number of incompressible pages since zram set up ================ ============================================================= ”h]”jü)�”}”(hhh]”j)�”}”(hhh]”(j)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”Kuh1jhj` ubj)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K=uh1jhj` ubj)�”}”(hhh]”(j!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒorig_data_size”h]”hŒorig_data_size”…”�”}”(hj€ h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M*hj} ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjz ubj&)�”}”(hhh]”hÝ)�”}”(hŒ:uncompressed size of data stored in this disk. Unit: bytes”h]”hŒ:uncompressed size of data stored in this disk. Unit: bytes”…”�”}”(hj— h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M*hj” ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjz ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjw ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒcompr_data_size”h]”hŒcompr_data_size”…”�”}”(hj· h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M,hj´ ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj± ubj&)�”}”(hhh]”hÝ)�”}”(hŒ+compressed size of data stored in this disk”h]”hŒ+compressed size of data stored in this disk”…”�”}”(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 hjw ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒmem_used_total”h]”hŒmem_used_total”…”�”}”(hjî h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M-hjë ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjè ubj&)�”}”(hhh]”hÝ)�”}”(hŒêthe amount of memory allocated for this disk. This includes allocator fragmentation and metadata overhead, allocated for this disk. So, allocator space efficiency can be calculated using compr_data_size and this statistic. Unit: bytes”h]”hŒêthe amount of memory allocated for this disk. This includes allocator fragmentation and metadata overhead, allocated for this disk. So, allocator space efficiency can be calculated using compr_data_size and this statistic. Unit: bytes”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M-hjubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjè ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjw ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ mem_limit”h]”hŒ mem_limit”…”�”}”(hj%h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M2hj"ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjubj&)�”}”(hhh]”hÝ)�”}”(hŒFthe maximum amount of memory ZRAM can use to store the compressed data”h]”hŒFthe maximum amount of memory ZRAM can use to store the compressed data”…”�”}”(hj<h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M2hj9ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjw ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ mem_used_max”h]”hŒ mem_used_max”…”�”}”(hj\h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M4hjYubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjVubj&)�”}”(hhh]”hÝ)�”}”(hŒ@the maximum amount of memory zram has consumed to store the data”h]”hŒ@the maximum amount of memory zram has consumed to store the data”…”�”}”(hjsh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M4hjpubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjVubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjw ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ same_pages”h]”hŒ same_pages”…”�”}”(hj“h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M6hj�ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj�ubj&)�”}”(hhh]”hÝ)�”}”(hŒdthe number of same element filled pages written to this disk. No memory is allocated for such pages.”h]”hŒdthe number of same element filled pages written to this disk. No memory is allocated for such pages.”…”�”}”(hjªh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M6hj§ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj�ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjw ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒpages_compacted”h]”hŒpages_compacted”…”�”}”(hjÊh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M8hjÇubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÄubj&)�”}”(hhh]”hÝ)�”}”(hŒ+the number of pages freed during compaction”h]”hŒ+the number of pages freed during compaction”…”�”}”(hjáh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M8hjÞubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjÄubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjw ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ huge_pages”h]”hŒ huge_pages”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M9hjþubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjûubj&)�”}”(hhh]”hÝ)�”}”(hŒ"the number of incompressible pages”h]”hŒ"the number of incompressible pages”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M9hjubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjûubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjw ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒhuge_pages_since”h]”hŒhuge_pages_since”…”�”}”(hj8h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M:hj5ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj2ubj&)�”}”(hhh]”hÝ)�”}”(hŒ4the number of incompressible pages since zram set up”h]”hŒ4the number of incompressible pages since zram set up”…”�”}”(hjOh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M:hjLubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj2ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hjw ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jhj` ubeh}”(h]”h ]”h"]”h$]”h&]”Œcols”Kuh1jhj] ubah}”(h]”h ]”h"]”h$]”h&]”uh1jûhjY ubah}”(h]”h ]”h"]”h$]”h&]”uh1jÞ h³hÊh´M)hj4h²hubhÝ)�”}”(hŒ File /sys/block/zram/bd_stat”h]”hŒ File /sys/block/zram/bd_stat”…”�”}”(hj‚h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M=hj4h²hubhÝ)�”}”(hŒ The bd_stat file represents a device's backing device statistics. It consists of a single line of text and contains the following stats separated by whitespace:”h]”hŒ¢The bd_stat file represents a device’s backing device statistics. It consists of a single line of text and contains the following stats separated by whitespace:”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M?hj4h²hubjß )�”}”(hX˜============== ============================================================= bd_count size of data written in backing device. Unit: 4K bytes bd_reads the number of reads from backing device Unit: 4K bytes bd_writes the number of writes to backing device Unit: 4K bytes ============== ============================================================= ”h]”jü)�”}”(hhh]”j)�”}”(hhh]”(j)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”Kuh1jhj¥ubj)�”}”(hhh]”h}”(h]”h ]”h"]”h$]”h&]”Œcolwidth”K=uh1jhj¥ubj)�”}”(hhh]”(j!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒbd_count”h]”hŒbd_count”…”�”}”(hjÅh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MChjÂubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj¿ubj&)�”}”(hhh]”hÝ)�”}”(hŒ6size of data written in backing device. Unit: 4K bytes”h]”hŒ6size of data written in backing device. Unit: 4K bytes”…”�”}”(hjÜh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MChjÙubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj¿ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hj¼ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒbd_reads”h]”hŒbd_reads”…”�”}”(hjüh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MEhjùubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjöubj&)�”}”(hhh]”hÝ)�”}”(hŒ6the number of reads from backing device Unit: 4K bytes”h]”hŒ6the number of reads from backing device Unit: 4K bytes”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MEhjubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hjöubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hj¼ubj!)�”}”(hhh]”(j&)�”}”(hhh]”hÝ)�”}”(hŒ bd_writes”h]”hŒ bd_writes”…”�”}”(hj3h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MGhj0ubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj-ubj&)�”}”(hhh]”hÝ)�”}”(hŒ5the number of writes to backing device Unit: 4K bytes”h]”hŒ5the number of writes to backing device Unit: 4K bytes”…”�”}”(hjJh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MGhjGubah}”(h]”h ]”h"]”h$]”h&]”uh1j%hj-ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j hj¼ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jhj¥ubeh}”(h]”h ]”h"]”h$]”h&]”Œcols”Kuh1jhj¢ubah}”(h]”h ]”h"]”h$]”h&]”uh1jûhjžubah}”(h]”h ]”h"]”h$]”h&]”uh1jÞ h³hÊh´MBhj4h²hubeh}”(h]”Œstats”ah ]”h"]”Œstats”ah$]”h&]”uh1hµhh·h²hh³hÊh´Kæubh¶)�”}”(hhh]”(h»)�”}”(hŒ Deactivate”h]”hŒ Deactivate”…”�”}”(hjˆh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhj…h²hh³hÊh´MLubj")�”}”(hŒ$swapoff /dev/zram0 umount /dev/zram1”h]”hŒ$swapoff /dev/zram0 umount /dev/zram1”…”�”}”hj–sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´MPhj…h²hubeh}”(h]”Œ deactivate”ah ]”h"]”Œ deactivate”ah$]”h&]”uh1hµhh·h²hh³hÊh´MLubh¶)�”}”(hhh]”(h»)�”}”(hŒReset”h]”hŒReset”…”�”}”(hj¯h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhj¬h²hh³hÊh´MTubjß )�”}”(hXWrite any positive value to 'reset' sysfs node:: echo 1 > /sys/block/zram0/reset echo 1 > /sys/block/zram1/reset This frees all the memory allocated for the given device and resets the disksize to zero. You must set the disksize again before reusing the device. ”h]”(hÝ)�”}”(hŒ0Write any positive value to 'reset' sysfs node::”h]”hŒ3Write any positive value to ‘reset’ sysfs node:”…”�”}”(hjÁh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MVhj½ubj")�”}”(hŒ?echo 1 > /sys/block/zram0/reset echo 1 > /sys/block/zram1/reset”h]”hŒ?echo 1 > /sys/block/zram0/reset echo 1 > /sys/block/zram1/reset”…”�”}”hjÏsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´MXhj½ubhÝ)�”}”(hŒ”This frees all the memory allocated for the given device and resets the disksize to zero. You must set the disksize again before reusing the device.”h]”hŒ”This frees all the memory allocated for the given device and resets the disksize to zero. You must set the disksize again before reusing the device.”…”�”}”(hjÝh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M[hj½ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jÞ h³hÊh´MVhj¬h²hubeh}”(h]”Œreset”ah ]”h"]”Œreset”ah$]”h&]”uh1hµhh·h²hh³hÊh´MTubh¶)�”}”(hhh]”(h»)�”}”(hŒOptional Feature”h]”hŒOptional Feature”…”�”}”(hjüh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjùh²hh³hÊh´M`ubh¶)�”}”(hhh]”(h»)�”}”(hŒIDLE pages tracking”h]”hŒIDLE pages tracking”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhj h²hh³hÊh´McubhÝ)�”}”(hŒÜzram has built-in support for idle pages tracking (that is, allocated but not used pages). This feature is useful for e.g. zram writeback and recompression. In order to mark pages as idle, execute the following command::”h]”hŒÛzram has built-in support for idle pages tracking (that is, allocated but not used pages). This feature is useful for e.g. zram writeback and recompression. In order to mark pages as idle, execute the following command:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mehj h²hubj")�”}”(hŒ echo all > /sys/block/zramX/idle”h]”hŒ echo all > /sys/block/zramX/idle”…”�”}”hj)sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´Mihj h²hubhÝ)�”}”(hXDThis will mark all allocated zram pages as idle. The idle mark will be removed only when the page (block) is accessed (e.g. overwritten or freed). Additionally, when CONFIG_ZRAM_TRACK_ENTRY_ACTIME is enabled, pages can be marked as idle based on how many seconds have passed since the last access to a particular zram page::”h]”hXCThis will mark all allocated zram pages as idle. The idle mark will be removed only when the page (block) is accessed (e.g. overwritten or freed). Additionally, when CONFIG_ZRAM_TRACK_ENTRY_ACTIME is enabled, pages can be marked as idle based on how many seconds have passed since the last access to a particular zram page:”…”�”}”(hj7h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mkhj h²hubj")�”}”(hŒ"echo 86400 > /sys/block/zramX/idle”h]”hŒ"echo 86400 > /sys/block/zramX/idle”…”�”}”hjEsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´Mqhj h²hubhÝ)�”}”(hŒpIn this example, all pages which haven't been accessed in more than 86400 seconds (one day) will be marked idle.”h]”hŒrIn this example, all pages which haven’t been accessed in more than 86400 seconds (one day) will be marked idle.”…”�”}”(hjSh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mshj h²hubeh}”(h]”Œidle-pages-tracking”ah ]”h"]”Œidle pages tracking”ah$]”h&]”uh1hµhjùh²hh³hÊh´Mcubh¶)�”}”(hhh]”(h»)�”}”(hŒ writeback”h]”hŒ writeback”…”�”}”(hjlh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjih²hh³hÊh´MwubhÝ)�”}”(hŒµWith CONFIG_ZRAM_WRITEBACK, zram can write idle/incompressible page to backing storage rather than keeping it in memory. To use the feature, admin should set up backing device via::”h]”hŒ´With CONFIG_ZRAM_WRITEBACK, zram can write idle/incompressible page to backing storage rather than keeping it in memory. To use the feature, admin should set up backing device via:”…”�”}”(hjzh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Myhjih²hubj")�”}”(hŒ-echo /dev/sda5 > /sys/block/zramX/backing_dev”h]”hŒ-echo /dev/sda5 > /sys/block/zramX/backing_dev”…”�”}”hjˆsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M}hjih²hubhÝ)�”}”(hŒ�before disksize setting. It supports only partitions at this moment. If admin wants to use incompressible page writeback, they could do it via::”h]”hŒ�before disksize setting. It supports only partitions at this moment. If admin wants to use incompressible page writeback, they could do it via:”…”�”}”(hj–h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhjih²hubj")�”}”(hŒ&echo huge > /sys/block/zramX/writeback”h]”hŒ&echo huge > /sys/block/zramX/writeback”…”�”}”hj¤sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M‚hjih²hubhÝ)�”}”(hŒ?Admin can request writeback of idle pages at right timing via::”h]”hŒ>Admin can request writeback of idle pages at right timing via:”…”�”}”(hj²h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M„hjih²hubj")�”}”(hŒ&echo idle > /sys/block/zramX/writeback”h]”hŒ&echo idle > /sys/block/zramX/writeback”…”�”}”hjÀsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M†hjih²hubhÝ)�”}”(hŒLWith the command, zram will writeback idle pages from memory to the storage.”h]”hŒLWith the command, zram will writeback idle pages from memory to the storage.”…”�”}”(hjÎh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mˆhjih²hubhÝ)�”}”(hŒdAdditionally, if a user choose to writeback only huge and idle pages this can be accomplished with::”h]”hŒcAdditionally, if a user choose to writeback only huge and idle pages this can be accomplished with:”…”�”}”(hjÜh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MŠhjih²hubj")�”}”(hŒ+echo huge_idle > /sys/block/zramX/writeback”h]”hŒ+echo huge_idle > /sys/block/zramX/writeback”…”�”}”hjêsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M�hjih²hubhÝ)�”}”(hŒ…If a user chooses to writeback only incompressible pages (pages that none of algorithms can compress) this can be accomplished with::”h]”hŒ„If a user chooses to writeback only incompressible pages (pages that none of algorithms can compress) this can be accomplished with:”…”�”}”(hjøh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M�hjih²hubj")�”}”(hŒ0echo incompressible > /sys/block/zramX/writeback”h]”hŒ0echo incompressible > /sys/block/zramX/writeback”…”�”}”hjsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M’hjih²hubhÝ)�”}”(hŒƒIf an admin wants to write a specific page in zram device to the backing device, they could write a page index into the interface::”h]”hŒ‚If an admin wants to write a specific page in zram device to the backing device, they could write a page index into the interface:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M”hjih²hubj")�”}”(hŒ3echo "page_index=1251" > /sys/block/zramX/writeback”h]”hŒ3echo "page_index=1251" > /sys/block/zramX/writeback”…”�”}”hj"sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M—hjih²hubhÝ)�”}”(hX§In Linux 6.16 this interface underwent some rework. First, the interface now supports `key=value` format for all of its parameters (`type=huge_idle`, etc.) Second, the support for `page_indexes` was introduced, which specify `LOW-HIGH` range (or ranges) of pages to be written-back. This reduces the number of syscalls, but more importantly this enables optimal post-processing target selection strategy. Usage example::”h]”(hŒWIn Linux 6.16 this interface underwent some rework. First, the interface now supports ”…”�”}”(hj0h²hh³Nh´Nubj�)�”}”(hŒ `key=value`”h]”hŒ key=value”…”�”}”(hj8h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj0ubhŒ# format for all of its parameters (”…”�”}”(hj0h²hh³Nh´Nubj�)�”}”(hŒ`type=huge_idle`”h]”hŒtype=huge_idle”…”�”}”(hjJh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj0ubhŒ!, etc.) Second, the support for ”…”�”}”(hj0h²hh³Nh´Nubj�)�”}”(hŒ`page_indexes`”h]”hŒ page_indexes”…”�”}”(hj\h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj0ubhŒ was introduced, which specify ”…”�”}”(hj0h²hh³Nh´Nubj�)�”}”(hŒ `LOW-HIGH`”h]”hŒLOW-HIGH”…”�”}”(hjnh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj0ubhŒ¹ range (or ranges) of pages to be written-back. This reduces the number of syscalls, but more importantly this enables optimal post-processing target selection strategy. Usage example:”…”�”}”(hj0h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M™hjih²hubj")�”}”(hŒƒecho "type=idle" > /sys/block/zramX/writeback echo "page_indexes=1-100 page_indexes=200-300" > \ /sys/block/zramX/writeback”h]”hŒƒecho "type=idle" > /sys/block/zramX/writeback echo "page_indexes=1-100 page_indexes=200-300" > \ /sys/block/zramX/writeback”…”�”}”hj†sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M hjih²hubhÝ)�”}”(hŒbWe also now permit multiple page_index params per call and a mix of single pages and page ranges::”h]”hŒaWe also now permit multiple page_index params per call and a mix of single pages and page ranges:”…”�”}”(hj”h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M¤hjih²hubj")�”}”(hŒqecho page_index=42 page_index=99 page_indexes=100-200 \ page_indexes=500-700 > /sys/block/zramX/writeback”h]”hŒqecho page_index=42 page_index=99 page_indexes=100-200 \ page_indexes=500-700 > /sys/block/zramX/writeback”…”�”}”hj¢sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M§hjih²hubhÝ)�”}”(hŒ¾If there are lots of write IO with flash device, potentially, it has flash wearout problem so that admin needs to design write limitation to guarantee storage health for entire product life.”•édh]”hŒ¾If there are lots of write IO with flash device, potentially, it has flash wearout problem so that admin needs to design write limitation to guarantee storage health for entire product life.”…”�”}”(hj°h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mªhjih²hubhÝ)�”}”(hŒúTo overcome the concern, zram supports "writeback_limit" feature. The "writeback_limit_enable"'s default value is 0 so that it doesn't limit any writeback. IOW, if admin wants to apply writeback budget, they should enable writeback_limit_enable via::”h]”hXTo overcome the concern, zram supports “writeback_limitâ€� feature. The “writeback_limit_enable“‘s default value is 0 so that it doesn’t limit any writeback. IOW, if admin wants to apply writeback budget, they should enable writeback_limit_enable via:”…”�”}”(hj¾h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M®hjih²hubj")�”}”(hŒ2$ echo 1 > /sys/block/zramX/writeback_limit_enable”h]”hŒ2$ echo 1 > /sys/block/zramX/writeback_limit_enable”…”�”}”hjÌsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M³hjih²hubhÝ)�”}”(hŒ†Once writeback_limit_enable is set, zram doesn't allow any writeback until admin sets the budget via /sys/block/zramX/writeback_limit.”h]”hŒˆOnce writeback_limit_enable is set, zram doesn’t allow any writeback until admin sets the budget via /sys/block/zramX/writeback_limit.”…”�”}”(hjÚh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mµhjih²hubhÝ)�”}”(hŒ‡(If admin doesn't enable writeback_limit_enable, writeback_limit's value assigned via /sys/block/zramX/writeback_limit is meaningless.)”h]”hŒ‹(If admin doesn’t enable writeback_limit_enable, writeback_limit’s value assigned via /sys/block/zramX/writeback_limit is meaningless.)”…”�”}”(hjèh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M¸hjih²hubhÝ)�”}”(hŒPIf admin wants to limit writeback as per-day 400M, they could do it like below::”h]”hŒOIf admin wants to limit writeback as per-day 400M, they could do it like below:”…”�”}”(hjöh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M»hjih²hubj")�”}”(hŒ $ MB_SHIFT=20 $ 4K_SHIFT=12 $ echo $((400<>4K_SHIFT)) > \ /sys/block/zram0/writeback_limit. $ echo 1 > /sys/block/zram0/writeback_limit_enable”h]”hŒ $ MB_SHIFT=20 $ 4K_SHIFT=12 $ echo $((400<>4K_SHIFT)) > \ /sys/block/zram0/writeback_limit. $ echo 1 > /sys/block/zram0/writeback_limit_enable”…”�”}”hjsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M¾hjih²hubhÝ)�”}”(hŒgIf admins want to allow further write again once the budget is exhausted, they could do it like below::”h]”hŒfIf admins want to allow further write again once the budget is exhausted, they could do it like below:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MÄhjih²hubj")�”}”(hŒP$ echo $((400<>4K_SHIFT)) > \ /sys/block/zram0/writeback_limit”h]”hŒP$ echo $((400<>4K_SHIFT)) > \ /sys/block/zram0/writeback_limit”…”�”}”hj sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´MÇhjih²hubhÝ)�”}”(hŒHIf an admin wants to see the remaining writeback budget since last set::”h]”hŒGIf an admin wants to see the remaining writeback budget since last set:”…”�”}”(hj.h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MÊhjih²hubj")�”}”(hŒ&$ cat /sys/block/zramX/writeback_limit”h]”hŒ&$ cat /sys/block/zramX/writeback_limit”…”�”}”hj<sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´MÌhjih²hubhÝ)�”}”(hŒ=If an admin wants to disable writeback limit, they could do::”h]”hŒ /sys/block/zramX/writeback_limit_enable”h]”hŒ2$ echo 0 > /sys/block/zramX/writeback_limit_enable”…”�”}”hjXsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´MÐhjih²hubhÝ)�”}”(hŒøThe writeback_limit count will reset whenever you reset zram (e.g., system reboot, echo 1 > /sys/block/zramX/reset) so keeping how many of writeback happened until you reset the zram to allocate extra writeback budget in next setting is user's job.”h]”hŒúThe writeback_limit count will reset whenever you reset zram (e.g., system reboot, echo 1 > /sys/block/zramX/reset) so keeping how many of writeback happened until you reset the zram to allocate extra writeback budget in next setting is user’s job.”…”�”}”(hjfh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MÒhjih²hubhÝ)�”}”(hXŒBy default zram stores written back pages in decompressed (raw) form, which means that writeback operation involves decompression of the page before writing it to the backing device. This behavior can be changed by enabling `compressed_writeback` feature, which causes zram to write compressed pages to the backing device, thus avoiding decompression overhead. To enable this feature, execute::”h]”(hŒáBy default zram stores written back pages in decompressed (raw) form, which means that writeback operation involves decompression of the page before writing it to the backing device. This behavior can be changed by enabling ”…”�”}”(hjth²hh³Nh´Nubj�)�”}”(hŒ`compressed_writeback`”h]”hŒcompressed_writeback”…”�”}”(hj|h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjtubhŒ” feature, which causes zram to write compressed pages to the backing device, thus avoiding decompression overhead. To enable this feature, execute:”…”�”}”(hjth²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M×hjih²hubj")�”}”(hŒ2$ echo yes > /sys/block/zramX/compressed_writeback”h]”hŒ2$ echo yes > /sys/block/zramX/compressed_writeback”…”�”}”hj”sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´MÞhjih²hubhÝ)�”}”(hŒUNote that this feature should be configured before the `zramX` device is initialized.”h]”(hŒ7Note that this feature should be configured before the ”…”�”}”(hj¢h²hh³Nh´Nubj�)�”}”(hŒ`zramX`”h]”hŒzramX”…”�”}”(hjªh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj¢ubhŒ device is initialized.”…”�”}”(hj¢h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Màhjih²hubhÝ)�”}”(hX0Depending on backing device storage type, writeback operation may benefit from a higher number of in-flight write requests (batched writes). The number of maximum in-flight writeback operations can be configured via `writeback_batch_size` attribute. To change the default value (which is 32), execute::”h]”(hŒÙDepending on backing device storage type, writeback operation may benefit from a higher number of in-flight write requests (batched writes). The number of maximum in-flight writeback operations can be configured via ”…”�”}”(hjÂh²hh³Nh´Nubj�)�”}”(hŒ`writeback_batch_size`”h]”hŒwriteback_batch_size”…”�”}”(hjÊh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjÂubhŒ@ attribute. To change the default value (which is 32), execute:”…”�”}”(hjÂh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mãhjih²hubj")�”}”(hŒ1$ echo 64 > /sys/block/zramX/writeback_batch_size”h]”hŒ1$ echo 64 > /sys/block/zramX/writeback_batch_size”…”�”}”hjâsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´Méhjih²hubhÝ)�”}”(hŒ|If admin wants to measure writeback count in a certain period, they could know it via /sys/block/zram0/bd_stat's 3rd column.”h]”hŒ~If admin wants to measure writeback count in a certain period, they could know it via /sys/block/zram0/bd_stat’s 3rd column.”…”�”}”(hjðh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mëhjih²hubeh}”(h]”Œ writeback”ah ]”h"]”Œ writeback”ah$]”h&]”uh1hµhjùh²hh³hÊh´Mwubh¶)�”}”(hhh]”(h»)�”}”(hŒ recompression”h]”hŒ recompression”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhjh²hh³hÊh´MïubhÝ)�”}”(hX[With `CONFIG_ZRAM_MULTI_COMP`, zram can recompress pages using alternative (secondary) compression algorithms. The basic idea is that alternative compression algorithm can provide better compression ratio at a price of (potentially) slower compression/decompression speeds. Alternative compression algorithm can, for example, be more successful compressing huge pages (those that default algorithm failed to compress). Another application is idle pages recompression - pages that are cold and sit in the memory can be recompressed using more effective algorithm and, hence, reduce zsmalloc memory usage.”h]”(hŒWith ”…”�”}”(hjh²hh³Nh´Nubj�)�”}”(hŒ`CONFIG_ZRAM_MULTI_COMP`”h]”hŒCONFIG_ZRAM_MULTI_COMP”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjubhX>, zram can recompress pages using alternative (secondary) compression algorithms. The basic idea is that alternative compression algorithm can provide better compression ratio at a price of (potentially) slower compression/decompression speeds. Alternative compression algorithm can, for example, be more successful compressing huge pages (those that default algorithm failed to compress). Another application is idle pages recompression - pages that are cold and sit in the memory can be recompressed using more effective algorithm and, hence, reduce zsmalloc memory usage.”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mñhjh²hubhÝ)�”}”(hX With `CONFIG_ZRAM_MULTI_COMP`, zram supports up to 4 compression algorithms: one primary and up to 3 secondary ones. Primary zram compressor is explained in "3) Select compression algorithm", secondary algorithms are configured using recomp_algorithm device attribute.”h]”(hŒWith ”…”�”}”(hj7h²hh³Nh´Nubj�)�”}”(hŒ`CONFIG_ZRAM_MULTI_COMP`”h]”hŒCONFIG_ZRAM_MULTI_COMP”…”�”}”(hj?h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj7ubhŒó, zram supports up to 4 compression algorithms: one primary and up to 3 secondary ones. Primary zram compressor is explained in “3) Select compression algorithmâ€�, secondary algorithms are configured using recomp_algorithm device attribute.”…”�”}”(hj7h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Múhjh²hubhÝ)�”}”(hŒ Example:::”h]”hŒ Example::”…”�”}”(hjWh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mÿhjh²hubj")�”}”(hŒ�#show supported recompression algorithms cat /sys/block/zramX/recomp_algorithm #1: lzo lzo-rle lz4 lz4hc [zstd] #2: lzo lzo-rle lz4 [lz4hc] zstd”h]”hŒ�#show supported recompression algorithms cat /sys/block/zramX/recomp_algorithm #1: lzo lzo-rle lz4 lz4hc [zstd] #2: lzo lzo-rle lz4 [lz4hc] zstd”…”�”}”hjesbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´Mhjh²hubhÝ)�”}”(hX<Alternative compression algorithms are sorted by priority. In the example above, zstd is used as the first alternative algorithm, which has priority of 1, while lz4hc is configured as a compression algorithm with priority 2. Alternative compression algorithm's priority is provided during algorithms configuration:::”h]”hX=Alternative compression algorithms are sorted by priority. In the example above, zstd is used as the first alternative algorithm, which has priority of 1, while lz4hc is configured as a compression algorithm with priority 2. Alternative compression algorithm’s priority is provided during algorithms configuration::”…”�”}”(hjsh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhjh²hubj")�”}”(hŒè#select zstd recompression algorithm, priority 1 echo "algo=zstd priority=1" > /sys/block/zramX/recomp_algorithm #select deflate recompression algorithm, priority 2 echo "algo=deflate priority=2" > /sys/block/zramX/recomp_algorithm”h]”hŒè#select zstd recompression algorithm, priority 1 echo "algo=zstd priority=1" > /sys/block/zramX/recomp_algorithm #select deflate recompression algorithm, priority 2 echo "algo=deflate priority=2" > /sys/block/zramX/recomp_algorithm”…”�”}”hj�sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M hjh²hubhÝ)�”}”(hŒmAnother device attribute that `CONFIG_ZRAM_MULTI_COMP` enables is `recompress`, which controls recompression.”h]”(hŒAnother device attribute that ”…”�”}”(hj�h²hh³Nh´Nubj�)�”}”(hŒ`CONFIG_ZRAM_MULTI_COMP`”h]”hŒCONFIG_ZRAM_MULTI_COMP”…”�”}”(hj—h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj�ubhŒ enables is ”…”�”}”(hj�h²hh³Nh´Nubj�)�”}”(hŒ `recompress`”h]”hŒ recompress”…”�”}”(hj©h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhj�ubhŒ, which controls recompression.”…”�”}”(hj�h²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhjh²hubhÝ)�”}”(hŒ Examples:::”h]”hŒ Examples::”…”�”}”(hjÁh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mhjh²hubj")�”}”(hX`#IDLE pages recompression is activated by `idle` mode echo "type=idle priority=1" > /sys/block/zramX/recompress #HUGE pages recompression is activated by `huge` mode echo "type=huge priority=2" > /sys/block/zram0/recompress #HUGE_IDLE pages recompression is activated by `huge_idle` mode echo "type=huge_idle priority=1" > /sys/block/zramX/recompress”h]”hX`#IDLE pages recompression is activated by `idle` mode echo "type=idle priority=1" > /sys/block/zramX/recompress #HUGE pages recompression is activated by `huge` mode echo "type=huge priority=2" > /sys/block/zram0/recompress #HUGE_IDLE pages recompression is activated by `huge_idle` mode echo "type=huge_idle priority=1" > /sys/block/zramX/recompress”…”�”}”hjÏsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´Mhjh²hubhÝ)�”}”(hŒ³The number of idle pages can be significant, so user-space can pass a size threshold (in bytes) to the recompress knob: zram will recompress only pages of equal or greater size:::”h]”hŒ²The number of idle pages can be significant, so user-space can pass a size threshold (in bytes) to the recompress knob: zram will recompress only pages of equal or greater size::”…”�”}”(hjÝh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M hjh²hubj")�”}”(hŒí#recompress all pages larger than 3000 bytes echo "threshold=3000 priority=1" > /sys/block/zramX/recompress #recompress idle pages larger than 2000 bytes echo "type=idle threshold=2000 priority=1" > \ /sys/block/zramX/recompress”h]”hŒí#recompress all pages larger than 3000 bytes echo "threshold=3000 priority=1" > /sys/block/zramX/recompress #recompress idle pages larger than 2000 bytes echo "type=idle threshold=2000 priority=1" > \ /sys/block/zramX/recompress”…”�”}”hjësbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M$hjh²hubhÝ)�”}”(hŒbIt is also possible to limit the number of pages zram re-compression will attempt to recompress:::”h]”hŒaIt is also possible to limit the number of pages zram re-compression will attempt to recompress::”…”�”}”(hjùh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M+hjh²hubj")�”}”(hŒUecho "type=huge_idle priority=1 max_pages=42" > \ /sys/block/zramX/recompress”h]”hŒUecho "type=huge_idle priority=1 max_pages=42" > \ /sys/block/zramX/recompress”…”�”}”hjsbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´M.hjh²hubhÝ)�”}”(hX It is advised to always specify `priority` parameter. While it is also possible to specify `algo` parameter, so that `zram` will use algorithm's name to determine the priority, it is not recommended, since it can lead to unexpected results when the same algorithm is configured with different priorities (e.g. different parameters). `priority` is the only way to guarantee that the expected algorithm will be used.”h]”(hŒ It is advised to always specify ”…”�”}”(hjh²hh³Nh´Nubj�)�”}”(hŒ `priority`”h]”hŒpriority”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjubhŒ2 parameter. While it is also possible to specify ”…”�”}”(hjh²hh³Nh´Nubj�)�”}”(hŒ`algo`”h]”hŒalgo”…”�”}”(hj/h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjubhŒ parameter, so that ”…”�”}”(hjh²hh³Nh´Nubj�)�”}”(hŒ`zram`”h]”hŒzram”…”�”}”(hjAh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjubhŒÕ will use algorithm’s name to determine the priority, it is not recommended, since it can lead to unexpected results when the same algorithm is configured with different priorities (e.g. different parameters). ”…”�”}”(hjh²hh³Nh´Nubj�)�”}”(hŒ `priority`”h]”hŒpriority”…”�”}”(hjSh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jŽhjubhŒG is the only way to guarantee that the expected algorithm will be used.”…”�”}”(hjh²hh³Nh´Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M1hjh²hubeh}”(h]”Œ recompression”ah ]”h"]”Œ recompression”ah$]”h&]”uh1hµhjùh²hh³hÊh´Mïubeh}”(h]”Œoptional-feature”ah ]”h"]”Œoptional feature”ah$]”h&]”uh1hµhh·h²hh³hÊh´M`ubh¶)�”}”(hhh]”(h»)�”}”(hŒmemory tracking”h]”hŒmemory tracking”…”�”}”(hj~h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhj{h²hh³hÊh´M9ubhÝ)�”}”(hŒ¤With CONFIG_ZRAM_MEMORY_TRACKING, user can know information of the zram block. It could be useful to catch cold or incompressible pages of the process with*pagemap.”h]”hŒ¤With CONFIG_ZRAM_MEMORY_TRACKING, user can know information of the zram block. It could be useful to catch cold or incompressible pages of the process with*pagemap.”…”�”}”(hjŒh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M;hj{h²hubhÝ)�”}”(hŒ~If you enable the feature, you could see block state via /sys/kernel/debug/zram/zram0/block_state". The output is as follows::”h]”hŒIf you enable the feature, you could see block state via /sys/kernel/debug/zram/zram0/block_stateâ€�. The output is as follows:”…”�”}”(hjšh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M?hj{h²hubj")�”}”(hŒw300 75.033841 .wh... 301 63.806904 s..... 302 63.806919 ..hi.. 303 62.801919 ....r. 304 146.781902 ..hi.n”h]”hŒw300 75.033841 .wh... 301 63.806904 s..... 302 63.806919 ..hi.. 303 62.801919 ....r. 304 146.781902 ..hi.n”…”�”}”hj¨sbah}”(h]”h ]”h"]”h$]”h&]”j1j2uh1j!h³hÊh´MBhj{h²hubhŒdefinition_list”“”)�”}”(hhh]”(hŒdefinition_list_item”“”)�”}”(hŒ First column zram's block index.”h]”(hŒterm”“”)�”}”(hŒ First column”h]”hŒ First column”…”�”}”(hjÃh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÁh³hÊh´MHhj½ubhŒ definition”“”)�”}”(hhh]”hÝ)�”}”(hŒzram's block index.”h]”hŒzram’s block index.”…”�”}”(hjÖh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MIhjÓubah}”(h]”h ]”h"]”h$]”h&]”uh1jÑhj½ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j»h³hÊh´MHhj¸ubj¼)�”}”(hŒ5Second column access time since the system was booted”h]”(jÂ)�”}”(hŒ Second column”h]”hŒ Second column”…”�”}”(hjôh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÁh³hÊh´MJhjðubjÒ)�”}”(hhh]”hÝ)�”}”(hŒ'access time since the system was booted”h]”hŒ'access time since the system was booted”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MKhjubah}”(h]”h ]”h"]”h$]”h&]”uh1jÑhjðubeh}”(h]”h ]”h"]”h$]”h&]”uh1j»h³hÊh´MJhj¸h²hubj¼)�”}”(hXThird column state of the block: s: same page w: written page to backing store h: huge page i: idle page r: recompressed page (secondary compression algorithm) n: none (including secondary) of algorithms could compress it ”h]”(jÂ)�”}”(hŒ Third column”h]”hŒ Third column”…”�”}”(hj#h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÁh³hÊh´MZhjubjÒ)�”}”(hhh]”(hÝ)�”}”(hŒstate of the block:”h]”hŒstate of the block:”…”�”}”(hj4h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MMhj1ubj·)�”}”(hhh]”(j¼)�”}”(hŒ s: same page”h]”(jÂ)�”}”(hŒs:”h]”hŒs:”…”�”}”(hjIh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÁh³hÊh´MOhjEubjÒ)�”}”(hhh]”hÝ)�”}”(hŒ same page”h]”hŒ same page”…”�”}”(hjZh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MPhjWubah}”(h]”h ]”h"]”h$]”h&]”uh1jÑhjEubeh}”(h]”h ]”h"]”h$]”h&]”uh1j»h³hÊh´MOhjBubj¼)�”}”(hŒ w: written page to backing store”h]”(jÂ)�”}”(hŒw:”h]”hŒw:”…”�”}”(hjxh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÁh³hÊh´MQhjtubjÒ)�”}”(hhh]”hÝ)�”}”(hŒwritten page to backing store”h]”hŒwritten page to backing store”…”�”}”(hj‰h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MRhj†ubah}”(h]”h ]”h"]”h$]”h&]”uh1jÑhjtubeh}”(h]”h ]”h"]”h$]”h&]”uh1j»h³hÊh´MQhjBubj¼)�”}”(hŒ h: huge page”h]”(jÂ)�”}”(hŒh:”h]”hŒh:”…”�”}”(hj§h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÁh³hÊh´MShj£ubjÒ)�”}”(hhh]”hÝ)�”}”(hŒ huge page”h]”hŒ huge page”…”�”}”(hj¸h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MThjµubah}”(h]”h ]”h"]”h$]”h&]”uh1jÑhj£ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j»h³hÊh´MShjBubj¼)�”}”(hŒ i: idle page”h]”(jÂ)�”}”(hŒi:”h]”hŒi:”…”�”}”(hjÖh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÁh³hÊh´MUhjÒubjÒ)�”}”(hhh]”hÝ)�”}”(hŒ idle page”h]”hŒ idle page”…”�”}”(hjçh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MVhjäubah}”(h]”h ]”h"]”h$]”h&]”uh1jÑhjÒubeh}”(h]”h ]”h"]”h$]”h&]”uh1j»h³hÊh´MUhjBubj¼)�”}”(hŒ6r: recompressed page (secondary compression algorithm)”h]”(jÂ)�”}”(hŒr:”h]”hŒr:”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÁh³hÊh´MWhjubjÒ)�”}”(hhh]”hÝ)�”}”(hŒ3recompressed page (secondary compression algorithm)”h]”hŒ3recompressed page (secondary compression algorithm)”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MXhjubah}”(h]”h ]”h"]”h$]”h&]”uh1jÑhjubeh}”(h]”h ]”h"]”h$]”h&]”uh1j»h³hÊh´MWhjBubj¼)�”}”(hŒ>n: none (including secondary) of algorithms could compress it ”h]”(jÂ)�”}”(hŒn:”h]”hŒn:”…”�”}”(hj4h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jÁh³hÊh´MZhj0ubjÒ)�”}”(hhh]”hÝ)�”}”(hŒ:none (including secondary) of algorithms could compress it”h]”hŒ:none (including secondary) of algorithms could compress it”…”�”}”(hjEh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´MZhjBubah}”(h]”h ]”h"]”h$]”h&]”uh1jÑhj0ubeh}”(h]”h ]”h"]”h$]”h&]”uh1j»h³hÊh´MZhjBubeh}”(h]”h ]”h"]”h$]”h&]”uh1j¶hj1ubeh}”(h]”h ]”h"]”h$]”h&]”uh1jÑhjubeh}”(h]”h ]”h"]”h$]”h&]”uh1j»h³hÊh´MZhj¸h²hubeh}”(h]”h ]”h"]”h$]”h&]”uh1j¶hj{h²hh³hÊh´NubhÝ)�”}”(hŒÞFirst line of above example says 300th block is accessed at 75.033841sec and the block's state is huge so it is written back to the backing storage. It's a debugging feature so anyone shouldn't rely on it to work properly.”h]”hŒäFirst line of above example says 300th block is accessed at 75.033841sec and the block’s state is huge so it is written back to the backing storage. It’s a debugging feature so anyone shouldn’t rely on it to work properly.”…”�”}”(hjwh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´M\hj{h²hubhÝ)�”}”(hŒNitin Gupta ngupta@vflare.org”h]”(hŒ Nitin Gupta ”…”�”}”(hj…h²hh³Nh´NubjL)�”}”(hŒngupta@vflare.org”h]”hŒngupta@vflare.org”…”�”}”(hj�h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œmailto:ngupta@vflare.org”uh1jKhj…ubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÜh³hÊh´Mahj{h²hubeh}”(h]”Œmemory-tracking”ah ]”h"]”Œmemory tracking”ah$]”h&]”uh1hµhh·h²hh³hÊh´M9ubeh}”(h]”Œ'zram-compressed-ram-based-block-devices”ah ]”h"]”Œ(zram: compressed ram-based block devices”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”}”(j°j­hÿhüjËjÈjFjCj‰j†jìjéj%j"jhjej�jšjÄjÁj1j.j‚jj©j¦jöjójxjujfjcjjjpjmj¨j¥uŒ nametypes”}”(j°‰hÿ‰jˉjF‰j‰‰jì‰j%‰jh‰j�‰jĉj1‰j‚‰j©‰jö‰jx‰jf‰j‰jp‰j¨‰uh}”(j­h·hühËjÈjjCjÎj†jIjéjŒj"jïjej(jšjkjÁj j.jÇjj4j¦j…jój¬jujùjcj jjijmjj¥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”“”}”…”R”Œparse_messages”]”Œtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nh²hub.