rpi_zram icon indicating copy to clipboard operation
rpi_zram copied to clipboard

resolve issues with existing swap devices

Open DonThorntonJr opened this issue 8 years ago • 2 comments

per Ubuntu: https://askubuntu.com/questions/471912/zram-vs-zswap-vs-zcache-ultimate-guide-when-to-use-which-one

my solution was to turn off non-zram swap devices after initialization:

... swapon -p 5 /dev/zram3

swapon -s for i in $( swapon -s | awk 'NR>1 { print $1 }' | egrep -v zram ) ; do swapoff ${i} ; done swapon -s

DonThorntonJr avatar Jan 19 '17 00:01 DonThorntonJr

Existing swap is disabled before creating the ZRAM swap in PR #3 - I tested your code first but it didn't work. I just took a different approach and instead turned off existing swap before enabling ZRAM.

Cat5TV avatar Feb 05 '18 17:02 Cat5TV

there wasn't any problem with novas code for my rpi 3b+ it automatically disabled the existing swap before creating the new one

dcpender avatar Jan 09 '19 00:01 dcpender