watch '( zramctl --output-all ; echo -e "\n\n" ; free -h ; echo -e "\n\n" ; swapon --show ; )' that will live update all the memory information on my Proxmox host. Here is a sample of the output: zramctl --output-all ; echo -e "\n\n" ; free -h ; echo -e "\n\n" ; swapon --show
NAME DISKSIZE DATA COMPR ALGORITHM STREAMS ZERO-PAGES TOTAL MEM-LIMIT MEM-USED MIGRATED COMP-RATIO MOUNTPOINT
/dev/zram0 4.6G 3G 791.4M zstd 4908 858.2M 0B 860.3M 12.1K 3.5291 [SWAP]
total used free shared buff/cache available
Mem: 7.7Gi 6.9Gi 357Mi 320Mi 1.2Gi 819Mi
Swap: 28Gi 3.2Gi 24Gi
NAME TYPE SIZE USED PRIO
/dev/sdb4 partition 23.6G 0B 10
/dev/zram0 partition 4.6G 3.2G 32767
root@pve:~# uptime
11:43:04 up 2 days, 8:35, 1 user, load average: 2.99, 3.01, 2.78
root@pve:~# uname -a
Linux pve 6.18.0-1-jaminmc-tcp-pve #1 SMP PREEMPT_DYNAMIC PMX 6.18.0-1 (2026-01-14T16:25Z) x86_64 GNU/Linux
I searched but I don't find a HowTo for Zswap on Proxmox.
apt install zram-tools was sufficient. That gave me:~# zramctl
NAME ALGORITHM DISKSIZE DATA COMPR TOTAL STREAMS MOUNTPOINT
/dev/zram0 lz4 23.5G 4K 64B 20K [SWAP]
/etc/default/zramswap which is probably NOT what you want. The above "23.5G" is for a system with 48 GiB Ram because of these defaults:~# grep -B 3 PERCENT /etc/default/zramswap
# Specifies the amount of RAM that should be used for zram
# based on a percentage the total amount of available memory
# This takes precedence and overrides SIZE below
PERCENT=50
zswap.enabled=1 to the kernel args or set the prop via a cronjob at boot or a service or however else you prefer.zramctl and zram-tools. Not sure why ZSWAP is lacking here.This isn't about zswap though, zswap and zram (although they serve a related but not completely identical usecase) are actually quite different things as explained in the references from Impact.Try to look into the wiki: https://pve.proxmox.com/wiki/Zram ;-)
Interesting, did not know that...Just addzswap.enabled=1to the kernel args
zswap.enabled=1 zswap.max_pool_percent=20 zswap.compressor=lz4 zswap.zpool=z3fold
z3fold is outdated/obsolete: https://www.phoronix.com/news/Linux-Z3fold-Removal-ComingWe use essential cookies to make this site work, and optional cookies to enhance your experience.