Skip to content

Instantly share code, notes, and snippets.

@denji
Last active July 24, 2022 22:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save denji/711446192aeb70717b477ffd87a38668 to your computer and use it in GitHub Desktop.
Save denji/711446192aeb70717b477ffd87a38668 to your computer and use it in GitHub Desktop.
Linux zSwap LZ4 (z3fold) sudo update-initramfs -k all -u / zram #lz4 #zstd #lz4hc #zbud #zsmalloc #z3fold #iot #router #embedded

/etc/default/grub

GRUB_CMDLINE_LINUX_DEFAULT="... zswap.enabled=1 zswap.compressor=lz4 zswap.max_pool_percent=20 zswap.zpool=z3fold"

/etc/initramfs-tools/modules (Linux zSwap lz4+z3fold)

# List of modules that you want to include in your initramfs.
# They will be loaded at boot time in the order below.
#
# Syntax:  module_name [args ...]
#
# You must run update-initramfs(8) to effect this change.
#
# Examples:
#
# raid1
# sd_mod
lz4
lz4_compress
# zstd
# zstd_compress
# lz4hc
# lz4hc_compress
# https://elinux.org/images/d/d3/Z3fold.pdf
z3fold

Linux zSwap LZ4 (z3fold) sudo update-initramfs -k all -u

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment