~/pancakes/ilikepancakes.ink/linux/arch-install-guide.html
_
×

Arch Linux Installation Guide

Complete installation guide for GNOME, Hyprland, and KDE Plasma environments

This comprehensive guide will walk you through installing Arch Linux from scratch with your choice of desktop environment. Arch Linux provides unparalleled control and customization, allowing you to build exactly the system you want.

⚠️ Important: This guide assumes basic Linux knowledge. Arch installation requires attention to detail. Always have the official Arch Wiki open as a reference: wiki.archlinux.org

1. Preparation

Step 1.1: Download Arch Linux ISO

Download the latest Arch Linux ISO from the official website:

# Download from: https://archlinux.org/download/ # Verify the signature for security gpg --keyserver-options auto-key-retrieve --verify archlinux-*.iso.sig
Step 1.2: Create Bootable USB

Create a bootable USB drive (replace /dev/sdX with your USB device):

# Linux/macOS sudo dd bs=4M if=archlinux-*.iso of=/dev/sdX conv=fsync oflag=direct status=progress # Windows (use Rufus or similar tool)
Step 1.3: Boot from USB

Boot from the USB drive and you'll be greeted with the Arch Linux live environment.

💡 Tip: If you have UEFI, ensure Secure Boot is disabled in BIOS settings.

2. Base Installation

Step 2.1: Verify Boot Mode
# Check if booted in UEFI mode ls /sys/firmware/efi/efivars # If directory exists, you're in UEFI mode
Step 2.2: Connect to Internet
# For Ethernet (usually automatic) ping archlinux.org # For WiFi iwctl [iwd]# device list [iwd]# station wlan0 scan [iwd]# station wlan0 get-networks [iwd]# station wlan0 connect "Your-WiFi-Name" [iwd]# exit
Step 2.3: Update System Clock
timedatectl set-ntp true timedatectl status
Step 2.4: Partition Disks

List available disks and create partitions:

# List disks lsblk # Use cfdisk for easier partitioning cfdisk /dev/sda # Recommended partition scheme for UEFI: # /dev/sda1: 512M EFI System (Type: EFI System) # /dev/sda2: 4G+ Linux swap (Type: Linux swap) # /dev/sda3: Remaining space Linux filesystem (Type: Linux filesystem)
Step 2.5: Format Partitions
# Format EFI partition mkfs.fat -F32 /dev/sda1 # Format root partition mkfs.ext4 /dev/sda3 # Setup swap mkswap /dev/sda2 swapon /dev/sda2
Step 2.6: Mount Partitions
# Mount root partition mount /dev/sda3 /mnt # Create and mount EFI directory mkdir /mnt/boot mount /dev/sda1 /mnt/boot

3. System Configuration

Step 3.1: Install Base System
# Install base packages pacstrap /mnt base linux linux-firmware # Install additional essential packages pacstrap /mnt base-devel vim nano networkmanager grub efibootmgr
Step 3.2: Generate fstab
genfstab -U /mnt >> /mnt/etc/fstab # Verify the file cat /mnt/etc/fstab
Step 3.3: Chroot into System
arch-chroot /mnt
Step 3.4: Configure System
# Set timezone ln -sf /usr/share/zoneinfo/Region/City /etc/localtime hwclock --systohc # Configure locale echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen locale-gen echo "LANG=en_US.UTF-8" > /etc/locale.conf # Set hostname echo "your-hostname" > /etc/hostname # Configure hosts file cat >> /etc/hosts << EOF 127.0.0.1 localhost ::1 localhost 127.0.1.1 your-hostname.localdomain your-hostname EOF
Step 3.5: Set Root Password
passwd
Step 3.6: Install and Configure Bootloader
# Install GRUB grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=GRUB # Generate GRUB configuration grub-mkconfig -o /boot/grub/grub.cfg
Step 3.7: Enable NetworkManager
systemctl enable NetworkManager

4. GNOME Desktop Environment

Step 4.1: Create User Account
# Create user and add to groups useradd -m -G wheel,audio,video,optical,storage -s /bin/bash username # Set user password passwd username # Enable sudo for wheel group EDITOR=nano visudo # Uncomment: %wheel ALL=(ALL) ALL
Step 4.2: Install GNOME
# Install GNOME desktop environment pacman -S gnome gnome-extra # Install display manager pacman -S gdm # Enable GDM systemctl enable gdm
Step 4.3: Install Additional Software
# Install useful applications pacman -S firefox chromium code git wget curl htop neofetch # Install multimedia codecs pacman -S gst-plugins-good gst-plugins-bad gst-plugins-ugly gst-libav # Install fonts pacman -S ttf-dejavu ttf-liberation noto-fonts
GNOME Features: GNOME provides a modern, clean desktop experience with excellent Wayland support, integrated applications, and smooth animations. Perfect for users who want a polished, user-friendly environment.

5. Hyprland Wayland Compositor

