Page 1 of 1

Zram, how to enable? (in Manjaro/Arch-Porteus)

Posted: 25 Jan 2017, 12:03
by ElectriQT
Hi, long time since I was here, and the main reason for that:
The Porteus 3.5 Nemesis works so nice for me! With the frequent updates and all. :- )

(I have seen some small bugs since I started, had to change upower / pm-util,
needed to remove a symlink libcadec to be able to update,
but I did figure how to solve this problems by my self)

I am glad to see that the Arch-Manjaro-Porteus project still going on / restarted,
In my opinion this is the best one so far, almost bug free
I really like LXDE, and the automatic security updates in Manjaro-linux, and so on,
however.. there is some memory leak, probably in the html5 player or in Firefox.
Sometimes I have no HDD, but now it is installed on a very small HDD
I don't use any swap-partition, so then suddenly it can freeze the
system ..really hard.., Sometimes even the sysRq "R E I S U B" will not work,
A hard power off seems to be the only way if it really freezes everything before I can "killall firefox" :- /

Q. What is the correct method to enable Z-ram in this version?

I am almost new to Linux, so I am not 100% sure about how to do this,
I found some scripts here:
https://github.com/vaeth/zram-init

.

Re: Zram,how to enable?

Posted: 25 Jan 2017, 16:39
by Blaze
Try zram=25% in /mnt/sdb1/boot/syslinux/porteus.cfg

For example

LABEL GRAPHICAL section
....
APPEND initrd=initrd.xz changes=/porteus zram=25%

Cheers

Re: Zram,how to enable? (in Manjaro/Arch-Porteus)

Posted: 26 Jan 2017, 00:46
by ElectriQT
Blaze wrote: boot/syslinux/porteus.cfg
APPEND initrd=initrd.xz changes=/porteus zram=25%
-Nope,that did not work :- (

top (Htop) tells me: "Swp 0k/0k"

Maybe I need to shut of any running normal Harddrive-swap first?
[Edit: No, no difference. I tried swapon / swapoff -a ]



EDIT, I have the LXDE-version of Manjaro/Arch based PorteusNemesis3.5,
(I had no issues with Zram in the Slackwarebased Porteus)
All the latest updates from Manjaro installed with pacman update manager.)
EDIT, I Removed some redundant text. Moved a part of it to a second question about the Firewall.

Re: Zram, how to enable? (in Manjaro/Arch-Porteus)

Posted: 26 Jan 2017, 21:13
by normalGuy
Maybe cheatcode:
noswap

... Prevents the automatic use of an existing swap partition.
By default, Porteus searches your attached drives for
partitions that are formatted as swap, and will mount them
for use within Porteus. The 'noswap' cheatcode disables
this behaviour.
Works with me with arch in HD and porteus Usb.

Zram, how to enable? (in Manjaro/Arch-Porteus)

Posted: 02 Sep 2017, 23:59
by ElectriQT
http://www.techrapid.co.uk/2017/04/crea ... linux.html

works, (without sudo, I did it as root)

"zRam is a virtual memory compression using block devices named /dev/zram using a fast compression algorithm that compress the least recently used (LRU) or inactive space in the memory allows the GNU/Linux kernel to free up more memory with less performance hit.

zRam is greatly increasing the available amount of memory without swap disks/partition. It is recommended for user to use zRam instead of not use swap or swap on slow disks.
Create a zRam block devices
Load the zRam modules to the kernel using modprobe:

sudo modprobe zram

Set the zRam extremely fast compression algorithm using lz4:

sudo sh -c "echo 'lz4' > /sys/block/zram0/comp_algorithm"

Set 2 Gigabyte available zRam disk space for swap:

sudo sh -c "echo '2G' > /sys/block/zram0/disksize"

Create a swap on zRam block devices:

sudo mkswap --label zram0 /dev/zram0

Enable the zRam block devices for swapping with high priority:

sudo swapon --priority 100 /dev/zram0 "

Zram, how to enable? (in Manjaro/Arch-Porteus)

Posted: 07 Sep 2017, 16:03
by francois
So still using nemesis. :D Did you update to the most recent base modules updates by ncmprhnsbl, or are your running on your january installation? Are you using brokenman lxde modules or did you built your own on top of xorg from scratch.