OrbitalMartian

Back to Arch

📕 1277 words ⏳ 10 min.

In the last week or so, I have been toying with the idea of moving back to using Arch Linux from Fedora, where I ended up a couple of weeks ago. Today, I finally got round to doing just that. This time though, rather than using the old faithful method of archinstall script, I decided to manually install it. The way that Arch was designed.

I just wanted to share what I did and just look back on whether I could have done anything differently.

This is my first time manually installing any distro so it was a learning curve; I had the Arch Wiki Installation Guide open the whole time. Which did lead to one funny mishap, when I set the font to ter-132b which is as the Arch Wiki puts it:

For example, to use one of the largest fonts suitable for HiDPI screens

Being on a 1600x900px laptop screen, made it ginormous.

First Steps

After downloading the ISO and writing it to my USB using Fedora Media Writer (which is preinstalled on Fedora, so I didn’t need to go and install anything extra), I booted into the live environment.

The first thing I did was set my console keymap. The default is US, but I have a UK keyboard so I needed to set it as such. To do this, I simply ran:

$ localectl list-keymaps

To find what the code for my desired layout was, which I found is uk then:

$ loadkeys uk

And just like that, I had British keyboard layout in the TTY.

Next, I connected to the internet. For me, I use WiFi so I used iwctl to power on both the adapter and device. I then scanned for networks, listed them to ensure my WiFi network was shown and then connect to it by putting the SSID.

$ iwd
[iwd]# adapter *name-of-adapter* set-property Powered on
[iwd]# device *name-of-device* set-property Powered on
[iwd]# station *name* scan
[iwd]# station *name* get-networks
[iwd]# station *name* connect *SSID*

Then I quickly tested that I was connected by running $ ping archlinux.org which came back A-Ok and I moved on.

I updated the system clock by running timedatectl and made sure that it was set to Europe/London and that Daylight Savings was not in effect.

Configuring System & Installing

File System Configuration

Next, was the fun partition (get it, partitioning). Anyway, I always just have a single partition for my systems, so I set my disk to be partitioned as such:

$ fdisk -l
Disk /dev/sda: 931.51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: ST1000LM035-1RK1
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: F94EACDF-8CC2-451A-8EF1-21023FE3CDC0

Device       Start        End    Sectors   Size Type
/dev/sda1     2048       4095       2048     1M BIOS boot
/dev/sda2     4096    4198399    4194304     2G Linux extended boot
/dev/sda3  4198400 1953523711 1949325312 929.5G Linux filesystem

From there, I formatted the partition by creating the file system. I went for BTRFS as that’s what I’ve been using for years, for no particular reason other than it sounds cool and it works.

$ mkfs.btrfs /dev/sda3

I didn’t bother making a swap partition as I have never had a use for it nor understood them, maybe I’ll eventually understand them and find a need for them in my workflows.

After that, I mounted the root partition to /mnt :

$ mount /dev/sda3 /mnt

Installation

The wiki says to select the mirrors, I just left the whole lot of them in there, I didn’t want to mess around with them, but this is something I will look to sort out moving forward.

Installing the base system, it was as simple as running:

$ pacstrap -K /mnt base linux linux-firmware

I then quickly made sure to run fstab to ensure that /boot is mounted on startup.

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

Now I chroot into my newly created system to make a couple of configurations, such as ensuring the time is set correctly and that locales are generated as well as setting the hostname.

$ arch-chroot /mnt
# ln-sf /usr/share/zoneinfo/Europe/London /etc/localtime
# hwclock --systohc
# locale-gen

At this point, I had to create two files in /etc called locale.conf and vconsole.conf, which looked as below.

/etc/locale.conf
---
LANG=en_GB.UTF-8
/etc/vconsole.conf
---
KEYMAP=uk

To set the hostname, I created another file in /etc called hostname which simply contained the name I wanted my PC to be known on the network.

Now I set the root password using passwd and then chose my bootloader. I chose to go with GRUB as it’s the one I’ve had on all previous distros and installs and the one I’ve heard of the most.

Reboot

It was at this point, that I needed to reboot, so I did.

First exiting out of the chroot environment, then umount -R /mnt, and running reboot.

On restarting, I had a working system, but had a couple of problems. Firstly, I hadn’t installed a network manager, so I could do nothing more than local operations. To fix this, I booted back into the live environment and pacstrap‘ed networkmanager into my system and after a quick reboot back into my working system, I was able to connected to my WiFi using nmcli and then I could begin my other post-installation configuration as recommended in the General recommendations Arch Wiki .

Post-Installation Configuration

Now I have a working system, all I needed to do was setup my user, so I did so using adduser and setting the password using passwd.

$ useradd -m *username*
$ passwd

I did forget to add my user to the groups that I needed to, to allow it to be a superuser. This I had to do afterwards using groupadd sudoers wheel. Then I got to installing Plasma and SDDM so I could have a graphical environment. I set SDDM to run on startup through sudo systemctl enable --now sddm which also sets it to open then and there allowing me to easily log into my newly installed session. And then that’s where I am now. Of course I’ve installed a couple of other things since then, such as Vivaldi, tut, Alacritty, Kate, Kwrite and Dolphin. I have also got my Nextcloud account added to my system through System Settings > Online Accounts.

I have also installed yay as my AUR helper to allow me to use the AUR to install any packages I need.

Conclusion

And with all that information, I think that’s it for this one. I hope you enjoyed and I’ll see you next time. BYEEE!!!


Comments

If you have something to say, leave a comment, or contact me ✉️ instead