This post will assume the following partition layout (UEFI installation):
/boot/EFI- UEFI grub,
/for system installation,
/homefor user files,
/datafor any other data. I usually keep all my development on this partition, so when I need to reinstall the system, I will not be formatting this partition.
lsblk to identify the partitions that you will need. In my case, since I only
have one hard drive it will be:
mkfs.fat -F32 /dev/sda1 -I mkfs.ext4 /dev/sda2 mkfs.ext4 /dev/sda3 mkfs.ext4 /dev/sda4
mount /dev/sda2 /mnt mkdir -p /mnt/home mkdir -p /mnt/data mount /dev/sda3 /mnt/home mount /dev/sda4 /mnt/data
Connect to the Internet
There are few ways of doing it, but the most convinient for me is to execute the below, and just choose the network and type in the password
I tend to use
vi to edit text files, but you can also use
uncomment the closest mirror to you, and save file.
Install the system
I also install
base-devel group, to include some additional packages
pacstrap /mnt base base-devel
Export partition table
We need to export the current partition table to
/etc/fstab so when we reboot, the
newely installed system can boot up. This will take the existing partition table and will append it to the system we just installed.
genfstab -U -p /mnt >> /mnt/etc/fstab
Chroot into new install
We need to chroot into new installation to setup some basics before we reboot.
Install basic packages
pacman -S grub efibootmgr linux-lts linux-lts-headers networkmanager linux-firmware
Uncheck the required locale based on your language, and save file.
Set LANG variable and UK keymap layout.
echo LANG=en_GB.UTF-8 > /etc/locale.conf echo KEYMAP=uk > /etc/vconsole.conf
ln -s /usr/share/zoneinfo/Europe/London /etc/localtime hwclock --systohc --utc
echo arch > /etc/hostname
Set root password
Install boot manager
mkdir /boot/EFI mount /dev/sda1 /boot/EFI grub-install --target=x86_64-efi --bootloader-id=grub_uefi --recheck
Install unicodes if you need to
pacman -S intel-ucode
Configure boot manager
grub-mkconfig -o /boot/grub/grub.cfg
We can now exit
chroot, unmount all partitions and reboot to our new installation.
exit umount -R /mnt reboot
In the following steps we will add system user and grant them with the administrative permissions.
Login as root (as it’s currently the only system user) and execute following commands, replacing
USERNAME with your actuall username:
useradd -m -G wheel,users -s /bin/bash USERNAME passwd USERNAME
This user was added to the
wheel group. We will now allow any users in that group to
perform any administrative system operations. Uncomment the following in
%wheel ALL=(ALL) NOPASSWD: ALL
Add 32-bit packages support
If you will be installing programs that will require 32-bit package versions like Steam, enable them
by uncommenting in
[multilib] Include = /etc/pacman.d/mirrorlist
Connect to the Internet
List available networks
nmcli device wifi list
Connect to the network
nmcli device wifi connect SSID password password
Update the system and enable 32-bit packages
At this point we have base installation complete. In next parts, we will install graphical environment i3