Hi, how many guys in endeavour os community uses zram ?
And to activate zram on endeavour os
Enable zram:
sudo pacman -S zram-generator
sudo touch /usr/lib/systemd/zram-generator.conf
sudo nano /usr/lib/systemd/zram-generator.conf
I use this configuration:
[zram0]
zram-fraction = 1.0
# Maximum is half of my usable RAM.
max-zram-size = 6144
compression-algorithm = zstd
Thanx
Are this steps are correct?
Am i missing something?
dalto
August 28, 2021, 2:40am
3
I use it on all my physical machines at this point.
Not exactly. First of all, there is no reason to touch a file before editing it.
You should setup the file at /etc/systemd/zram-generator.conf instead of using the location in /usr/lib
These days I am using 100% of ram up to 8GB.
sudo nano /etc/systemd/zram-generator.conf
Like this?
dalto
August 28, 2021, 2:44am
5
Sure. That is one way to do it.
Which way you had do this?
I am learning terminal, so i want to know
dalto
August 28, 2021, 2:47am
7
There are virtually an unlimited number of ways to edit and/or install a configuration file. Using sudo nano is a perfectly reasonable way.
I would use vi personally but I donât recommend that if you donât know how to use it.
And can you show us
Your zram configuration
It would be helpful for newbie like me
dalto
August 28, 2021, 2:51am
9
I could if I had access to that machine but I am not in front of it at the moment.
And to disable zswap,
Because it can cause problems with zRAM
Steps
cat /sys/module/zswap/parameters/enabled
an is Y then disable it
in the grub with
sudo nano /etc/default/grub
In the Nano editor, locate the line GRUB_CMDLINE_LINUX_DEFAULT . This line of code in the configuration file should have a few command-line arguments, such as âquiet splash,â and maybe a few others. Donât erase them! Instead, add the code below at the end of the line.
zswap.enabled=0
then
grub-mkconfig -o /boot/grub/grub.cfg
Are this steps are correct?
dalto
August 28, 2021, 2:56am
13
You shouldnât need to disable zswap. It shouldnât be used by default.
Where are you getting these instructions?
Link : https://wiki.archlinux.org/title/improving_performance#zram_or_zswap
arch wiki says we need to disable zswap,
zswap is enabled by default in endos
mbod
August 28, 2021, 5:51am
16
I didnt notice that. I am using zram but I have not disabled any zswap. Are you sure about the EndeavourOS default?
My /etc/systemd/zram-generator.conf is very simple:
[zram0]
max-zram-size = 12288
I am only specifying the amount of RAM. Thats it.
According to the Arch Wiki :
In the stable linux official kernel, zswap is enabled by default. This can be verified via the CONFIG_ZSWAP_DEFAULT_ON flag in the stable kernel config .
Yes it is enabled by default on enos
mbod
August 28, 2021, 7:02am
19
I missed that. Thank you. I am running zram since ages without disabling zswap. I will disable it now.