Contents

Archlinux Installation (VM)

Goal: a minimal working Arch Linux VM, every command shown and briefly explained.

This is a hands-on walkthrough, not the Arch Wiki. I’ll show each command in the exact order to run and explain what it does. For deep dives, refer to the Arch Wiki.

I’m writing this from Debian 13 and using GNOME Boxes, but the steps work with VirtualBox, VMware, or any other hypervisor.

Prerequisites

  • Comfortable using a terminal (run, copy/paste commands).

  • Basic familiarity with files, directories, and mounts.

  • Virtualization software installed (GNOME Boxes, VirtualBox, VMware, etc.).

No extra prep needed we’ll download the ISO, create the VM, partition, install packages, and configure the system step-by-step. By the end you’ll have a minimal Arch install ready for customization.

1. Download & Verify the ISO

Navigate to archlinux.org in your browser and click the Download button on the sidebar.

Select the closest mirror for downloading. While torrents might be the optimal choice, they require a VPN for security and specialized software, which could be confusing for newcomers. However, feel free to explore this option there are numerous online guides available.

After clicking, scroll down and locate your country or the nearest one. For my location, that’s France, so I’ll select a French mirror. You can copy the list of mirrors to ChatGPT and ask which ones are from reputable providers for additional security verification. Simply click on your chosen mirror.

A dialog will appear. Click on archlinux-x86_64.iso to begin the download. Once completed, click on b2sums.txt.

We use b2sums to verify the ISO’s integrity and ensure it hasn’t been tampered with. When you click the file, your browser will likely display its contents. Copy the line that ends with “archlinux-x86_64.iso”.

Create a b2sums.txt file in the same directory as the ISO file (they must be in the same location).

Open the file and paste the copied line.

Open a terminal in the directory containing both the ISO and b2sums files, then run this verification command:

b2sum -c b2sums.txt

2. Create the Virtual Machine

I’ll be using GNOME Boxes, but the process is similar in other VM software. Create a new VM and select “install from file” rather than “download OS”.

Select the ISO we downloaded.

Choose BIOS instead of UEFI. If you select UEFI and follow this guide, your installation won’t boot because it requires additional configuration steps. I’ve chosen BIOS because it’s simpler and suitable for a VM environment. However, if you plan to use this installation seriously or your machine is modern (within the last 10-15 years), consider using UEFI.

Depending on your machine’s capabilities, allocate appropriate amounts of RAM and storage, and configure any other necessary fields. In VirtualBox, you can even specify the number of CPU cores, so don’t worry about minor differences in this configuration step.

The VM will now start. You can either press Enter or wait for the automatic boot countdown.

Allow Arch Linux to complete its initialization process.

3. Begin the Installation Process

This should be your screen before proceeding with any commands.

First, configure your keyboard layout for proper command input. Find your layout using:

localectl list-keymaps

Use the arrow keys to navigate and locate your specific layout.

My layout is “fr”. Exit using Ctrl+C and apply the layout with:

loadkeys **name**
# In my case:
loadkeys fr

If the text appears too small, increase the font size with:

setfont ter-132b

Now verify network connectivity with the following commands:

ip link

Check the status of your network device (enp1s0 in this example). Also test connectivity with:

ping archlinux.org

This should succeed, confirming everything is working properly.

4. Disk Partitioning

Check available storage space with:

lsblk

For partitioning, while many tools are available, I’ll use cfdisk due to its similarity to GUI tools like gparted.

Type:

cfdisk

This interface should appear:

Select “gpt” and press Enter.

You’ll see the free space available. Select “new” (use left and right arrow keys to navigate options like new, quit, help, etc.) and press Enter.

Use arrow keys to navigate and specify the partition size. The order doesn’t matter significantly, so let’s begin with the root partition where our system will be installed.

Let’s allocate 54GB out of the available 60GB.

Press Enter to confirm. You’ll see it created /dev/vda1 with the default “Linux filesystem” type. Use up and down arrows to select vda1 or the free space. Select the free space, choose “new”, and press Enter.

Allocate 5GB for the swap partition (virtual RAM necessary for resource-constrained environments).

Since the default type is “Linux filesystem”, we need to change /dev/vda2 to swap. Select /dev/vda2 using arrow keys, choose “Type” with left/right arrows, and press Enter.

Select “Linux swap” and press Enter.

The remaining space will be used for the BIOS partition. While 1GB is excessive (BIOS partitions only need 2-3MB maximum), it doesn’t cause issues. Choose “new” and press Enter (ensure you’ve selected the free space, not /dev/vda2).

Accept the default size and press Enter.

Select /dev/vda3, choose “Type”, and press Enter.

Select “BIOS boot”.

Everything looks correct. Select “Write” to apply the changes.

Type “yes” and press Enter to confirm.

Notice the confirmation message “The partition table has been altered”. Select “Quit” and press Enter to exit cfdisk.

Verify the partitioning was successful using:

lsblk

Now create filesystems for the partitions. For the root partition (vda1), create the filesystem using:

mkfs.ext4 /dev/vda1

Configure the swap partition:

mkswap /dev/vda2

Mount our partition to /mnt:

mount /dev/vda1 /mnt

Activate the swap:

swapon /dev/vda2

5. System Configuration

Install the essential packages using pacstrap, along with any additional packages you require:

pacstrap -K /mnt base linux linux-firmware vim sudo nano networkmanager

Allow the installation to complete.

After installation finishes, generate the fstab file:

genfstab -U /mnt >> /mnt/etc/fstab

Change root into the new system:

arch-chroot /mnt

Configure the hardware clock:

hwclock --systohc

Generate locale information:

locale-gen

Set the system locale by editing the configuration file using nano:

nano /etc/locale.conf

Add the following line:

LANG=en_US.UTF-8

Exit with Ctrl+X, type “y”, and press Enter to save.

Configure the keyboard layout for the console using vim:

vim /etc/vconsole.conf

Press “i” to enter insert mode and add:

KEYMAP=fr

Replace “fr” with your specific layout.

Press Escape, then type “:wq” to write and quit vim.

Set a hostname using echo:

echo "archlinux" >> /etc/hostname

Configure the root password:

passwd

Install and configure GRUB for BIOS systems:

pacman -S grub
grub-install --target=i386-pc /dev/vda
grub-mkconfig -o /boot/grub/grub.cfg

Exit chroot, unmount the filesystem, and reboot:

exit
umount -R /mnt
reboot

6. Your Working System

The VM will reboot. Wait briefly and click on the window to interact with it.

Welcome to your Arch Linux system! Log in using the username “root” (currently the only user) and the password you configured with the “passwd” command.

Test connectivity with:

ping google.com

This will initially fail because NetworkManager doesn’t start automatically. Check its status:

systemctl status NetworkManager

Start NetworkManager immediately and enable it for automatic startup:

systemctl start NetworkManager
systemctl enable NetworkManager

Verify the service is active and enabled, then test connectivity again—it should work now.

Test ping again to confirm network functionality.

Now let’s install some packages. First, update the package repositories:

pacman -Syy

Install fastfetch for system information display:

pacman -S fastfetch

Run it by typing:

fastfetch

Congratulations! Take a screenshot, share it, and proudly tell everyone “I use Arch, by the way.”