Introduction: The Arch Linux Philosophy
Arch Linux represents a distinct approach to Linux distribution. It is not pre-configured with defaults and aims to provide a lightweight, flexible, and user-centric operating system. The philosophy behind Arch is “Keep It Simple, Stupid” (KISS), which translates into a minimalist base system that the user builds upon to suit their exact needs. This makes it an excellent choice for those who want complete control over their environment, a deep understanding of their system, and the ability to tailor it for specific tasks, whether it be a powerful development workstation, a lean server, or a customized desktop experience.

This guide will walk you through the process of installing Arch Linux from scratch. It is designed for users who are comfortable with the command line and are eager to learn the inner workings of a Linux system. While it may seem daunting at first, the process is methodical and highly rewarding.
Prerequisites and Preparation
Before embarking on the Arch Linux installation, ensure you have the following in hand.
System Requirements
Arch Linux is known for its minimal resource requirements. However, to ensure a smooth installation and a functional system, consider these general guidelines:
- Architecture: A modern x86-64 processor.
- RAM: At least 512 MB is recommended for basic installation, but 1 GB or more is highly advisable for a graphical environment and general use.
- Storage: A minimum of 10 GB of free disk space. More is recommended depending on your intended use and the software you plan to install.
- Bootable Installation Medium: A USB drive or DVD containing the Arch Linux installation image.
- Internet Connection: A stable internet connection is crucial for downloading packages during the installation process.
Downloading the Arch Linux ISO
The first step is to obtain the latest Arch Linux installation image.
- Visit the Official Arch Linux Download Page: Navigate to the official Arch Linux download page (https://archlinux.org/download/).
- Choose a Mirror: You will find a list of download mirrors around the world. Select a mirror geographically close to you for faster download speeds.
- Download the ISO: Download the
.isofile for the latest release.
Creating a Bootable USB Drive
Once you have the ISO image, you need to write it to a USB drive to create a bootable installation medium.
For Linux Users:
The dd command is a powerful and straightforward way to achieve this.
- Identify your USB drive: Insert your USB drive and use a command like
lsblkorsudo fdisk -lto identify its device name (e.g.,/dev/sdX, whereXis the drive letter). Be extremely careful to select the correct device, as writing to the wrong drive can erase all its data. - Unmount the USB drive (if mounted):
bash
sudo umount /dev/sdX*
Replace/dev/sdXwith your USB drive’s device name. - Write the ISO to the USB drive:
bash
sudo dd bs=4M if=/path/to/archlinux-*.iso of=/dev/sdX status=progress oflag=sync
Replace/path/to/archlinux-*.isowith the actual path to your downloaded ISO file, and/dev/sdXwith your USB drive’s device name. Thebs=4Moption specifies a block size of 4 megabytes for faster writing,status=progressshows the writing progress, andoflag=syncensures data is physically written to the drive.
For Windows Users:
Tools like Rufus or balenaEtcher can be used to create bootable USB drives.
- Download Rufus: Get Rufus from its official website.
- Launch Rufus: Open Rufus and select your USB drive.
- Select the ISO: Click “Select” and choose the downloaded Arch Linux ISO file.
- Start the process: Click “Start” and confirm any prompts. Rufus will warn you that all data on the USB drive will be destroyed.
Booting from the Installation Medium
After creating the bootable USB drive, you need to configure your computer’s BIOS/UEFI to boot from it.
- Restart your computer: Insert the bootable USB drive and restart your computer.
- Enter BIOS/UEFI settings: Immediately upon startup, press the key to enter your system’s BIOS or UEFI settings. This key is usually displayed on the screen during boot and commonly is
Del,F2,F10,F12, orEsc. Consult your motherboard or computer manufacturer’s documentation if unsure. - Change boot order: Navigate to the “Boot” or “Boot Order” section. Prioritize booting from your USB drive.
- Save and Exit: Save your changes and exit the BIOS/UEFI setup. Your computer should now boot into the Arch Linux live environment.
The Arch Linux Installation Process
Once you have successfully booted into the Arch Linux live environment, you will be presented with a command-line prompt. This is where the installation begins.
Initial Setup and Network Configuration
The first steps involve ensuring your system is ready and connected to the internet.
-
Verify Boot Mode:
Arch Linux can be installed in either UEFI or BIOS mode. Check which mode your system is using:ls /sys/firmware/efi/efivarsIf this command shows files, you are in UEFI mode. If it returns an error or an empty directory, you are likely in BIOS mode. This is important for partitioning and bootloader installation.
-
Set Keyboard Layout (Optional but Recommended):
To ensure your keyboard layout is correct, especially if it’s not US English:loadkeys usReplace
uswith your desired layout (e.g.,gbfor British English). -
Connect to the Internet:
Arch Linux installation requires an internet connection to download packages.-
Wired Connection (Ethernet): If you have a wired connection, it should automatically be detected. You can verify your IP address with:
ip link dhcpcdThe
dhcpcdcommand will try to obtain an IP address for your network interface. -
Wireless Connection (Wi-Fi): For wireless connections, you’ll need to use the
iwctlutility.
bash
iwctl
[iwd]# device list
[iwd]# station <device_name> scan
[iwd]# station <device_name> get-networks
[iwd]# station <device_name> connect <SSID>
Replace<device_name>with your Wi-Fi adapter (e.g.,wlan0),<SSID>with your Wi-Fi network name. You will be prompted for your Wi-Fi password.
-
-
Update the System Clock:
Ensure your system’s clock is accurate, which is important for package verification.
bash
timedatectl set-ntp true
timedatectl status
Disk Partitioning
This is a critical step where you define how your hard drive will be used. The method of partitioning depends on whether you are using UEFI or BIOS mode.
UEFI System Partitioning
For UEFI systems, you’ll typically need at least three partitions:
- EFI System Partition (ESP): This partition is essential for booting UEFI systems. It should be formatted as FAT32 and is usually mounted at
/boot. A size of 300-500 MB is generally sufficient. - Root Partition (
/): This is where the main Arch Linux system will be installed. You can choose the size based on your needs; 20-30 GB is a reasonable starting point. - Swap Partition (Optional but Recommended): A swap partition acts as virtual RAM. A common recommendation is to set it equal to or double your physical RAM, though modern systems with ample RAM may need less.
BIOS System Partitioning
For BIOS systems, you typically need:
- Root Partition (
/): Similar to UEFI, this is where the system is installed. - Swap Partition (Optional but Recommended): Similar to UEFI, for virtual RAM.
- Home Partition (
/home) (Optional but Recommended): Separating/homeallows you to reinstall the system without losing your personal files.
Using fdisk or parted
We’ll use fdisk for this guide, as it’s widely used and straightforward. Replace /dev/sdX with your target drive (e.g., /dev/sda, /dev/nvme0n1).
-
Launch
fdisk:fdisk /dev/sdX -
Create Partitions:
-
For UEFI:
gto create a new GPT partition table (for UEFI).nto create a new partition.- Press Enter to accept defaults for partition number, first sector, and last sector (for ESP, adjust size to ~500M).
- Enter
ef00as the partition type for the ESP. nto create the root partition. Accept defaults for partition number, first sector. For the last sector, specify a size (e.g.,+30G).nto create the swap partition. Accept defaults for partition number, first sector. For the last sector, specify a size (e.g.,+4G).tto change partition type. Select the swap partition number and enter8200.wto write changes and exit.
-
For BIOS:
oto create a new MBR partition table (for BIOS).nto create a new partition (primary). Accept defaults for partition number, first sector. Specify size (e.g.,+30G) for root.nto create a new partition (primary or logical for swap). Accept defaults for partition number, first sector. Specify size (e.g.,+4G) for swap.tto change partition type. Select the swap partition number and enter82.wto write changes and exit.
-
-
Format Partitions:
- EFI System Partition (if applicable):
bash
mkfs.fat -F 32 /dev/sdX1
- Root Partition:
bash
mkfs.ext4 /dev/sdX2
(Replace/dev/sdX2with your root partition, e.g.,/dev/sda2) - Swap Partition:
bash
mkswap /dev/sdX3
(Replace/dev/sdX3with your swap partition, e.g.,/dev/sda3)
bash
swapon /dev/sdX3
- EFI System Partition (if applicable):
Mounting Partitions
Now, mount the newly formatted partitions to the live environment’s file system.
-
Mount the Root Partition:
mount /dev/sdX2 /mnt(Replace
/dev/sdX2with your root partition) -
Create and Mount EFI System Partition (if applicable):
bash
mkdir /mnt/boot
mount /dev/sdX1 /mnt/boot
(Replace/dev/sdX1with your EFI partition)
Installing Essential Packages

The pacstrap script is used to install the base Arch Linux system and other essential packages onto your mounted root partition.
-
Install Base System and Text Editor:
pacstrap /mnt base linux linux-firmware nanobase: The essential Arch Linux packages.linux: The Linux kernel.linux-firmware: Firmware required by various hardware components.nano: A simple text editor for configuration files. You can replacenanowith your preferred editor, such asvim.
-
Generate
fstab:
This file defines how partitions are mounted at boot.
bash
genfstab -U /mnt >> /mnt/etc/fstab
Verify the contents of/mnt/etc/fstabto ensure it looks correct.
System Configuration
With the base system installed, you need to configure it to your liking.
Chrooting into the New System
To make changes to the installed system, you need to change the root directory to /mnt.
arch-chroot /mnt
You are now operating within your newly installed Arch Linux environment.
Time Zone Configuration
Set your system’s time zone.
- List available time zones:
bash
ls /usr/share/zoneinfo/
- Set your time zone:
bash
ln -sf /usr/share/zoneinfo/Region/City /etc/localtime
For example:ln -sf /usr/share/zoneinfo/Europe/London /etc/localtime - Synchronize the hardware clock:
bash
hwclock --systohc
Localization
Configure your system’s language settings.
-
Edit
locale.gen:
Open/etc/locale.genwith your text editor (e.g.,nano /etc/locale.gen). Uncomment the lines for your desired locales. For example, to enable English (US) and English (United Kingdom):en_US.UTF-8 UTF-8 en_GB.UTF-8 UTF-8 -
Generate Locales:
locale-gen -
Create
locale.conf:
Set the default system locale.
bash
echo "LANG=en_US.UTF-8" > /etc/locale.conf
(Replaceen_US.UTF-8with your preferred locale)
Hostname
Set the hostname for your computer.
-
Edit
hostnamefile:echo "myarchlinux" > /etc/hostnameReplace
"myarchlinux"with your desired hostname. -
Configure
hostsfile:
Edit/etc/hostsand add the following lines:
127.0.0.1 localhost
::1 localhost
127.0.1.1 myarchlinux.localdomain myarchlinux
Replacemyarchlinux.localdomainandmyarchlinuxwith your actual hostname.
Root Password
Set a strong password for the root user.
passwd
You will be prompted to enter and confirm the root password.
Bootloader Installation
A bootloader is necessary to boot your Arch Linux system. GRUB is a popular and robust choice.
For UEFI Systems (GRUB)
-
Install GRUB and EFI support:
pacman -S grub efibootmgr -
Install GRUB to the EFI partition:
grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=ArchLinux--efi-directory=/boot: Specifies the directory where the EFI System Partition is mounted.--bootloader-id=ArchLinux: A unique identifier for your Arch Linux boot entry.
-
Generate GRUB configuration file:
bash
grub-mkconfig -o /boot/grub/grub.cfg
For BIOS Systems (GRUB)
-
Install GRUB:
pacman -S grub -
Install GRUB to the Master Boot Record (MBR):
grub-install /dev/sdXReplace
/dev/sdXwith your boot drive (e.g.,/dev/sda). Do not specify a partition number here. -
Generate GRUB configuration file:
bash
grub-mkconfig -o /boot/grub/grub.cfg
Additional User Creation (Recommended)
It’s best practice to create a regular user account for daily use, rather than always operating as root.
-
Add a new user:
useradd -m -G wheel usernameReplace
usernamewith your desired username. The-mflag creates a home directory, and-G wheeladds the user to thewheelgroup, which is often used for administrative privileges. -
Set password for the new user:
passwd username -
Configure
sudo:
To allow your new user to execute commands with root privileges, you need to configuresudo.- Install
sudo:
bash
pacman -S sudo
- Edit the
sudoersfile:
bash
visudo
Uncomment the line%wheel ALL=(ALL:ALL) ALLto allow members of thewheelgroup to usesudo. Save and exit.
- Install
Installing a Desktop Environment (Optional)
If you want a graphical user interface, you’ll need to install a desktop environment and a display manager. Here’s an example for GNOME:
-
Install GNOME and a display manager (GDM):
pacman -S gnome gdm -
Enable GDM:
systemctl enable gdm -
Other Desktop Environments: You can choose other popular desktop environments like KDE Plasma (
plasma kde-applications), XFCE (xfce4 xfce4-goodies), or LXQt (lxqt). Remember to enable their respective display managers (e.g.,sddmfor KDE,lightdmfor XFCE/LXQt).
Finalizing the Installation and Rebooting
Once all configuration steps are complete, you are ready to exit the chroot environment and reboot your system.
-
Exit chroot:
exit -
Unmount partitions:
umount -R /mnt -
Reboot:
bash
reboot
Remove the installation medium (USB drive) when prompted or as your computer restarts.

Post-Installation Steps
Upon booting into your new Arch Linux system, you’ll likely be greeted by a login prompt (or the graphical login manager if you installed a desktop environment).
- Login: Log in as the regular user you created.
- Update System: It’s always a good practice to update your system after installation:
bash
sudo pacman -Syu
- Install Additional Software: Now you can install any other applications you need using
pacman. For example:
bash
sudo pacman -S firefox vlc git
Congratulations, you have successfully installed Arch Linux! This provides a solid foundation for a highly customized and efficient operating system. The Arch Wiki (https://wiki.archlinux.org/) is an invaluable resource for further customization and troubleshooting.
