Whether you’re a seasoned Linux user or a newbie looking to dive deep into the world of how to install arch Linux, this tutorial is here to help you get the job done. Arch Linux is one of the most powerful and flexible Linux distributions available. It’s well-known for its simplicity, rolling release model, and the Arch Way—a philosophy that focuses on user control and minimalism. However, the installation process can be a bit intimidating, especially for beginners.
In this guide, we will walk you through how to install Arch Linux from scratch, using the command line interface. Whether you’re installing it on a physical machine or setting up a virtual machine (like VirtualBox), this article provides clear and detailed instructions to help you successfully set up Arch Linux. We’ll also discuss dual boot configurations with other operating systems, such as Windows, to help you get started.
Why Choose Arch Linux?
Before jumping into the installation process, it’s essential to understand why Arch Linux has become a favorite among developers and experienced users.
- Minimalism and Customization: Arch Linux comes with only the essential tools, leaving everything else up to the user. This allows for greater customization and learning.
- Rolling Release: Arch Linux doesn’t follow traditional release cycles. Instead, it features a rolling release model, which means you always have access to the latest software without needing to wait for new versions.
- Learning Experience: Installing Arch from scratch is a learning experience that can deepen your understanding of Linux and system administration.
- Community Support: The Arch Wiki is one of the most comprehensive resources available for Linux users, providing step-by-step guides for almost any task you can imagine.
Prerequisites: What You’ll Need
Before diving into the installation process, here’s a quick checklist of what you’ll need:
- A Computer or Virtual Machine: This could be a physical machine or a virtual machine (like VirtualBox).
- Internet Connection: An internet connection is required to download packages and updates during the installation process.
- Arch Linux ISO File: Download the latest Arch Linux ISO from the official Arch website: https://www.archlinux.org/download/.
- USB Drive or Virtual Machine Setup: If installing on a physical machine, create a bootable USB drive. Alternatively, use a virtual machine like VirtualBox.

How to Install Arch Linux from the Command Line?
1. Boot From the Arch Linux Installation Media
Start by booting your computer or virtual machine from the Arch Linux ISO.
- Physical Machine: Create a bootable USB drive using tools like Rufus (for Windows) or Etcher (for Linux/macOS), then boot from the USB drive.
- Virtual Machine: Set up a new virtual machine in VirtualBox, attach the ISO file, and boot from it.
Once booted, you’ll be presented with a command-line interface (CLI). Arch Linux doesn’t have a graphical installer like other distros, so you’ll need to use the terminal for all setup steps.
2. Set the Keyboard Layout
The default keyboard layout may not match your region. You can list available layouts by running:
ls /usr/share/kbd/keymaps/i386/qwerty/
To change the keyboard layout, use the following command:
loadkeys <layout>
For example, to switch to the US keyboard layout, type:
loadkeys us
3. Connect to the Internet
If you’re using a wired connection, Arch should automatically connect to the internet. To verify, use the ping
command:
ping archlinux.org
If you’re using Wi-Fi, you’ll need to connect manually. First, identify your network interface by running:
iw dev
Then, use the wifi-menu
tool (for network management) to connect:
wifi-menu
Follow the on-screen instructions to select your Wi-Fi network and enter your password.
4. Update the System Clock
Next, synchronize the system clock with the internet. This is crucial for avoiding time-related issues during installation.
timedatectl set-ntp true
5. Partition the Disk
The next step involves partitioning your disk. If you’re installing Arch Linux alongside another operating system, make sure to shrink the existing partitions using a tool like GParted before proceeding.
Use the fdisk
tool to partition your disk:
fdisk /dev/sda
Here’s a basic example of partitioning a disk:
/dev/sda1
: Boot partition (e.g., 512MB)/dev/sda2
: Main partition (remaining space)
To create partitions, follow these steps inside the fdisk
prompt:
- Type
n
to create a new partition. - Type
w
to write changes.
6. Format the Partitions
Once you’ve created your partitions, you need to format them. The most common file system for Linux is ext4.
For the boot partition:
mkfs.ext4 /dev/sda1
For the root partition:
mkfs.ext4 /dev/sda2
7. Mount the Partitions
Now, mount the root partition to the /mnt
directory:
mount /dev/sda2 /mnt
Create a mount point for the boot partition and mount it:
mkdir /mnt/boot
mount /dev/sda1 /mnt/boot
8. Install Arch Linux Base System
Arch Linux uses the pacstrap tool to install the base system. Run the following command to install essential packages:
pacstrap /mnt base linux linux-firmware vim
9. Configure the System
Now it’s time to configure your system. First, generate the fstab file, which helps the system identify and mount partitions on boot:
genfstab -U /mnt >> /mnt/etc/fstab
Chroot into the newly installed system:
arch-chroot /mnt
10. Set the Time Zone
Set the correct time zone for your location:
ln -sf /usr/share/zoneinfo/Region/City /etc/localtime
Replace Region/City with your actual time zone, e.g., America/New_York. Then, synchronize the hardware clock:
hwclock --systohc
11. Localization
Edit the /etc/locale.gen file to enable your desired locale (for example, en_US.UTF-8
):
vim /etc/locale.gen
Uncomment the line for en_US.UTF-8
. Then generate the locale:
locale-gen
Set the locale:
echo LANG=en_US.UTF-8 > /etc/locale.conf
12. Set the Hostname
Choose a name for your system and set it:
echo myarch > /etc/hostname
Add the hostname to the hosts file:
vim /etc/hosts
Add the following lines:
127.0.0.1 localhost
::1 localhost
127.0.1.1 myarch.localdomain myarch
13. Install Bootloader
To install the bootloader, you’ll use GRUB. First, install GRUB:
pacman -S grub
Then, install GRUB to your system’s disk:
grub-install --target=i386-pc /dev/sda
Finally, generate the GRUB configuration file:
grub-mkconfig -o /boot/grub/grub.cfg
14. Set a Root Password
Set a password for the root user:
passwd
15. Reboot
Exit the chroot environment and reboot your system:
exit
umount -R /mnt
reboot
Remove the installation media (USB drive or ISO) and boot into your new Arch Linux system.
Additional Setup
How to Install Arch Linux on VirtualBox?
Setting up Arch Linux on VirtualBox is a great way to test Arch without modifying your existing system. The process is similar to installing Arch on a physical machine, except you need to configure the VirtualBox settings first:
- Create a new virtual machine with a suitable amount of memory and disk space.
- Mount the Arch Linux ISO as the boot device.
- Proceed with the installation using the same steps outlined above.
How to Install Arch Linux Dual Boot with Windows?
To install Arch Linux alongside Windows in a dual-boot configuration, follow the same steps, but instead of wiping your disk, shrink the Windows partition and install Arch Linux on the free space. Use a tool like GRUB to manage the dual-boot process.
Conclusion
Congratulations! You’ve successfully install Arch Linux. While the process is more involved than with many other distributions, it offers unparalleled control and flexibility, making it a rewarding experience for anyone who wants to learn more about Linux.
If you found this guide helpful, feel free to share it with others interested in installing Arch. If you have any questions or run into issues, leave a comment below, and I’ll be happy to help!