What’s Special?
Optimized Arch Linux experience to get the most out of your hardware, drastically improved battery life and a good CPU Scheduling algorithm, Budget Fair Queueing, also setting up automatic frequency scaling of the CPU based on real-time load, and this is mostly Bleeding Edge, installer’s discretion is advised…
Pre Installation
- Connect to the internet using an ethernet cable, or WiFi
Copied!iwctl [iwctl]# station wlan0 connect "SSID" # Here wlan0 is the name of your wifi card, and SSID is the wifi name
- Make sure you’re connected to the internet by typing the following command
Copied!ping fruitynode.org -c4
We Just wanna make sure that the internet is accessible. You can try pinging any website you want, or if you’re sure that the internet is already set up, you can skip this part.
- Update the System Clock
Copied!timedatectl
- Now correctly Partition your disk…
(My specs are the deciding factor of the next command, so do make sure to change the partition size and stuff according to your setup!)
Copied!fdisk -l Device Size Type /dev/nvme0n1p1 2G EFI System /dev/nvme0n1p2 20G Linux Swap /dev/nvme0n1p3 <100%> Linux filesystem
- Formatting
Copied!mkfs.vfat -F32 /dev/nvme0n1p1 mkswap /dev/nvme0n1p2 mkfs.ext4 /dev/nvme0n1p3
- Mount the file systems
Copied!mount /dev/nvme0n1p3 /mnt mkdir -p /mnt/boot mount /dev/nvme0n1p1 /mnt/boot swapon /dev/nvme0n1p2
Installation
- Install the core Operating System tools here
(Some packages might not apply to you! proceed with discretion!)
Copied!pacstrap -K /mnt base base-devel linux linux-firmware intel-ucode sof-firmware alsa-ucm-conf git man-db sudo vi vim networkmanager pipewire iwd zram-generator bluez bluez-utils
Configuration of the Operating System
- Generate a file system table
Copied!genfstab -U /mnt >> /mnt/etc/fstab
- chroot into the new system
Copied!arch-chroot /mnt
- Configure the correct timezone
Copied!ln -sf /usr/share/zoneinfo/Asia/Kolkata /etc/locatime
- Run hwclock
Copied!hwclock --systohc
- Localization
Copied!echo "en_US.UTF-8 UTF-8" > /etc/locale.gen locale-gen echo "LANG_en_US.UTF-8" > /etc/locale.conf
- Network Configuration
Copied!echo "notebook" > /etc/hostname
Here notebook is the hostname of my laptop, you might want to change this
- Set up Zram
Copied!echo 0 > /sys/module/zswap/parameters/enabled
Then, to create a zram swap device using zstd
and half of the entire available ram, install zram-generator, then create /etc/systemd/zram-generator.conf
with the following
Copied!/etc/systemd/zram-generator.conf [zram0] zram-size = ram / 2 compression-algorithm = zstd swap-priority = 100 fs-type = swap
- Set up a user account and set a superuser password
Copied!passwd # sets the sudo password groupadd users useradd -m nonan23x usermod -aG wheel,users nonan23x passwd nonan23x # sets the user password
Copied!visudo # Uncomment to allow wheel group users to leverage their priviledges
- Setup Zsh shell for a nicer experience
Copied!cp /etc/zsh/zprofile /mnt/root/.zprofile && \ cp /etc/zsh/zshrc /mnt/root/.zshrc
- Installing a Desktop Environment
Copied!sudo pacman -S plasma konsole firefox
- Setup NetworkManager to start at boot
Copied!systemctl enable NetworkManager systemctl enable sddm
- Setup Hibernation
To do so, setup initramfs,resume
hook is required in/etc/mkinitcpio.conf
Then Remember to regenerate the initramfs for these changes to take effect
Copied!HOOKS=(base udev autodetect modconf kms keyboard keymap consolefont block filesystems resume fsck)
Copied!mkinitcpio -p linux
- Boot loader
I’m going to use systemd-boot
Copied!# Figure out your own PARTUUIDs! sudo blkid
Copied!bootctl install # /boot/loader/entries/arch-linux.conf title Arch Linux (linux) linux /vmlinuz-linux initrd /intel-ucode.img initrd /initramfs-linux.img options root=PARTUUID=<fill this> resume=PARTUUID=<fill this> rw
Post Installation
This is where the fun begins!!!
- Set up the correct mirrors!
Copied!## India Server = https://mirror.sahil.world/archlinux/$repo/os/$arch ## India Server = https://mirrors.piconets.webwerks.in/archlinux-mirror/$repo/os/$arch ## India Server = https://mirrors.nxtgen.com/archlinux-mirror/$repo/os/$arch ## India Server = https://archlinux.mirror.net.in/archlinux/$repo/os/$arch ## India Server = https://in-mirror.garudalinux.org/archlinux/$repo/os/$arch ## India Server = https://mirrors.vishnetwork.in/archlinux/$repo/os/$arch ## India Server = https://mirror.albony.xyz/archlinux/$repo/os/$arch ## India Server = http://mirrors.piconets.webwerks.in/archlinux-mirror/$repo/os/$arch ## India Server = http://in-mirror.garudalinux.org/archlinux/$repo/os/$arch ## India Server = http://mirror.sahil.world/archlinux/$repo/os/$arch ## India Server = http://archlinux.mirror.net.in/archlinux/$repo/os/$arch ## India Server = http://mirror.4v1.in/archlinux/$repo/os/$arch ## India Server = http://mirrors.nxtgen.com/archlinux-mirror/$repo/os/$arch
- Configure the AUR (im using paru)
Copied!sudo chown -R :users /opt cd /opt && git clone https://aur.archlinux.org/paru-git.git cd paru-git && makepkg -si
- Installing some required stuff like drivers and needed software
Copied!paru -S --needed jq npm unzip zip tar noto-fonts noto-fonts-cjk noto-fonts-emoji p7zip wine-staging giflib lib32-giflib libpng lib32-libpng libldap lib32-libldap gnutls lib32-gnutls mpg123 lib32-mpg123 openal lib32-openal v4l-utils lib32-v4l-utils libpulse lib32-libpulse libgpg-error lib32-libgpg-error alsa-plugins lib32-alsa-plugins alsa-lib lib32-alsa-lib libjpeg-turbo lib32-libjpeg-turbo sqlite lib32-sqlite libxcomposite lib32-libxcomposite libxinerama lib32-libgcrypt libgcrypt lib32-libxinerama ncurses lib32-ncurses ocl-icd lib32-ocl-icd libxslt lib32-libxslt libva lib32-libva gtk3 lib32-gtk3 gst-plugins-base-libs lib32-gst-plugins-base-libs vulkan-icd-loader lib32-vulkan-icd-loader mesa vulkan-intel docker gvfs thermald tlp xf86-input-libinput xf86-video-ati
- Optimizing the OS using Kernel parameters and stuff (Optional)
Copied!echo "options snd_hda_intel power_save=1" > /etc/modprobe.d/audio_powersave.conf echo "options iwlwifi power_save=1" >> /etc/modprobe.d/iwlwifi.conf
Copied!options nowatchdog ibt=off quiet loglevel=3 systemd.show_status=auto rd.udev.log_level=3 i915.modeset=1 nvme_load=yes
- Better IO Scheduler (Optional)
Copied!cat << EOF > /etc/udev/rules.d/60-ioschedulers.rules # set scheduler for NVMe ACTION=="add|change", KERNEL=="nvme[0-9]*", ATTR{queue/scheduler}="none" # set scheduler for SSD and eMMC ACTION=="add|change", KERNEL=="sd[a-z]|mmcblk[0-9]*", ATTR{queue/rotational}=="0", ATTR{queue/scheduler}="mq-deadline"
- Start necessary services
Copied!systemctl enable thermald.service systemctl enable auto-cpufreq.service
- Articles that weren’t included in this guide, but you must read them and only activate them if fits your setup
SSD – Set up Periodic or Continous TRIM
Improving Performance – A lot of things were untouched
RICE your machine
- Follow the rest of the guide from my github
Leave a Reply