Skip to content

Instructions for installing ArchLinux using the installation script ArchFi

It's been a while since my last ArchLinux installation guide article that covered the classic installation method (reading the documentation and typing command by command until you get to a working system). The following is a new one that will describe how to install this popular Linux distribution, using the Archfi installation script, I mentioned earlier. This text will be part of a trilogy that will consist of: Archfi script, Archinstal script and finally their comparison. Somehow, it just happened that a few days ago, a new version of the Archfi script was released after less than a year and a half, so let's see how it all works (and it works :) ).

Step by step installation in pictures

88-running-plasma-neofetch

Image 88 of 110

To begin with, you need to download a fresh version of the ArchLinux installation image and create a bootable flash drive. What I myself often look for on the Internet is the command I use to achieve this, and it is the following:

# dd bs=4M if=path/to/archlinux-version-x86_64.iso of=/dev/sdx conv=fsync oflag=direct status=progress

/dev/sdx – is the flash memory on which you want to create a bootable disk, in this example it is x but it can also be some other letter, for example b, c,… You do not want to replace this parameter (letter) with another partition on hard disk or ssd! The consequences are of course the deletion of the existing partition.

You boot the system from flash memory and the famous ArchLinux console is waiting where everything starts. It is recommended that you have a wired connection to the Internet, because Wi-Fi cards may require additional drivers, which is a bit irritating and slows down the installation process. The next step is to download a fresh version of the Archfi script from the SourceForge site:

$ curl -LO archfi.sf.net/archfi

Or if the script is unavailable on this link, then:

$ curl -LO matmoul.github.io/archfi

And by running the script:

$ sh archfi

ArchFi presents TUI (Text-based User Interface) with the main menu shown in the following images

Image of the main menu

Before I begin to describe the procedure, I would like to emphasize that an integral part of the text will be a photo-gallery with 88 images (this is a narrowed selection) and to indicate the main areas in order to maintain the clarity of the text. The main areas are:

1. Main menu – language selection and disk partitioning

2. Configuring a new installation of ArchLinux

3. Installation of the graphical environment

4. Firewall and user settings

Main menu – language selection and disk partitioning

As with a standard installation, it starts with selecting the language, keyboard layout, partitioning the device and mounting the partitions on which the new system will be installed. This example is a GPT system with an EFI system partition (which is the case with all computers bought in the last 10 years or so).

My personal choice here is to choose English language and American keyboard (us) for the layout. The reason for this is that the ArchFi script does not support the Serbian language, and I am used to using the American keyboard layout for working in the console :) When partitioning, I use the cfdisk partitioning tool. As I mentioned, a GPT partition table and two partitions with monitor points /boot and /. The first represents the EFI system partition where the system bootloader and kernel are stored, while the second is the root partition with the ext4 file system.

Note: This partition scheme is for demonstration purposes only. For real installation and daily use, in addition to the mentioned partitions, you can create swap and home partitions.

Next, start the installation of the basic system with the pacstrap tool and select the kernel that will be downloaded and used on the installed system. After that, we move on to the next area - configuring a new installation.

Configuring a new installation of ArchLinux

Configuring the new system

Configuring a new installation of ArchLinux means setting the hostname and store it in the hostnamefile, in this example the name is archlinux. Next is setting the keyboard and font layout and storing the settings to the vconsole.conffile. I leave these values at default. Next is the selection of the locale - en_US.UTF-8 which is stored in the locale.conf file and the time zone - Europe/Belgrade whose configuration is stored in the localtime.

The second part of this step involves setting a password for the "root" user and generating an fstab file with the partition UUID numbers. This has been a standard for so long that I don't even remember when it started being used :). In this step I do not change the mkinitcpio or mirrorlist_files. After selecting the appropriate bootloader, the next step in the installation is the installation of the graphical environment. I recently started using systemd-bootfor bootloader. The reason for this is faster boot using this bootloader compared to Grub2 and one Grub upgrade made it impossible for me to boot.

Installation of the graphical environment

The work of the ArchFi script stops here, because another script called Archdiis necessary for the installation of the graphical environment. Archdi Script has a simpler main menu with only three items, as in the following image:

Archdi script main menu

Updates submenu

From the Updates submenu, it is possible to install additional packages that extend the capabilities of the standard pacman package manager, such as pacman_contrib, then yay - the AUR helper. The following are some basic commands for system maintenance, which are not necessary at this step (after all, we are at the beginning of installing a new system).

Submenu Install

The next item in the submenu is Install. Here we have the possibility to install console and system packages, then Xorg server, graphic environment, display manager and additional applications necessary for daily work.

In the console tools submenu, you can select some general packages, then compression tools, web browsers and recovery tools. The script offers a list of available packages, so choosing is both easy and a little tedious at the same time.

In this section it is possible to choose an additional kernel to install, a good candidate for this is linux-lts. . It is preferable to have a backup variant if the latest kernel version does not prove to be a good choice. An essential item is the (networkmanager), because you'll want to configure network connections graphically. The rest is optional and depends on the hardware you have.

Xorg server submenu

The Xorg submenu offers the installation of packages related to this graphics server, the minimum amount of packages by default, while you can choose some additional packages yourself. This depends on the hardware you have. Drivers for input devices as well as graphics cards are also part of this sub-menu.

Config submenu

At the end of this area is the installation of the graphical environment and additional applications. As a user of the KDE Plasma environment I chose the same for this example, with some minimal set of Plasma packages and Plasma applications. From additional applications, you can install an office suite, a web browser, a torrent client, video and audio players, additional codecs... It all depends on your wishes and needs.

Setting up firewall and users and more

Towards the end of the installation, it is possible to configure the firewall and add the desired user to the sudoers group to have administrator privileges using the sudo command. The script also allows starting certain system services, again this depends on your needs. Again it asks to install certain kernels, which confuses me a bit. The script creator probably knows better :) Next is the configuration of the bootloader, which is not necessary.

After restarting the system, you log in to the newly installed system, with all the packages you installed via Archfi and Archdi scripts and the settings you made, and you can see the result of this example in the virtual machine in the picture:

Installed system and neofetch

This view of the neofetch script confirms that the installation in this way installs the minimum number of packages - 854, and the RAM memory usage is low. I like the system I use to have only the essentials with no frills, so this is a big plus for the installation script itself.

en_USEnglish
Powered by TranslatePress