Skip to content

Latest commit

 

History

History
268 lines (207 loc) · 5.32 KB

README.md

File metadata and controls

268 lines (207 loc) · 5.32 KB

Arch Install

Pre-chroot

Update system clock:

timedatectl set-ntp true

Setup partitioning:

fdisk -l

Look for the model of disk you want to install the OS on Write the the disk down. Common names used are /dev/sdX or /dev/nvme0nX. Where X should be replaced with the disk letter

Example used: /dev/nvme0n1. Replace with corresponding disk

gdisk /dev/nvme0n1

# the following commands are ran inside gdisk
# delete existing partitions with, run the d command until you have no partitions left (unless you want to dual boot, don't delete the windows partitions)
d
=> 1,2,3,...

# create new partition for EFI
n
=> default = 1
=> default
=> +1G
=> EF00

# create a swap partition
n
=> default = 2
=> default
=> +32G # take the size of your RAM or half of it
=> default

# partition for our Linux system
n
=> default = 3
=> default
=> default
=> default

# Write changes --IMPORTANT--
w

assuming your disk name is /dev/nvme0n1 Format Partitions:

mkfs.fat -F 32 /dev/nvme0n1p1

mkswap /dev/nvme0n1p2

mkfs.ext4 /dev/nvme0n1p3

Mount partitions

mount /dev/nvme0n1p3 /mnt
mkdir /mnt/boot
mount /dev/nvme0n1p1 /mnt/boot

swapon /dev/nvme0n1p2

install nano

pacman -S nano

Before we can go onto installing our system we'll enable some things that'll make our downloads faster.

nano /etc/pacman.conf

ParallelDownloads=20

Install base system and kernel (add nano if you don't want to use vim for further steps)

pacstrap /mnt base linux linux-firmware base-devel

Generate fstab for our mounted filesystems

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

Enter our very basic install:

arch-chroot /mnt

Inside our chroot

Set our timezone

ln -sf /usr/share/zoneinfo/Europe/Brussels /etc/localtime

Sync hardware clock

hwclock --systohc

Setting Locale (optional, i usually don't and it works)

Localization:

nano /etc/locale.gen

# uncomment accordingly
en_US.UTF-8
nl_BE.UTF-8
nano /etc/locale.conf

LANG=en_US.UTF-8

Hostname

Set hostname:

nano /etc/hostname

yourpcname

Setup Users

Set our root password:

passwd

Create a normal user DO NOT FORGET -m :

useradd -m username

Set the password for our new user

passwd username

Installing boot loader

bootctl

bootctl install

add Arch entry

add a new file to /boot/loader/entries named arch.conf and add the following content:

title   Arch Linux
linux   /vmlinuz-linux
initrd  /initramfs-linux.img
options root=/dev/nvme0n1p3 #this can be different depending on your specific install

add Windows entry for dual boot

install edk2-shell and copy the file to your boot partition

sudo pacman -S edk2-shell
sudo cp /usr/share/edk2-shell/x64/Shell.efi /boot/shellx64.efi

get the PARTUUID for your windows-esp partition

sudo blkid | grep vfat

Usually, the Windows EFI Partiton is labelled “EFI system partition”, you should get a line that looks like that:

/dev/nvme1n1p2: UUID="52CC-E135" BLOCK_SIZE="512" TYPE="vfat" PARTLABEL="EFI system partition" PARTUUID="e2cc5bf0-9654-4ba3-bdc7-cdb1c2db2c3b"

set console-mode to max in loader config

sudo nano /boot/loader/loader.conf

> add the following line to the file
console-mode max

reboot and choose EFI shell in the loader screen which gets autocreated if you copied the shellx64.efi file correctly. it should display a list of FS aliases followed by that fs alias' partition details. if it does not enter the command map.

take note of the FS alias that contains the PARTUUID you got from the windows partition. this can look something like HD0b or HD2c but can also be longer.

enter the exit command and reboot into your linux installation.

create a file in your boot partition called windows.nsh and add the following with your correct fs alias:

HD2c:EFI\Microsoft\Boot\Bootmgfw.efi

now create a loader entry for that windows installation by creating a file windows.conf under /boot/loader/entries with the following content:

title   Windows
efi     /shellx64.efi
options -nointerrupt -noconsolein -noconsoleout windows.nsh

installing necessary tools

installing networkmanager and enabling the service for network access after install

pacman -S networkmanager
systemctl enable NetworkManager

Setup Sudo

pacman -S sudo
groupadd sudo
usermod -aG sudo username
nano /etc/sudoers
# => uncomment users in sudo group can use sudo

Installing KDE plasma

important use plasma-desktop instead of plasma-meta if you want a basic set of utilities like text editor, calculator, file explorer,.... plasma-meta is more of a barebones setup

pacman -S xorg-server plasma-meta

Enabling SDDM

systemctl enable sddm

Install a Terminal and file explorer

you can use others, but dolphin and konsole are the default for kde flatpak is for software installation using discover

pacman -S konsole dolphin flatpak

Exit Chroot and Reboot

exit
reboot

update in case of incorrect GPG keys

rm -rf /etc/pacman.d/gnupg/

pacman-key --init
pacman-key --populate archlinux
pacman-key --refresh-keys

pacman -S archlinux-keyring

installing a font containing emojis

run the fonts.sh script in this repository with root priveleges