Package Details: zramswap 5-1

Git Clone URL: https://aur.archlinux.org/zramswap.git (read-only, click to copy)
Package Base: zramswap
Description: Sets up zram-based swap devices on boot
Upstream URL: http://en.wikipedia.org/wiki/ZRam
Licenses: GPL
Submitter: svenstaro
Maintainer: rpodgorny
Last Packager: rpodgorny
Votes: 235
Popularity: 0.38
First Submitted: 2011-10-05 23:35 (UTC)
Last Updated: 2019-12-20 16:58 (UTC)

Required by (0)

Sources (3)

Latest Comments

« First ‹ Previous 1 2 3 4 5 6 7 8 9 10 11 12 .. 19 Next › Last »

melodie commented on 2014-05-21 22:39 (UTC)

Hi, This package is NOT zramswap: I have just seen my aur package manager submit an update for the zramswap program I have been using for such a long time, and I have been very surprised to read the description in the PKGBUILD: ********** pkgdesc="This is script for creating hybrid swap space from zram swaps, swap files and swap partitions. Swap file - auto create dinamic growing swap file and mount it via loop. For enable: sudo systemctl enable systemd-swap. Config in /etc/systemd-swap.cfg" ********** Whereas the description for the zramswap (version 1.1.1) which is installed into my system is: ********** "Description : Sets up zram-based swap devices on boot" ********** I am not saying that your systemd-swap program is not good, I don't know it, but I DISAGREE STRONGLY about the process that consists in providing it as if it were zramswap ITSELF : this seems to me very close to dishonest. :-( You program being also here: https://aur.archlinux.org/packages/sy/systemd-swap/ and the PKGBUILD: https://aur.archlinux.org/packages/sy/systemd-swap/PKGBUILD shows this different between the *present* zramswap and the one *systemd-swap*: diff = < pkgname=zramswap > pkgname=systemd-swap Here is what the **zramswap** script installed here does and which works a treat as we can see: ****************** $ cat /proc/swaps Filename Type Size Used Priority /dev/sda5 partition 4607996 0 -1 /dev/zram0 partition 506528 0 100 /dev/zram1 partition 506528 0 100 ******************* and here is the content of the script: ******************* $ cat /usr/lib/systemd/scripts/zramctrl #!/bin/sh start() { exec awk -v ZRAM_SIZE=$ZRAM_SIZE ' FILENAME == "/proc/cpuinfo" && ($1 == "processor" || $1 == "Processor") { cpucount++ next } FILENAME == "/proc/meminfo" && $1 == "MemTotal:" { if (ZRAM_SIZE == "") ZRAM_SIZE = 20 mem_total = int( (0 + $2) * 1024 * ( ZRAM_SIZE/100 ) ) next } END { mem_per_cpu = int(mem_total / cpucount) system("modprobe zram num_devices=" cpucount) for (i = 0; i < cpucount; i++) { print mem_per_cpu > "/sys/block/zram" i "/disksize" system("mkswap /dev/zram" i " -L zram" i) swapdevs = swapdevs " /dev/zram" i } system("swapon -p 100" swapdevs) } ' /proc/cpuinfo /proc/meminfo } stop() { exec awk ' FNR > 1 && $1 ~ /^\/dev\/zram[0-9]+$/ { activeswaps = activeswaps " " $1 } END { system("swapoff" activeswaps) system("rmmod zram") } ' /proc/swaps } case $1 in start|stop) "$1" ;; esac *********** and it's start file: *********** $ cat /usr/lib/systemd/scripts/zramctrl #!/bin/sh start() { exec awk -v ZRAM_SIZE=$ZRAM_SIZE ' FILENAME == "/proc/cpuinfo" && ($1 == "processor" || $1 == "Processor") { cpucount++ next } FILENAME == "/proc/meminfo" && $1 == "MemTotal:" { if (ZRAM_SIZE == "") ZRAM_SIZE = 20 mem_total = int( (0 + $2) * 1024 * ( ZRAM_SIZE/100 ) ) next } END { mem_per_cpu = int(mem_total / cpucount) system("modprobe zram num_devices=" cpucount) for (i = 0; i < cpucount; i++) { print mem_per_cpu > "/sys/block/zram" i "/disksize" system("mkswap /dev/zram" i " -L zram" i) swapdevs = swapdevs " /dev/zram" i } system("swapon -p 100" swapdevs) } ' /proc/cpuinfo /proc/meminfo } stop() { exec awk ' FNR > 1 && $1 ~ /^\/dev\/zram[0-9]+$/ { activeswaps = activeswaps " " $1 } END { system("swapoff" activeswaps) system("rmmod zram") } ' /proc/swaps } case $1 in start|stop) "$1" ;; esac ************ I would like it to stay that way, until it is itself in need of an update for any technical reason and I don't see any reason to change now. No freeze, no issue of any kind, on a fully up to date system. Please let systemd-swap be a new one and zramswap keep it's place! Thanks.

gourdcaptain commented on 2014-05-21 21:59 (UTC)

I might also note that systemd-swap's a bit more general purpose script and they may want to disable the other components in the config file. (I'm a guy using the zram swap for a overpowered netbook with 8 GB of RAM and a tiny SSD as a security margin in case I somehow run out of RAM, but I don't want actual swap because I don't want the wear and tear on the SSD.

Nefelim4ag commented on 2014-05-21 20:04 (UTC)

@thiagowfx Thanks, i add post install information.

thiagowfx commented on 2014-05-21 18:57 (UTC)

Hi, I just updated zramswap from 1.x to 2.x. Fortunately I come to this page to see the differences. I'd recommend you to add a post_install message so current users could see they should move to systemd-swap. Thanks!

Nefelim4ag commented on 2014-05-21 13:12 (UTC)

From now, this is duplicate of https://aur.archlinux.org/packages/systemd-swap/ package, for not leave users with orphan package (zramswap). Anybody, how read this, please install systemd-swap instead zramswap. Because zramswap is dead and be deleted from aur in few months.

Nefelim4ag commented on 2014-05-21 11:53 (UTC)

@orschiro Yes, systemd-swap cover zramswap functionally, also he full written on bash. Systemd-swap is combine for managing swap spaces.

orschiro commented on 2014-05-21 05:07 (UTC)

@Nefelim4ag Thanks, systemd-swap has more or less the same functionality as zramswap, correct?

Nefelim4ag commented on 2014-05-20 20:42 (UTC)

Try use https://aur.archlinux.org/packages/systemd-swap/