I just don’t understand why go through all that trouble? Why dont use zramctl?
devel-su
swapoff /dev/zram0
zramctl -s 6196888121 /dev/zram0
mkswap /dev/zram0
Setting up swapspace version 1, size = 5,8 GiB (6196887552 bytes)
no label, UUID=16e79d4e-8f13-4128-b5c0-32b438769ce6
swapon /dev/zram0
free -m
total used free shared buff/cache a
vailable
Mem: 5508 3042 1067 40 1399
2889
Swap: 5910 0 5910