I'm trying to enable LZ4 compression for zswap on Ubuntu 16.04.1 LTS.
My GRUB config:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash elevator=cfq profile zswap.enabled=1 zswap.compressor=lz4 zswap.max_pool_percent=80"
I executed sudo update-grub
, and rebooted. But, zswap says compressor lz4 not available, using default lzo
. I have liblz4-tool
installed. This is the message I get after executing dmesg | grep zswap
[ 0.000000] Command line: BOOT_IMAGE=/boot/vmlinuz-4.4.0-59-generic.efi.signed root=UUID=148a9e6d-52db-4678-b11d-ef1e5559b69d ro quiet splash elevator=cfq profile zswap.enabled=1 zswap.compressor=lz4 zswap.max_pool_percent=80 vt.handoff=7
[ 0.000000] Kernel command line: BOOT_IMAGE=/boot/vmlinuz-4.4.0-59-generic.efi.signed root=UUID=148a9e6d-52db-4678-b11d-ef1e5559b69d ro quiet splash elevator=cfq profile zswap.enabled=1 zswap.compressor=lz4 zswap.max_pool_percent=80 vt.handoff=7
[ 0.716485] zswap: compressor lz4 not available, using default lzo
[ 0.716493] zswap: loaded using pool lzo/zbud
I've found the solution in this Russian Debian Forum. I had to run these extra steps
And run
dmesg | grep -i zswap
, to seeExcited to see how the performance improves.
edit: I have written my steps in this guide. You can check if you face issues enabling zswap.