Archlinux Install

Posted on Apr 20, 2026

Laptop HW

  • ASUS R556L
  • CPU/GPU
    • CPU is I5-4210U(Haswell) which equipped with HD Graphics 4400 (Gen 7.5) according to lscpu
    • Nvidia GF117M(Fermi/NVC0), GeForce 820M
  • Screen
    • 15.6inch display and resolution is 1366x768.

basic installation

  • download iso and boot it.
  • install according to installation guideline
  • close secure boot from laptop bios.
  • connect wifi with iwctl
  • partition
    • need partition for efi, /boot(optional, systemd-boot need XBOOTLDR) and /.
    • partition the disk with fdisk and EFI(UEFI) partition is mandatory for UEFI.
    • format partitions.
  • mount disk to /mnt, update pacman mirrolist
  • nstall essential package: pacstrap -K /mnt base linux linux-firmware vim iwd
  • genfstab -U /mnt » /mnt/etc/fstab
  • arch-chroot /mnt
  • ln -sf /usr/share/zoneinfo/Area/Location /etc/localtime
  • hwclock –systohc
  • locale-gen
  • mkinitcpio -P
  • passwd
  • install boot loader, see UEFI
  • necessary package: sudo, openssh, less, fzf, mesa

Network

  • systemd_networkd + iwd + systemd_resolved
  • if only configure wifi with iwctl, there is no dhcp to assign IP.
  • automatic dhcp:
    • systemd-networkd
    • update /etc/iwd.config to enable iwd dhcp.

basic application

  • vim man bash-completion
  • tmux fzf btop nmap dust bc rsync
  • chrony for datetime syncup
  • yay

UEFI

Bios + MBR is setup on 1981 by IBM and many limitation. UEFI + GPT is new boot procedure.

  • support more big hard disk
  • speed up boot
  • secure boot
  • more flexible to develop new function with C, GUI and more function

EFI application

UEFI is like system and all EFI application (kernel or boot loader) could be run. It means we could skip boot loader and use Unified_kernel_image

EFI system partition

EFI partition is mandatory for UEFI, see link

boot loader

Grub or systemd_boot, see link

secure boot

Secure boot is part of UEFI and we could use UEFI without secure boot. Secure boot could be configured with CA (use your own key) or shim (Using a signed boot loader by Microsoft).

systemd-boot

  • systemd-boot could launch EFI application from EFI partition or partition with extended Boot Loader Partition (XBOOTLDR) on same disk. You could format /boot with XBOOTLDR or use EFI partition for boot.
  • install according to Archlinux wiki
  • bootctl –esp-path=/boot –boot-path=/boot install
  • bootctl to check if systemd-boot installed successfully
  • efibootmgr to double check UEFI system boot loader
  • update systemd-boot configuration file
    • update esp/loader/loader.conf
    • add arch.conf on esp/loader/entries/arch.conf
    • use “root=UUID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx” or “root=PARTUUID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx”
    • use “sort-key xxx” to sort entry list.
  • if you install GRUB first and then want to replace GRUB with systemd-boot. Remove GRUB bootloader in UEFI system boot with “efibootmgr –delete-bootnum -b #” (check GRUB sequence # with efibootmgr)

GPU

Intel

  • Intel driver is mesa even mesa-amber could also work.
  • my laptop GPU is Gen 6.5
  • mesa includes the modern Gallium3D drivers for Gen 3 hardware and later. This is the recommended choice.
  • mesa-amber is the legacy Mesa package which includes the classic (non-Gallium3D) drivers from Gen 2 to Gen 11 hardware. This driver might have better performance or stability for Gen 7 and older hardware, but is not maintained.

Nvidia

  • nouveau
    • need to “modprobe nouveau” and this driver is not loaded automatically.
    • nouveau should support KMS according to featureMatrix.
    • nouveau not support Vulkan on Fermi since nouveau support Vulkan from Kepler
    • nouveau + Fermi support OpenGl, not support Vulkan, but no webpage to describe support on GBM and EGL.
    • but nouveau not work with sway, ChatGPT think my driver card is too old to support GBM
  • Nvidia propriety driver
    • Sway not have good support on Nvidia driver , skip it

EGL/GBM/OpenGL/Vulkan

  • Rending API: OpenGl, OpenGl ES and Vulkan
  • EGL: provide context for rendering API(OpenGl/OpenGl ES)
    • Vulkan could connect with Wayland without EGL
  • GLX: connect X11 with OpenGl rendering API
  • GBM
    • allocate GPU memory for rendering API(OpenGl/OpenGl ES/Vulkan)
    • Wayland requires GBM support from the driver
  • eglinfo | grep Platform
  • vulkaninfo | grep Wayland

EGL

  • libEGL (WSLg) → d3d12_dri.so (WSLg) → /dev/dxg → GPU
  • App → libEGL / libGL → Mesa DRI driver → DRM kernel (/dev/dri/card0) → GPU
  • GLX → XWayland → Mesa → D3D12
  • EGL → Wayland → GBM/device → D3D12
  • Direct3D12 Gallium3D driver is

