Installation
Installation Script
Create Live USB
fdisk -l
dd if=archlinux.iso of=/dev/sdX bs=4M status=progress
iwctl
[iwd] device list
[iwd] station wlan0 scan
[iwd] station wlan0 get-networks
[iwd] station wlan0 connect SSID
[iwd] exit
ip link
ping archlinux.org
Time
fdisk -l
fdisk /dev/sdX
g #gpt format
n #new partition
+512M
t #change to EFI system, select 1
n #new partition for ext4 system
# may need dosfstools, btrfs-progs
# for ext4 system
mkfs.fat -F32 /dev/sdX1
mkfs.ext4 /dev/sdX2
mount /dev/sdX2 /mnt
mkdir /mnt/boot
mount /dev/sdX1 /mnt/boot #mount esp to /boot;
## for btrfs system
# create btrfs system
mkfs.btrfs -L LABEL /dev/sdX2
#mount
mount -o compress=zstd /dev/sdX2 /mnt
# create subvolume
btrfs subvolume create /mnt/rootvol
#umount
umount /mnt
# remount
mount -o compress=zstd,subvol=rootvol /dev/sdX2 /mnt
# mount esp
mkdir /mnt/boot
mount /dev/sdX1 /mnt/boot
Install System
pacstrap /mnt base linux linux-firmware coreutils base-devel \
opendoas neovim networkmanager man-db man-pages
genfstab -U /mnt >> /mnt/etc/fstab # -U by UUID; -L by label
Chroot
arch-chroot /mnt
ln -sf /usr/share/zoneinfo/America/New_York /etc/localtime
hwclock --systohc
# Edit locale.gen and uncomment needed locales
EDITOR /etc/locale.gen
en_US.UTF-8 UTF-8
locale-gen
EDITOR /etc/locale.conf
LANG=en_US.UTF-8
EDITOR /etc/hostname
myhostname
EDITOR /etc/hosts
127.0.0.1 localhost
::1 localhost
127.0.1.1 myhostname.localdomain myhostname
password and user
passwd
useradd -m -G wheel username
passwd username
# EDITOR=vi visudo #uncomment wheel
echo "permit :wheel as root" >> /etc/doas.conf
bootloader - systemd-boot
#make sure esp is mounted at /boot
pacman -Syu intel-ucode # amd-ucode
bootctl install
EDITOR esp/loader/loader.conf #see systemd-boot
default arch.conf
timeout 3
console-mode max
editor no
auto-entries 0
blkid -s UUID -o value /dev/sdX2 # -s tag -o full/value/list
EDITOR esp/loader/entries/arch.conf #see systemd-boot
title Arch Linux
linux /vmlinuz-linux
initrd /intel-ucode.img #needs to be ahead of initramfs
initrd /initramfs-linux.img
options root=UUID=$(blkid -s UUID -o value /dev/sdX2) rootflags=subvol=rootvol rw # root partition UUDI or PARTUUID; rootflags for btrfs
bootctl list
pacman -Syu networkmanager
systemctl enable NetworkManager.service
nmtui #or use DE GUI
# iwd backend my be helpful in certain cases
pacman -S iwd
# /etc/NetworkManager/conf.d/iwd.conf
[device]
wifi.backend=iwd
pacman -Syu bluez bluez-utils
systemctl enable bluetooth.service
EDITOR /etc/bluetooth/main.conf
[Policy]
AutoEnable=true
pacman -Syu pulseaudio-bluetooth #for bluetooth audio
Install DE