Package Details: zramswap 5-1

Git Clone URL: (read-only, click to copy)
Package Base: zramswap
Description: Sets up zram-based swap devices on boot
Upstream URL:
Licenses: GPL
Submitter: Svenstaro
Maintainer: rpodgorny
Last Packager: rpodgorny
Votes: 230
Popularity: 1.55
First Submitted: 2011-10-05 23:35
Last Updated: 2019-12-20 16:58

Required by (0)

Sources (3)

Latest Comments

« First ‹ Previous 1 2 3 4 5 6 7 ... Next › Last »

stuartiannaylor commented on 2019-05-06 19:37

Still does strange things like create multiple devices when zram is multi-stream by default.

Doesn't check for existing zram services and so will overwrite.

Also omits the mem_limit cap to control actual memory usage.

Irrespective of alg its still out of date.

Freso commented on 2019-05-06 19:32

I mean, if it hadn’t been changed to specifically use the non-default compression algorithm, upgrading the kernel to 5.1+ would automatically have made lzo-rle what was used by default… I don’t think the script should hardcode the compression method. If people want to use lz4, they can make it do so themselves. Trust that the kernel devs make informed decisions on what compression to use by default?

papakilo commented on 2019-05-06 13:56


I have changed your config and I'm already trying lzo-rle with kernel 5.1:

$ cat /sys/block/zram0/comp_algorithm lzo [lzo-rle] lz4 lz4hc 842 zstd

$ zramctl NAME ALGORITHM DISKSIZE DATA COMPR TOTAL STREAMS MOUNTPOINT /dev/zram1 lzo-rle 480,6M 4K 79B 12K 2 [SWAP] /dev/zram0 lzo-rle 480,6M 4K 79B 12K 2 [SWAP]

Now I'm testing if really faster than lz4...

papakilo commented on 2019-05-06 13:25

Hi rpodgorny,

as you asked me to advise you, Linux kernel 5.1 is finally available.

So now that lzo-rle compression is also available (, will you apply it to zramswap?

rpodgorny commented on 2019-03-15 13:47

bump me when 5.1 is out. also, please remove the package deletion request. thank you...

papakilo commented on 2019-03-15 08:34

Hi there, now that lzo-rle compression will be available (, will you apply it to zramswap? Bye, thanks.

stuartiannaylor commented on 2019-03-14 13:48

Its great that you have made a package for Arch problem is you have used zram-config-0.5.deb as a basis.

Afraid much of what you are doing like creating devices per core whilst zram is multi-stream by default is purely through the Chinese bad whispers of the above package. You use the pointless num_devices which is optional and don't check if any exist say for the likes of log2ram. Zram is a hotplug system like zramctl --find find a free device I have been on a rant to Ubuntu about how a package such as the above has passed so many release when it is practically broken in every way and somehow manages to encourage so many copies.

Read the kernel doc and you find there is little correlation. You can check my repo out which prob needs pollish but at least is relatively correct.

Read the bugs and my questions on what is obviously your source.

PS log2ram is also great and if your updating packages and maybe in the mood have a look at.

Needs a config script as disk_size, mem_limit and the choice of any comp alg from /proc/crypto is far to wide a choice to be hard wired.

I have noticed that there is little difference on some distribs between lzo & lz4 and thinking it might be down to binary optimisation and in many cases where this is used if NEON optimisation has been implemented in compile. lz4 should be much faster but seems in use much less than expected with raspian that is. Prob Arch haven't checked lz4 should be a clear winner.

jaab commented on 2018-04-13 10:46

Works like a charm for small arm devices. Thank you!

duffydack commented on 2018-03-19 00:13

/dev/zram{0-7} lz4 199.2M 4K 68B 4K 8 [SWAP]

Excellent, thank you.

rpodgorny commented on 2018-03-18 23:56

updated. please test.