Vulkan

  • mandatory for vulkan: vulkan-icd-loader
  • vulkan-dzn: Vulkan driver for D3D12
  • vulkan-tools: vulkaninfo

package for GPU

  • intel-ucode vulkan-intel
  • intel-media-driver libva-intel-driver intel-gpu-tools
  • bbswitch

Configuration for WSL

  • export MESA_LOADER_DRIVER_OVERRIDE=d3d12
  • export GALLIUM_DRIVER=d3d12 # key for WSL
  • export EGL_PLATFORM=wayland
  • export SDL_VIDEODRIVER=wayland
  • export GDK_BACKEND=wayland,x11

configuration for wlroots

  • wlroots enviroment variables
  • WLR_DRM_DEVICES=’/dev/dri/card1:/dev/dri/card2:/dev/dri/card0'
  • WLR_RENDERER=gles2 sway # default: OpenGL ES 2.0
  • WLR_RENDERER=vulkan sway # Vulkan
  • WLR_RENDERER=pixman sway # SW rendering

Sound

  • Install pipewire
  • pulse is mandatory for man desktop application, wiremix for mixer.
  • pipewire pipewire-jack pipewire-pulse wiremix

Power management

  • systemd-logind to manage
  • upower battery managment

Login manager

  • greetd for login manager

Font and input method

  • fcitx5 fcitx5-qt fcitx5-gtk fcitx5-chinese-addons fcitx5-configtool
  • adwaita-icon-theme adwaita-fonts
  • Choose “Shuangpin”, not “Pingyin”
  • ttf-liberation
  • noto-fonts noto-fonts-cjk noto-fonts-emoji
  • ttf-cascadia-code ttf-fira-code
  • wqy-bitmapfont wqy-microhei wqy-zenhei

Sway

seat

  • Seat is used to manage HW like keyboard. Xorg use SUID root to get HW access, but wayland need seat for security reason.
  • systemd-logind + polkit or seatd
  • LIBSEAT_BACKEND=logind

sway-bar

  • sway-bar is used to display text only and key/mouse action is for whole bar. Way-bar is more advanced bar and display/action per area.
  • install iw to get SSID for sway-bar

idle manager

swayidle is idle manager. Idle manager take action like lock screen, black screen.

sway configuration

  • need add fcitx5, mofi, sway-idle command
  • exec sway to start sway
  • systemd add session already and no need to add session for sway: “exec dbus-run-session sway $@ > sway.log 2>&1”. Wehat may not work well if duplicate bus exists.

start up script

sway need to configure environmental variable and set up session before start sway

other

  • swaylock
  • swaybg
  • foot or alacritty for terminal
  • wofi for command running menu
  • grim + slurp + wl-clipboard for screen capture
  • mako for notification
  • imv for picture viewer
  • zathura for PDF viewer
  • google-chrome for browser
  • yazi for file manager
  • fastfetch
  • upower
  • wev for keyboard name mapping in wayland

Wechat

flatpak

  • pacman -S flatpak
  • reboot computer, see link. It is important and flatpak doesn’t work if no reboot.
  • flatpak search wechat

wechat-bin

  • wechat-bin is formal linux app from wechat but it is X-Windows, not wayland native.
  • try if X-Windows works well by xorg-xeyes, if not, pacman -S xorg-xwayland.
0227/082642.468546:ERROR:elf_dynamic_array_reader.h(64)] tag not found
[0227/082642.476024:WARNING:process_reader_linux.cc(146)] no stack mapping
[0227/082642.476127:WARNING:process_reader_linux.cc(146)] no stack mapping
[0227/082642.476223:WARNING:process_reader_linux.cc(146)] no stack mapping
[0227/082642.476299:WARNING:process_reader_linux.cc(146)] no stack mapping
[0227/082642.476384:WARNING:process_reader_linux.cc(146)] no stack mapping
[0227/082642.654154:ERROR:directory_reader_posix.cc(42)] opendir /home/jack/.xwechat/crashinfo/attachments/bb038d30-2906-42a4-9525-580c8a8ac7b1: No such file or directory (2) Aborted (core dumped) wechat
  • this app doesn’t work well in sway with many issue like fcitx doesn’t work.

wechat

  • yay -S wechat

tmpfs

  • setup tmpfs accroding to link
  • makepkg: edit /etc/makepkg.conf and delete comment mark before BUILDDIR=/tmp/makepkg
  • fstab: add “tmpfs /home/hongy19/tmpfs tmpfs noatime,nodev,nosuid,size=2G,uid=1000,gid=1000,mode=1700 0 0”
  • chrome: edit .config/chromium-flags.conf and add “–disk-cache-dir=/home/hongy19/tmpfs/chrome”
  • yay: yay –save –builddir /home/hongy19/tmpfs/yay