Step 5.1: Create User Account (if not done)
# Create user and add to groups useradd -m -G wheel,audio,video,optical,storage -s /bin/bash username # Set user password passwd username # Enable sudo for wheel group EDITOR=nano visudo # Uncomment: %wheel ALL=(ALL) ALL
Step 5.2: Install Hyprland and Dependencies
# Install Hyprland from official repos pacman -S hyprland # Install essential Wayland tools pacman -S waybar wofi dunst alacritty # Install additional tools pacman -S grim slurp wl-clipboard xdg-desktop-portal-hyprland # Install file manager and basic apps pacman -S thunar firefox
Step 5.3: Configure Hyprland
# Exit chroot and reboot first exit umount -R /mnt reboot # After reboot, login as your user and create config mkdir -p ~/.config/hypr cp /usr/share/hyprland/hyprland.conf ~/.config/hypr/ # Basic Hyprland configuration cat > ~/.config/hypr/hyprland.conf << 'EOF' # Monitor configuration monitor=,preferred,auto,auto # Input configuration input { kb_layout = us follow_mouse = 1 touchpad { natural_scroll = no } sensitivity = 0 } # General configuration general { gaps_in = 5 gaps_out = 20 border_size = 2 col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg col.inactive_border = rgba(595959aa) layout = dwindle } # Decoration decoration { rounding = 10 blur { enabled = true size = 3 passes = 1 } drop_shadow = yes shadow_range = 4 shadow_render_power = 3 col.shadow = rgba(1a1a1aee) } # Animations animations { enabled = yes bezier = myBezier, 0.05, 0.9, 0.1, 1.05 animation = windows, 1, 7, myBezier animation = windowsOut, 1, 7, default, popin 80% animation = border, 1, 10, default animation = borderangle, 1, 8, default animation = fade, 1, 7, default animation = workspaces, 1, 6, default } # Key bindings $mainMod = SUPER bind = $mainMod, Q, exec, alacritty bind = $mainMod, C, killactive, bind = $mainMod, M, exit, bind = $mainMod, E, exec, thunar bind = $mainMod, V, togglefloating, bind = $mainMod, R, exec, wofi --show drun bind = $mainMod, P, pseudo, bind = $mainMod, J, togglesplit, # Move focus bind = $mainMod, left, movefocus, l bind = $mainMod, right, movefocus, r bind = $mainMod, up, movefocus, u bind = $mainMod, down, movefocus, d # Switch workspaces bind = $mainMod, 1, workspace, 1 bind = $mainMod, 2, workspace, 2 bind = $mainMod, 3, workspace, 3 bind = $mainMod, 4, workspace, 4 bind = $mainMod, 5, workspace, 5 # Move active window to workspace bind = $mainMod SHIFT, 1, movetoworkspace, 1 bind = $mainMod SHIFT, 2, movetoworkspace, 2 bind = $mainMod SHIFT, 3, movetoworkspace, 3 bind = $mainMod SHIFT, 4, movetoworkspace, 4 bind = $mainMod SHIFT, 5, movetoworkspace, 5 # Autostart exec-once = waybar exec-once = dunst EOF
Step 5.4: Configure Waybar
# Create waybar config mkdir -p ~/.config/waybar cat > ~/.config/waybar/config << 'EOF' { "layer": "top", "position": "top", "height": 30, "modules-left": ["hyprland/workspaces"], "modules-center": ["clock"], "modules-right": ["network", "pulseaudio", "battery"], "hyprland/workspaces": { "disable-scroll": true, "all-outputs": true, "format": "{icon}", "format-icons": { "1": "", "2": "", "3": "", "4": "", "5": "", "urgent": "", "focused": "", "default": "" } }, "clock": { "format": "{:%Y-%m-%d %H:%M}", "tooltip-format": "{:%Y %B}\n{calendar}" }, "network": { "format-wifi": " {signalStrength}%", "format-ethernet": " Connected", "format-disconnected": "⚠ Disconnected" }, "pulseaudio": { "format": "{icon} {volume}%", "format-muted": " Muted", "format-icons": { "headphone": "", "hands-free": "", "headset": "", "phone": "", "portable": "", "car": "", "default": ["", "", ""] } }, "battery": { "format": "{icon} {capacity}%", "format-icons": ["", "", "", "", ""] } } EOF # Create waybar style cat > ~/.config/waybar/style.css << 'EOF' * { border: none; border-radius: 0; font-family: "JetBrains Mono", monospace; font-size: 13px; min-height: 0; } window#waybar { background-color: rgba(43, 48, 59, 0.8); border-bottom: 3px solid rgba(100, 114, 125, 0.5); color: #ffffff; transition-property: background-color; transition-duration: .5s; } #workspaces button { padding: 0 5px; background-color: transparent; color: #ffffff; border-bottom: 3px solid transparent; } #workspaces button:hover { background: rgba(0, 0, 0, 0.2); } #workspaces button.focused { background-color: #64727D; border-bottom: 3px solid #ffffff; } #clock, #battery, #cpu, #memory, #network, #pulseaudio { padding: 0 10px; margin: 0 4px; color: #ffffff; } EOF
Hyprland Features: Hyprland is a dynamic tiling Wayland compositor with beautiful animations, extensive customization options, and excellent performance. Perfect for power users who want a modern, efficient workflow with eye-candy.

