From bfad32cbe95c4e4ff5bb46324d347b5bc81eaf0f Mon Sep 17 00:00:00 2001 From: Tobias Powalowski Date: Tue, 1 Aug 2023 14:28:00 +0200 Subject: [PATCH] increase rootfs size to 5G --- usr/lib/archboot/login.sh | 2 +- usr/lib/archboot/update/update.sh | 4 +--- usr/share/archboot/base/init | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/usr/lib/archboot/login.sh b/usr/lib/archboot/login.sh index 30e673aa9..c20746e05 100644 --- a/usr/lib/archboot/login.sh +++ b/usr/lib/archboot/login.sh @@ -50,7 +50,7 @@ if [[ "${TTY}" = "tty1" ]]; then modprobe zstd &>/dev/null echo "1" >/sys/block/zram0/reset echo "zstd" >/sys/block/zram0/comp_algorithm - echo "4G" >/sys/block/zram0/disksize + echo "5G" >/sys/block/zram0/disksize _progress "33" "Creating btrfs on /dev/zram0..." mkfs.btrfs /dev/zram0 &>/dev/null mount -o discard /dev/zram0 /sysroot &>/dev/null diff --git a/usr/lib/archboot/update/update.sh b/usr/lib/archboot/update/update.sh index 8108d36d1..c2bbf624f 100644 --- a/usr/lib/archboot/update/update.sh +++ b/usr/lib/archboot/update/update.sh @@ -523,13 +523,11 @@ _new_image() { _create_archboot_db "${_W_DIR}"/var/cache/pacman/pkg > "${_LOG}" # riscv64 does not support kexec at the moment if ! [[ "${_RUNNING_ARCH}" == "riscv64" ]]; then - # generate tarball in container, umount tmp it's a tmpfs and weird things could happen then # removing not working lvm2 from latest image _progress "35" "${_KEEP} Removing lvm2 from container..." ${_NSPAWN} "${_W_DIR}" pacman -Rdd lvm2 --noconfirm &>"${_NO_LOG}" - # generate latest tarball in container _progress "40" "${_KEEP} Generating local ISO..." - # generate local iso in container + # generate local iso in container, umount tmp it's a tmpfs and weird things could happen then ${_NSPAWN} "${_W_DIR}" /bin/bash -c "umount /tmp;rm -rf /tmp/*; archboot-${_RUNNING_ARCH}-iso.sh -g -p=${_PRESET_LOCAL} \ -i=${_ISONAME}-local-${_RUNNING_ARCH}" > "${_LOG}" || exit 1 rm -rf "${_W_DIR}"/var/cache/pacman/pkg/* diff --git a/usr/share/archboot/base/init b/usr/share/archboot/base/init index c0edbacf3..a7931c3d2 100755 --- a/usr/share/archboot/base/init +++ b/usr/share/archboot/base/init @@ -79,7 +79,7 @@ _second_stage() { rm -rf /lib/modules/*/kernel/drivers/{acpi,ata,gpu,bcma,block,bluetooth,hid,input,platform,net,scsi,soc,spi,usb,video} /lib/modules/*/extramodules _progress "66" "${_KEEP} Creating /dev/zram0 with zstd compression..." echo "zstd" >/sys/block/zram0/comp_algorithm - echo "4G" >/sys/block/zram0/disksize + echo "5G" >/sys/block/zram0/disksize _progress "67" "${_KEEP} Creating btrfs on /dev/zram0..." mkfs.btrfs /dev/zram0 &>/dev/null # use discard to get free RAM on delete!