Start iwd.service and connect your wifi
# systemctl start iwd.service
# systemctl status iwd.service
# iwctl --passphrase <you_wifi_password> station <name_of_station> connect <wifi_name>
# timeout 2 ping google.comVerify the host specified by ping is reachable otherwise don't proceed until you fix it. Since you won't be able to do anything without internet connection.
Assuming you have created the partitions using e.g cfdisk <SSD>
# cfdisk /dev/sdaBoot
# mkdir -p /mnt/boot/efi
# mkfs.fat -F32 /dev/sda1
# mount /dev/sda1 /mnt/boot/efiVar
# mkdir -p /mnt/var
# mkfs.ext4 /dev/sda2
# e2label /dev/sda2 var
# mount /dev/sda2 /mnt/varRoot
# mkfs.ext4 /dev/sda3
# mount /dev/sda3 /mntHome
# mkdir -p /mnt/home
# mkfs.ext4 /dev/sda4
# e2label /dev/sda4 home
# mount /dev/sda4 /mnt/homeSwapfile
# fallocate -l 32GB /swapfile mkswap
# /swapfile swapon /swapfileinstall base system
# pacstrap /mnt base linux-lts linux-firmware nano dialog iw wpa_supplicant networkmanagerinstall grub bootloader
# pacman -S grub efibootmgr os-prober
# grub-install --target=x86_64-efi --bootloader-id=grub --efi-directory=/boot/efi
Generate grub config
# grub-mkconfig -o /boot/grub/grub.cfg# genfstab -U /mnt >> /mnt/etc/fstabSometimes you might get file errors that the system is readonly if you try to generate the fstab file. Remount the system to fix it.
# mount -o remount, rw /
Edit the fstab file
# nano /mnt/etc/fstabEnter the Swapfile to the FSTAB
# nano /etc/fstab /swapfile none swap defaults 0 0For the mounted partitions change the UUID to the name of partition
i.e inplace of UUID=xxxxxx change this to /dev/sda2.
Though not necessary,it make the system boot faster.
nano commands
- Ctrl + o : Write Edits
- Enter : Save Edits
- Ctrl + x : Exit nano
- Ctrl + l : Clear Screen
Set timezone
You need to chroot to set the timezone
# arch-chroot /mntThen
# ln -sf /usr/share/zoneinfo/Africa/Nairobi /etc/locatimeSet hardware clock
# hwclock --systohc --utcsynchronize clock with timezone
This is simply activating the NTP service
# timedatectl set-ntp truegenerate locale settings
Using American English
Uncomment this part #en_US.UTF-8 UTF-8 in this file /etc/locale.gen
i.e
# nano /etc/locale.genThen run # locale-gen
set language & export it to a locale config file
# echo LANG = en_US.UTF-8 > /etc/locale.conf
# export LANG = en_US.UTF-8set hostname
change your_hostname below to what you would like to call your laptop
# echo your_hostname > /etc/hostnameRun this to verify everything is OK
# mkinitcpio -p linux-ltsShell
Am using zsh
# pacman -S zsh zsh-completions zsh-syntax-highlighting zsh-theme-powerlevel10kSet it as default
# chsh -S /bin/zshTerminal Emulator Install terminology terminal emulator
# pacman -S terminologyRoot
# passwdWhen prompted type and confirm the new password for root Sudo User
# useradd -m -G wheel -s /bin/zsh jay
# passwd jayWhen prompted type and confirm the password for sudo user above
Uncomment the wheel group
# EDITOR=nano visudoExit chroot
# exitUmount all partitions
# umount -R /mntReboot the system
# rebootNOTE
While they system is rebooting you may now remove the USB installer disk.
From now onwards you will be working with your fresh arch install using your
sudo user instead of root user.
Since we removed the USB installer disk we have lost the iwd.service that comes with it to
connect to wi-fi.But since we installed these wireless packages;wpa_supplicant and networkmanager
in Step 3
We only need to enable,start them.Then connect to our wifi network and continue with the installation process.
Note that the shell prompt has changed from # to %.
Enable & Start wpa_supplicant and networkmanager services
% sudo systemctl is-enable wpa_supplicant.service
% sudo systemctl enable wpa_supplicant.service
% sudo systemctl start wpa_supplicant.service
% sudo systemctl status wpa_supplicant.service% sudo systemctl is-enable networkmanager.service
% sudo systemctl enable networkmanager.service
% sudo systemctl start networkmanager.service
% sudo systemctl status networkmanager.serviceIf the status of the 2 services above is "running".Then we can connect our wifi again
nmcli is the command line client for networkmanager
List nearby wireless networks
% nmcli device wifi listIf your network is listed among the above;then connect to a wireless network
% nmcli device wifi <SSID> password <SSID_PASSWORD>where SSID -> your wifi name and SSID_PASSWORD -> your wifi password
Sometimes your wifi could be hidden hence it won't show up in the list. If that is the case then
% nmcli device wifi connect <SSID> password <SSID_PASSWORD> hidden yes
Am assuming if you are able to get through Step 1 then the above is easier.
Now that you have reconnected to the internet(ping to verify),you can continue configuring you installation.
Edit file hosts
% sudo nano /etc/hostsChange the above file to
127.0.0.1 localhost
:: localhost
127.0.0.1 <your_hostname>.localdomain <your_hostname>
Replace anything within the angle brackets inclusive.
Add multilib Repo
% sudo nano /etc/pacman.confUncomment the multilib repo.
sync repos
# sudo pacman -SyyYou should also see the multilib repo syncing just like it peers Core,Extra etc
Optimize the mirrors
- Am skipping this one till we have login out desktop environment;xfce
Install GUI Server
% sudo pacman -S xorg-server xorg-xinit xorg-xrandrInstall some important packages
% sudo pacman -S gvfs dkms xdg-user-dirs fuse2 haveged git ntfs-3gInstall the Display Manager & Desktop Environment
% sudo pacman lightdm lighdm-gtk-greeter xfce4 xfc4-goodiesConfigure Display Manager(lightdm)
% sudo nano /etc/lightdm/lightdm.confChange these settings
greeter-session=lightdm-gtk-greeter
user-session=xfce4-sessionEnable the LightDM Service
% sudo systemctl is-enabled lightdm.service
% sudo systemctl enable lightdm.serviceVerify that Graphical Target is the Default If not then set it to be the default one
% sudo systemctl get-defaultYou can skip the below step if the above command return graphical target
% sudo systemctl set-default graphical.targetVerify the enabled service
% sudo systemctl list-unit-files | grep enabledReboot your system and login using your sudo user credentials
% rebootSet Terminology Emulator as Default in xfce
- Applications-->Settings--->Default Applications --->Utilities--->Terminal Emulator
- Select 'Terminology' so that whenever you press
ctrl + alt + t,its the one that pops up.
NOTE
- I have skipped the installation for audio drivers and others,this could be done once desktop environment is up and running.