6. KDE Plasma Desktop Environment

Step 6.1: Create User Account (if not done)
# Create user and add to groups useradd -m -G wheel,audio,video,optical,storage -s /bin/bash username # Set user password passwd username # Enable sudo for wheel group EDITOR=nano visudo # Uncomment: %wheel ALL=(ALL) ALL
Step 6.2: Install KDE Plasma
# Install KDE Plasma desktop environment pacman -S plasma kde-applications # Install display manager pacman -S sddm # Enable SDDM systemctl enable sddm # Install additional KDE applications (optional) pacman -S packagekit-qt5 flatpak
Step 6.3: Install Additional Software
# Install useful applications pacman -S firefox chromium code git wget curl htop neofetch # Install multimedia codecs pacman -S gst-plugins-good gst-plugins-bad gst-plugins-ugly gst-libav # Install fonts pacman -S ttf-dejavu ttf-liberation noto-fonts # Install development tools pacman -S docker docker-compose nodejs npm python python-pip
Step 6.4: Configure KDE Plasma
# Exit chroot and reboot first exit umount -R /mnt reboot # After reboot, login through SDDM # KDE Plasma will start automatically # Optional: Install AUR helper (yay) git clone https://aur.archlinux.org/yay.git cd yay makepkg -si cd .. rm -rf yay # Install popular AUR packages yay -S visual-studio-code-bin discord spotify
KDE Plasma Features: KDE Plasma offers the most customizable desktop experience with extensive theming options, powerful widgets, and a traditional desktop paradigm. Perfect for users who want maximum control over their desktop appearance and behavior.

7. Post-Installation Setup

Step 7.1: System Updates
# Update system sudo pacman -Syu # Enable multilib repository (for 32-bit support) sudo nano /etc/pacman.conf # Uncomment: # [multilib] # Include = /etc/pacman.d/mirrorlist # Update package database sudo pacman -Sy
Step 7.2: Install AUR Helper
# Install yay AUR helper git clone https://aur.archlinux.org/yay.git cd yay makepkg -si cd .. rm -rf yay # Alternative: Install paru git clone https://aur.archlinux.org/paru.git cd paru makepkg -si cd .. rm -rf paru
Step 7.3: Graphics Drivers
# For NVIDIA GPUs sudo pacman -S nvidia nvidia-utils nvidia-settings # For AMD GPUs sudo pacman -S xf86-video-amdgpu mesa # For Intel GPUs sudo pacman -S xf86-video-intel mesa # For laptops with hybrid graphics sudo pacman -S optimus-manager
Step 7.4: Essential Software
# Development tools sudo pacman -S git vim neovim tmux docker docker-compose # Media and productivity sudo pacman -S vlc gimp libreoffice-fresh # System utilities sudo pacman -S htop btop neofetch tree unzip zip # Fonts and themes sudo pacman -S ttf-fira-code ttf-font-awesome yay -S ttf-ms-fonts
Step 7.5: Enable Services
# Enable useful services sudo systemctl enable bluetooth sudo systemctl enable cups # for printing sudo systemctl enable docker sudo systemctl enable fstrim.timer # for SSD maintenance # Start services immediately sudo systemctl start bluetooth sudo systemctl start cups sudo systemctl start docker

8. Troubleshooting

Common Issues and Solutions
Boot Issues:
  • • Check GRUB configuration: sudo grub-mkconfig -o /boot/grub/grub.cfg
  • • Verify fstab entries: cat /etc/fstab
  • • Boot from live USB and arch-chroot to fix issues
Network Issues:
  • • Enable NetworkManager: sudo systemctl enable --now NetworkManager
  • • Check network interfaces: ip link show
  • • For WiFi: nmcli device wifi connect "SSID" password "password"
Display Issues:
  • • Install proper graphics drivers for your GPU
  • • Check Xorg logs: cat /var/log/Xorg.0.log
  • • For Wayland issues, try X11 session
Audio Issues:
  • • Install PulseAudio: sudo pacman -S pulseaudio pulseaudio-alsa
  • • Or install PipeWire: sudo pacman -S pipewire pipewire-pulse
  • • Check audio devices: aplay -l

9. Resources and Next Steps

Essential Resources
Official Documentation:
Community and Support
Get Help:
Next Steps
# Useful commands to remember sudo pacman -Syu # Update system sudo pacman -S package # Install package sudo pacman -R package # Remove package sudo pacman -Ss search # Search packages yay -S aur-package # Install from AUR systemctl status service # Check service status journalctl -xe # View system logs
🎉 Congratulations! You've successfully installed Arch Linux with your chosen desktop environment. Remember: the journey doesn't end here. Arch Linux is about continuous learning and customization. Explore the AUR, customize your desktop, and most importantly - have fun with your new system!

Visitor Counter:

Visitor counter showing site visits