mirror of
git://slackware.nl/current.git
synced 2024-12-28 09:59:53 +01:00
bd0f6e74cb
a/sysvinit-scripts-15.1-noarch-17.txz: Rebuilt. rc.S: enable swapping on a ZRAM device, configurable in /etc/default/zram. rc.S, rc.6: Don't use mount -n option. l/adwaita-icon-theme-46.2-noarch-1.txz: Upgraded. l/adwaita-icon-theme-legacy-20240517_7642b10-noarch-1.txz: Added. Thanks to reddog83. l/enchant-2.8.0-x86_64-1.txz: Upgraded. l/ffmpeg-6.1.1-x86_64-3.txz: Rebuilt. Patched to fix AV1 VA-API dropping frames. Thanks to fulalas. l/python-zipp-3.19.0-x86_64-1.txz: Upgraded. xap/mozilla-firefox-126.0.1-x86_64-1.txz: Upgraded. This is a bugfix release. For more information, see: https://www.mozilla.org/en-US/firefox/126.0.1/releasenotes/ isolinux/initrd.img: Rebuilt. Add /sbin/zramctl. rc.S: Set up some swap on a ZRAM device. SeTpartitions: Support installing to bcachefs filesystems. SeTpartitions: quit offering reiserfs which will be gone in Linux 6.10. usb-and-pxe-installers/usbboot.img: Rebuilt. Add /sbin/zramctl. rc.S: Set up some swap on a ZRAM device. SeTpartitions: Support installing to bcachefs filesystems. SeTpartitions: quit offering reiserfs which will be gone in Linux 6.10.
34 lines
1.1 KiB
Text
34 lines
1.1 KiB
Text
# Should we use swap on ZRAM?
|
|
ZRAM_ENABLE=1
|
|
|
|
# Total system RAM, in KB:
|
|
MEMTOTAL=$(echo $(cat /proc/meminfo | grep ^MemTotal:) | cut -f 2 -d ' ')
|
|
|
|
# ZRAM device size. We'll make this the same size as the system RAM.
|
|
# Assuming 1:4 compression, this would (if filled) occupy 1/4 of the system
|
|
# RAM. Until pages are swapped to ZRAM, the device occupies almost no RAM.
|
|
# As far as what's optimal here, I've heard all kinds of theories. So maybe
|
|
# you want to set this to twice the system RAM. Or half. Or something else
|
|
# entirely.
|
|
ZRAMSIZE=$MEMTOTAL
|
|
|
|
# In case of a 32-bit kernel, we are limited to 4G maximum ZRAM device size.
|
|
# If ZRAMSIZE size is greater than 4G, then use 4G for the ZRAMSIZE.
|
|
if [ "$(uname -m)" = "i686" ]; then
|
|
if [ "$ZRAMSIZE" -gt "4194304" ]; then
|
|
ZRAMSIZE=4194304
|
|
fi
|
|
fi
|
|
|
|
# Number of ZRAM devices. We are only going to use one of them, so there's no
|
|
# need to increase this unless you'll be needing additional ZRAM devices for
|
|
# other purposes.
|
|
ZRAMNUMBER=1
|
|
|
|
# Set the compression algorithm.
|
|
# Use zstd for best results.
|
|
# Nothing else makes any sense.
|
|
ZRAMCOMPRESSION=zstd
|
|
|
|
# Set the swap priority for the ZRAM device:
|
|
ZRAMPRIORITY=100
|