Skip to content

zeer goede uitleg : https://wiki.archlinux.org/title/swap

set swappiness = 10 (

  • no swap
  • swap , possible on :
    • a swap partition
    • a swap file
    • swap device in ram
      and/or possible in combination with using zswap or zram :
    • Zswap is a Linux kernel feature providing a compressed write-back cache for swapped pages,
    • ZRAM creates a virtual compressed swap block in memory as alternative to a swap partition/file on disk.
      Both approaches increase the swapping performance and decrease the disk I/O operations.

TODO

5 jaar linux : nog nooit meer als 4 GB swap gezien , de 16 GB swap partition is dus te groot
echter, the swap partition cannot be resized / moved with gparted, even when started with a life linux usb distro
? > delete swap in linux > start a life distro > delete patrtion > remake it with proper size > reset a swap in linux ?
misschien moet eerst een “swap” property op de part afgezet worden ?

zswap

https://www.addictivetips.com/ubuntu-linux-tips/enable-zswap-on-linux/
= kernel parameters => must be set using grub

# get root 
sudo -s
# make a backup of the Grub configuration file
cp  /etc/default/grub  /etc/default/grub.bak
# open grub config file for editing
nano -w /etc/default/grub
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=1`

# save  with **Ctrl + O** and exit with **Ctrl + X**. 
# updatie  Grub bootloader 
sudo update-grub
# reboot machine
customizing zswap

best custom instellen !
https://wiki.archlinux.org/title/zswap
max pool of pages , tresholds , etc

zram