Script for creating hybrid swap space from zram swaps, swap files and swap partitions.
systemd-swap
is now completely rewritten in pythonsystemd-swap compression
lists available compression algorithms (#93)systemd-swap status
now works without root (some info requires root and are not displayed without sudo
)systemd-swap
can now swapon
virtblk disks (for use within VMs)This is a simple release containing the last fixups of the bash code before moving on to the python rewrite (#164), if there are requests to continue the bash version a 4.3.x branch will be created and maintained for the foreseeable future.
swapd_prio
(#169)4.3.1 did not actually fix this issue
dd
for all filesystems, fixing #155 when using swapFC on BTRFS/etc
swapfc_free_ram_perc
for setting the first swapfc file (other swapfc swap files are still managed by swapfc_free_swap_perc
)swapfc_priority
to 50 by default so that systemd doesn't log warning (#135)swapfc_frequency
is a valid integer, error otherwise (#121)swapon
for swap partitions found on /dev/sd*
and /dev/nvme*
.swapon
all zram devices (previously the first one would under certain circumstances not be made active).swapfc_path
so that snapshots work.Last release carried a regression causing zram
s size to be too large. (#134)
/etc/systemd/swap.conf.d/*.conf
/run/systemd/swap.conf.d/*.conf
/usr/lib/systemd/swap.conf.d/*.conf
/etc/systemd/swap.conf
/usr/share/systemd-swap/swap-default.conf
(With priority from top to bottom).swapfc_remove_free_swap_perc
Allows defining at what % of available ram we remove a swap file (defaluts to 55 which is the old value of swapfc_free_swap_perc
+ 40.swapfc_min_count
Just how you can define the maximum number of swap files created by swapfc, you can now define a minimum that will always be allocated (for instanse to restore the old behaviour of creating a swap file on startup set this to 1
). Defaults to 0
.swapfc_priority
Sets the priority of swap files created by swapfc (decreasing by one for every swap file created). Defaults to -2
(old default).5 swap.conf
and 8 systemd-swap
.Please read through them and send in grammar mistakes and anything you would like to be added :partying_face: .
type=notify
which should improve the output of systemctl status systemd-swap
.dd
instead of fallocate
if we're on ext4/3, f2fs or xfs (#109)chattr +C
on filesystems that don't support the flagIf you're running Ubuntu 18.04 or Centos 7 or older, please comment out line 25 in /usr/lib/systemd/system/systemd-swap.service
(see #118)