increase rootfs size to 5G

This commit is contained in:
Tobias Powalowski 2023-08-01 14:28:00 +02:00
parent d789ce6000
commit bfad32cbe9
3 changed files with 3 additions and 5 deletions

View file

@ -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

View file

@ -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/*

View file

@ -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!