How to install Arch Linux with UEFI.
Most distributions don’t need manual UEFI configuration as they have those GUI (graphical) installers, but Arch is a little different, therefore a short tutorial on using UEFI with Arch Linux.
Simple to follow UEFI installation video:
For the ones who already know what they are doing, a very short and very basic quick install. Assuming you already made your bootable USB drive with the Arch iso, follow below instructions, yes you have to configure much after the installation is complete.
After you’ve booted the installer:
# Disk is partitioned into 4 parts
# EFI directory 512MB
$ mkfs.vfat -F 32 /dev/sda1
# Create SWAP (size depending on your ram)
$ mkswap /dev/sda2 -L swapfs
# Root
$ mkfs.ext4 /dev/sda3 -L rootfs
# Home
$ mkfs.ext4 /dev/sda4 -L homefs
# Enable SWAP
$ swapon /dev/sda2
# Mount your partitions
$ mount /dev/sda3 /mnt
$ mkdir /mnt/home
$ mount /dev/sda4 /mnt/home
# Sync repo's first
$ pacman -Syy
$ pacstrap -i /mnt base base-devel linux efibootmgr grub #(any other package needed)
# When done continue with UEFI
$ mkdir /mnt/boot/esp
$ mount /dev/sda1 /mnt/boot/esp
# Chroot into installation
$ arch-chroot /mnt /bin/bash
#### install stuff (sudo vim etc etc)
#### uncomment # %wheel% in /etc/sudoers
# Set root password and create user
$ passwd (root password)
$ useradd -d /home/user-m -s /bin/bash user
$ usermod -aG wheel user
# Fix time
$ rm /etc/localtime
$ ln -s /usr/share/zoneinfo/Europe/Amsterdam /etc/localtime
$ hwlock --systohc --utc
# Fix locales
$ vi /etc/locale-gen
### uncomment en_US.UTF-8
$ locale-gen
$ echo "LANG=en_US.UTF-8" > /etc/locale.conf
# Create your ramdisk
$ mkinitcpio -p linux
# For dualboot only
$ pacman -S os-prober
### Move old GRUB directory to .bk ###### Don't touch: Windows and Boot directories
$ grub-install --target=x86_64-efi --efi-directory=esp --bootloader-id=GRUB
# Create your GRUB config
$ grub-mkconfig -o /boot/grub/grub.cfg
# exit chroot
$ exit
# Create your fstab file
$ genfstab -U /mnt > /mnt/etc/fstab
reboot
You should have a running installatin of Arch with UEFI setup at this point 🙂