diff options
author | Patrick J Volkerding <volkerdi@slackware.com> | 2024-05-28 18:08:19 +0000 |
---|---|---|
committer | Eric Hameleers <alien@slackware.com> | 2024-05-28 21:36:00 +0200 |
commit | bd0f6e74cb495743b6b39868d11437c1ca32d549 (patch) | |
tree | 03f681f3c1c78aca0489f8c9676bdf978fc3eec2 /source/installer | |
parent | 6602af83e2296cba3a6e204805b890d725d0f750 (diff) | |
download | current-bd0f6e74cb495743b6b39868d11437c1ca32d549.tar.gz current-bd0f6e74cb495743b6b39868d11437c1ca32d549.tar.xz |
Tue May 28 18:08:19 UTC 202420240528180819
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.
Diffstat (limited to 'source/installer')
-rw-r--r-- | source/installer/ChangeLog.txt | 6 | ||||
-rwxr-xr-x | source/installer/build_installer.sh | 1 | ||||
-rwxr-xr-x | source/installer/sources/initrd/etc/rc.d/rc.S | 21 | ||||
-rwxr-xr-x | source/installer/sources/initrd/usr/lib/setup/SeTpartitions | 77 |
4 files changed, 94 insertions, 11 deletions
diff --git a/source/installer/ChangeLog.txt b/source/installer/ChangeLog.txt index 88af5d041..cd0c305a0 100644 --- a/source/installer/ChangeLog.txt +++ b/source/installer/ChangeLog.txt @@ -1,3 +1,9 @@ +Tue May 28 17:53:49 UTC 2024 + 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. ++--------------------------+ Sat May 25 17:39:17 UTC 2024 Add zram.ko. +--------------------------+ diff --git a/source/installer/build_installer.sh b/source/installer/build_installer.sh index fb31963fc..20707f943 100755 --- a/source/installer/build_installer.sh +++ b/source/installer/build_installer.sh @@ -1184,6 +1184,7 @@ cp --remove-destination -fa${VERBOSE1} ${EXTRA_PKGS_SBIN} \ udev* \ umount \ xfs_repair \ + zramctl \ $PKG/$ARCH-installer-filesystem/sbin/ # This had dmsetup* above, which unnecessarily copies dmsetup.static # This had lvm* above, which unnecessarily copies lvm.static diff --git a/source/installer/sources/initrd/etc/rc.d/rc.S b/source/installer/sources/initrd/etc/rc.d/rc.S index 0e69d7349..c798c9d18 100755 --- a/source/installer/sources/initrd/etc/rc.d/rc.S +++ b/source/installer/sources/initrd/etc/rc.d/rc.S @@ -139,6 +139,27 @@ else fi # End Run udev: +# Set up some swap on a ZRAM device: +ZRAMSIZE=$(echo $(cat /proc/meminfo | grep ^MemTotal:) | cut -f 2 -d ' ') +ZRAMCOMPRESSION=zstd +ZRAMPRIORITY=100 +if [ ! -d /sys/devices/virtual/block/zram0 ]; then + modprobe zram +fi +# In case of a 32-bit kernel, we are limited to 4G maximum ZRAM device size. +# If the RAM 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 +ZRAM_DEVICE=$(/sbin/zramctl -f -a $ZRAMCOMPRESSION -s ${ZRAMSIZE}K) +if [ ! -z $ZRAM_DEVICE ]; then + /sbin/mkswap $ZRAM_DEVICE + /sbin/swapon -p $ZRAMPRIORITY $ZRAM_DEVICE +fi +unset ZRAMCOMPRESSION ZRAM_DEVICE ZRAMPRIORITY ZRAMSIZE + # Here's the situation. Because of the practice of keeping the local # time (rather than UTC) in the system's clock, at any given time half # of the people doing an install will be creating files that upon diff --git a/source/installer/sources/initrd/usr/lib/setup/SeTpartitions b/source/installer/sources/initrd/usr/lib/setup/SeTpartitions index 279edd94a..2a73ba5e5 100755 --- a/source/installer/sources/initrd/usr/lib/setup/SeTpartitions +++ b/source/installer/sources/initrd/usr/lib/setup/SeTpartitions @@ -35,6 +35,50 @@ Filesystem type: f2fs " 0 0 mkfs.f2fs -f $1 1> $REDIR 2> $REDIR } +# make_bcachefs( dev ) - Create a new bcachefs filesystem on the named dev. +# Parameters: dev Device node to format. +make_bcachefs() { + dialog --title "BCACHEFS COMPRESSION" --default-item "none" --menu \ + "Bcachefs supports on-the-fly compression/decompression to make the \ + most of your storage. If you'd like to use filesystem compression, \ + select one of the options below. Note that bcachefs has a lot of \ + options for compression, such as different levels, or compressing \ + in the background to eliminate write lag. These basic options will \ + get you going, though. Bcachefs filesystem options can be changed \ + later with \"bcachefs set-option\"." \ + 17 76 4 \ + "none" "Do not use filesystem compression" \ + "zstd" "Fast writes and very good compression ratio" \ + "lz4" "Very fast writes and good compression ratio" \ + "gzip" "Relatively useless, but be my guest" 2> $TMP/SeTcompress + if [ ! $? = 0 ]; then + rm -f $TMP/SeTcompress + exit + fi + if [ -r $TMP/SeTcompress ]; then + BCACHEFS_COMPRESSION="$(cat $TMP/SeTcompress)" + else + BCACHEFS_COMPRESSION=none + fi + # get the size of the named partition + SIZE=`get_part_size $1` + # output a nice status message + dialog --title "FORMATTING" \ + --backtitle "Formatting $1 with filesystem bcachefs, compression type $BCACHEFS_COMPRESSION." \ + --infobox "Formatting $1 \n\ +Size: $SIZE \n\ +Compression: $BCACHEFS_COMPRESSION \n\ +Filesystem type: bcachefs " 0 0 + # do the format + if mount | grep "$1 " 1> $NDIR 2> $NDIR ; then + umount $1 2> $NDIR + fi + mkfs.bcachefs -f --compression=$BCACHEFS_COMPRESSION $1 1> $REDIR 2> $REDIR + # mkfs.bcachefs is so ridiculously fast that we'd better pause for a moment + # or folks will wonder if the format failed + sleep 3 +} + # make_btrfs( dev ) - Create a new btrfs filesystem on the named dev. # Parameters: dev Device node to format. make_btrfs() { @@ -45,7 +89,7 @@ make_btrfs() { --backtitle "Formatting $1 with filesystem btrfs." \ --infobox "Formatting $1 \n\ Size: $SIZE \n\ -Filesystem type: btrfs " 0 0 +Filesystem type: btrfs " 0 0 # do the format if mount | grep "$1 " 1> $NDIR 2> $NDIR ; then umount $1 2> $NDIR @@ -65,7 +109,7 @@ make_ext2() { --backtitle "Formatting $1 with filesystem ext2." \ --infobox "Formatting $1 \n\ Size: $SIZE \n\ -Filesystem type: ext2" 0 0 +Filesystem type: ext2" 0 0 # do the format if mount | grep "$1 " 1> $NDIR 2> $NDIR ; then umount $1 2> $NDIR @@ -89,7 +133,7 @@ make_ext3() { --backtitle "Formatting $1 with filesystem ext3." \ --infobox "Formatting $1 \n\ Size: $SIZE \n\ -Filesystem type: ext3" 0 0 +Filesystem type: ext3" 0 0 # do the format if mount | grep "$1 " 1> $NDIR 2> $NDIR ; then umount $1 2> $NDIR @@ -113,7 +157,7 @@ make_ext4() { --backtitle "Formatting $1 with filesystem ext4." \ --infobox "Formatting $1 \n\ Size: $SIZE \n\ -Filesystem type: ext4" 0 0 +Filesystem type: ext4" 0 0 # do the format if mount | grep "$1 " 1> $NDIR 2> $NDIR ; then umount $1 2> $NDIR @@ -137,7 +181,7 @@ make_jfs() { --backtitle "Formatting $1 with filesystem jfs." \ --infobox "Formatting $1 \n\ Size: $SIZE \n\ -Filesystem type: jfs" 0 0 +Filesystem type: jfs" 0 0 # do the format if mount | grep "$1 " 1> $NDIR 2> $NDIR ; then umount $1 2> $NDIR @@ -159,7 +203,7 @@ make_reiserfs() { --backtitle "Formatting $1 with filesystem reiserfs." \ --infobox "Formatting $1 \n\ Size: $SIZE \n\ -Filesystem type: reiserfs " 0 0 +Filesystem type: reiserfs " 0 0 # do the format if mount | grep "$1 " 1> $NDIR 2> $NDIR ; then umount $1 2> $NDIR @@ -177,7 +221,7 @@ make_xfs() { --backtitle "Formatting $1 with filesystem xfs." \ --infobox "Formatting $1 \n\ Size: $SIZE \n\ -Filesystem type: xfs " 0 0 +Filesystem type: xfs " 0 0 # do the format if mount | grep "$1 " 1> $NDIR 2> $NDIR ; then umount $1 2> $NDIR @@ -238,7 +282,7 @@ to format this partition?" 12 70 3 \ # ask_fs( dev ) - Asks the user the type of filesystem to use for the named # device. Answer in $TMP/return ask_fs() { - unset BTRFS EXT2 EXT3 F2FS JFS REISERFS XFS + unset BCACHEFS BTRFS EXT2 EXT3 F2FS JFS REISERFS XFS if grep -wq ext2 /proc/filesystems 1> $NDIR 2> $NDIR ; then EXT2="Ext2 is the traditional Linux file system and is fast and stable. " fi @@ -250,8 +294,12 @@ ask_fs() { EXT4="Ext4 is the successor to the ext3 filesystem. " DEFAULT=ext4 fi - if grep -wq reiserfs /proc/filesystems 1> $NDIR 2> $NDIR ; then - REISERFS="ReiserFS is a journaling filesystem that stores all files and filenames in a balanced tree structure. " + # This will be gone in Linux 6.10, so it's probably time to quit offering it. + #if grep -wq reiserfs /proc/filesystems 1> $NDIR 2> $NDIR ; then + # REISERFS="ReiserFS is a journaling filesystem that stores all files and filenames in a balanced tree structure. " + #fi + if grep -wq bcachefs /proc/filesystems 1> $NDIR 2> $NDIR ; then + BCACHEFS="Bcachefs is a B-tree copy-on-write filesystem. " fi if grep -wq btrfs /proc/filesystems 1> $NDIR 2> $NDIR ; then BTRFS="Btrfs is a B-tree copy-on-write filesystem. " @@ -272,7 +320,7 @@ dialog --title "SELECT FILESYSTEM FOR $1" \\ --backtitle "Partition $1 will be formatted." \\ --default-item $DEFAULT --menu \\ "Please select the type of filesystem to use for the specified \\ -device. Here are descriptions of the available filesystems: $EXT2 $EXT3 $EXT4 $BTRFS $F2FS $JFS $REISERFS $XFS" \\ +device. Here are descriptions of the available filesystems: $EXT2 $EXT3 $EXT4 $BCACHEFS $BTRFS $F2FS $JFS $REISERFS $XFS" \\ 0 0 0 \\ EOF if [ ! "$EXT2" = "" ]; then @@ -290,6 +338,9 @@ EOF if [ ! "$REISERFS" = "" ]; then echo "\"reiserfs\" \"ReiserFS Journaling Filesystem\" \\" >> $TMP/tempscript fi + if [ ! "$BCACHEFS" = "" ]; then + echo "\"bcachefs\" \"Bcachefs Copy-on-Write B-tree Filesystem\" \\" >> $TMP/tempscript + fi if [ ! "$BTRFS" = "" ]; then echo "\"btrfs\" \"Btrfs Copy-on-Write B-tree Filesystem\" \\" >> $TMP/tempscript fi @@ -374,6 +425,8 @@ if [ ! "$DOFORMAT" = "No" ]; then fi elif [ "$ROOT_SYS_TYPE" = "reiserfs" ]; then make_reiserfs $ROOT_DEVICE + elif [ "$ROOT_SYS_TYPE" = "bcachefs" ]; then + make_bcachefs $ROOT_DEVICE elif [ "$ROOT_SYS_TYPE" = "btrfs" ]; then make_btrfs $ROOT_DEVICE elif [ "$ROOT_SYS_TYPE" = "f2fs" ]; then @@ -478,6 +531,8 @@ EOF fi elif [ "$NEXT_SYS_TYPE" = "reiserfs" ]; then make_reiserfs $NEXT_PARTITION + elif [ "$NEXT_SYS_TYPE" = "bcachefs" ]; then + make_bcachefs $NEXT_PARTITION elif [ "$NEXT_SYS_TYPE" = "btrfs" ]; then make_btrfs $NEXT_PARTITION elif [ "$NEXT_SYS_TYPE" = "f2fs" ]; then |