Lines Matching refs:zram
1 zram: Compressed RAM based block devices
6 The zram module creates RAM based block devices named /dev/zram<id>
12 Statistics for individual zram devices are exported through sysfs nodes at
13 /sys/block/zram<id>/
17 There are several ways to configure and manage zram device(-s):
18 a) using zram and zram_control sysfs attributes
21 In this document we will describe only 'manual' zram configuration steps,
22 IOW, zram and zram_control sysfs attributes.
26 that zram maintainers do not develop/maintain util-linux or zramctl, should
29 Following shows a typical sequence of steps for using zram.
36 zram sysfs attributes always return negative values in case of errors.
40 -ENOMEM -- zram was not able to allocate enough memory to fulfil your
55 modprobe zram num_devices=4
56 This creates 4 devices: /dev/zram{0,1,2,3}
58 num_devices parameter is optional and tells zram how many devices should be
110 There is little point creating a zram of greater than twice the size of memory
111 since we expect a 2:1 compression ratio. Note that zram uses about 0.1% of the
112 size of the disk when not in use so a huge zram is wasteful.
137 7) Add/remove zram devices
139 zram provides a control interface, which enables dynamic (on-demand) device
144 can use /dev/zram<id>) or error code.
147 cat /sys/class/zram-control/hot_add
152 echo X > /sys/class/zram-control/hot_remove
155 Per-device statistics are exported as various nodes under /sys/block/zram<id>/
158 read Documentation/ABI/testing/sysfs-block-zram.
178 mem_used_max RW the maximum amount of memory zram have consumed to
184 (available only via zram<id>/mm_stat node)
195 Documentation/ABI/obsolete/sysfs-block-zram
198 (e.g. num_reads) *AND* is accessible via one of the stat files (zram<id>/stat
199 or zram<id>/io_stat or zram<id>/mm_stat) is considered to be deprecated.
203 File /sys/block/zram<id>/stat
208 File /sys/block/zram<id>/io_stat
211 layer and, thus, not available in zram<id>/stat file. It consists of a
219 File /sys/block/zram<id>/mm_stat