Archlinux

archlinux is a Linux distribution based on the Linux kernel and other open-source software.

Installation

Partitioning

Show current partitions:

~# fdisk -l

Format your desired partition:

~# mkfs.ext4 /dev/sda1

Installing Base System

Mount your partition and start the installation:

~# mount /dev/sda1 /mnt
~# pacstrap /mnt base base-devel

Generate fstab:

~# genfstab -U /mnt >> /mnt/etc/fstab
~# cat /mnt/etc/fstab

Change root into the new system:

~# arch-chroot /mnt /bin/bash

Setting Up Users

Set root password:

~# passwd

Create a new user:

~# useradd -m -g users -G wheel,storage,power -s /bin/bash lsong
~# passwd lsong

Basic System Configuration

Synchronize and update repositories:

~# pacman -Syu

Install sudo:

~# pacman -S sudo

Bootloader Installation

Install and configure Grub:

~# pacman -S grub os-prober
~# grub-install /dev/sda
~# grub-mkconfig -o /boot/grub/grub.cfg

When ready, exit and reboot:

~# exit
~# umount -R /mnt
~# reboot

GUI Installation

Graphics Driver Installation

Identify your graphics card:

~$ lspci | grep VGA

Install the appropriate driver, e.g., for Intel:

~# pacman -S xf86-video-intel

For other graphic cards, refer to: ArchWiki Xorg Driver Installation

X Window System

然後按照 X 的步驟來安裝。

Pacman

AUR Helper - Yay:

~# pacman -S --needed git base-devel
~$ git clone https://aur.archlinux.org/yay.git
~$ cd yay
~$ makepkg -si

Audio:

~# pacman -S alsa-utils pulseaudio