archinstall/prep-BTRFS-UEFI.sh
2022-05-07 17:27:25 +00:00

47 lines
No EOL
1.4 KiB
Bash

# Vor Reboot
#localectl set-keymap de-latin1
#ip -c a
# rfkill unblock wifi
# iwctl
#pacman -Sy
#pacman -S tamsyn-font
#setfont Tamsyn10x20r
timedatectl set-ntp true
echo -n "o\ny\nyn\n\n\n+300M\nef00\nn\n\n\n\n\nw\ny\n" | gdisk /dev/vda #o\n y\n n\n \n \n +300m\n ef00\n n\n \n \n \n \n w\n y\n
#gdisk /dev/vda
# /dev/vda1 300M EFI
# /dev/vda2 Rest /
mkfs.vfat /dev/vda1 -n EFI
mkfs.btrfs /dev/vda2 -L arch
mount /dev/vda2 /mnt
cd /mnt
btrfs subvolume create @
btrfs subvolume create @home
btrfs subvolume create @var
btrfs subvolume create @log
btrfs subvolume create @cache
cd ~
umount -R /mnt
mount -o noatime,compress=zstd,space_cache=v2,discard=async,subvol=@ /dev/vda2 /mnt
mkdir -p /mnt/{home,boot,var}
mount -o noatime,compress=zstd,space_cache=v2,discard=async,subvol=@home /dev/vda2 /mnt/home
mount -o noatime,compress=zstd,space_cache=v2,discard=async,subvol=@var /dev/vda2 /mnt/var
mkdir -p /mnt/var/{cache,log}
mount -o noatime,compress=zstd,space_cache=v2,discard=async,subvol=@log /dev/vda2 /mnt/var/log
mount -o noatime,compress=zstd,space_cache=v2,discard=async,subvol=@cache /dev/vda2 /mnt/var/cache
mount /dev/vda1 /mnt/boot
pacstrap /mnt base linux linux-lts linux-firmware amd-ucode tamsyn-font vim git btrfs-progs
# discoverable-partitions-spec
genfstab -U /mnt >> /mnt/etc/fstab
ln -sf /run/systemd/resolve/stub-resolv.conf /mnt/etc/resolv.conf
arch-chroot /mnt