Triaxx Web Log

Arch Linux

Installation

Boot image

curl --output archlinux-x86_64.iso https://mirror.srv.fail/archlinux/iso/2026.03.01/archlinux-x86_64.iso
# on macOS
sudo dd if=archlinux-x86_64.iso of=/dev/disk4 bs=1m status=progress
# on NetBSD
dd if=/home/triaxx/archlinux-x86_64.iso of=/dev/sd2d bs=1m progress=100

System configuration

After booting from USB disk:

localectl list-keymaps | grep fi
loadkeys fi
timedatectl set-timezone Europe/Helsinki

Partitionning

Erase table or filesystem signatures:

wipefs --all /dev/sda

Create empty partition table:

echo 'label: gpt' | sfdisk /dev/sda

List available types for GPT:

sfdisk --label gpt --list-types

Create partitions:

echo "size=512MiB, name=efi, type=efi-system" | sfdisk /dev/sda
echo "size=512MiB, name=boot, type=linux-extended-boot" | sfdisk /dev/sda --append
echo "size=36GiB, name=linux-swap, type=linux-swap" | sfdisk /dev/sda --append
echo "size=128GiB, name=linux-root, type=linux-root-x86-64" | sfdisk /dev/sda --append
echo "size=36GiB, name=freebsd-swap, type=freebsd-swap" | sfdisk /dev/sda --append
echo "size=128GiB, name=freebsd-root, type=freebsd-ufs" | sfdisk /dev/sda --append
echo "size=+, name=data, type=freebsd-zfs" | sfdisk /dev/sda --append

Make filesystems:

mkfs.fat -F 32 /dev/sda1
mkfs.ext4 /dev/sda2
mkswap /dev/sda3
mkfs.ext4 /dev/sda4

Mount filesystems:

mount /dev/sda4 /mnt
mount --mkdir /dev/sda1 /mnt/efi
mount --mkdir /dev/sda2 /mnt/boot
swapon /dev/sda3

Packages

pacstrap -K /mnt base base-devel linux linux-firmware

Post-configuration

genfstab -U /mnt >> /mnt/etc/fstab
arch-chroot /mnt
pacman -Sy dhcpcd man-db vim

Localization

ln -sf /usr/share/zoneinfo/Europe/Helsinki /etc/localtime
hwclock --systohc

After editing /etc/locale.gen:

locale-gen
echo "LANG=fi_FI.UTF-8" > /etc/locale.conf
echo "KEYMAP=fi" > /etc/vconsole.conf
mkinitcpio -P

Network

echo "foobar" > /etc/hostname
systemctl enable dhcpcd@enp0s3

Users

Change the root password:

passwd

Create a unprivileged user (default group is users and default shell is bash, cf. /etc/default/useradd):

useradd -G wheel -m triaxx
passwd triaxx

Boot loader

bootctl install
cat > /boot/loader/entries/arch.conf << EOF
title      Arch Linux
linux      /vmlinuz-linux
initrd     /initramfs-linux.img
options    root=UUID=de8b50da-ee4f-1305-b885-7c7a10c23cfa rw video=1680x1050
EOF
bootctl update

Packages

Search regular expression from repository:

pacman -Ss <re>

Install package :

pacman -Sy <pkg>

Update installed packages:

pacman -Suy

List files of installed package :

pacman -Ql <pkg>

Remove package and all its dependencies:

pacman -Rs <pkg>

AUR

Install yay:

git clone https://aur.archlinux.org/yay.git
cd yay
makepkg -si

Search regular expression from AUR:

yay -Ss <re>

Install package from AUR:

yay -S <pkg>
Tags: