Whether you're a seasoned Arch user or a beginner, this cheat sheet has got your back. Letβs dive in! π§ββοΈβ‘
π οΈ System Management
π Update the system
sudo pacman -Syu
π₯ Install a package
sudo pacman -S <package_name>
ποΈ Remove a package
sudo pacman -R <package_name>
π§Ή Clean up unused dependencies
sudo pacman -Rns <package_name>
π Search for a package in the repo
pacman -Ss <package_name>
π List installed packages
pacman -Q
π¦ AUR (Arch User Repository) Management
π Install yay
(popular AUR helper)
git clone https://aur.archlinux.org/yay.git
cd yay
makepkg -si
π₯ Install a package from AUR
yay -S <package_name>
π Update all packages (including AUR)
yay -Syu
ποΈ Remove a package (AUR or repo)
yay -R <package_name>
πΎ File System and Disk Management
π Check disk space usage
df -h
ποΈ Check directory size
du -sh <directory_name>
π Mount a disk
sudo mount /dev/<device_name> /mnt
πͺ Unmount a disk
sudo umount /mnt
π οΈ List all drives and partitions
lsblk
βοΈ Format a drive to ext4
sudo mkfs.ext4 /dev/<device_name>
π₯ User Management
β Add a new user
sudo useradd -m -G wheel -s /bin/bash <username>
π Set a password for a user
sudo passwd <username>
π Switch to another user
su - <username>
β Delete a user
sudo userdel -r <username>
π Networking
π‘ Display active connections
ip a
π§ Enable/disable a network interface
sudo ip link set <interface> up
sudo ip link set <interface> down
π Test network connectivity
ping <hostname_or_IP>
β»οΈ Restart NetworkManager
sudo systemctl restart NetworkManager
βοΈ System Services
π Check the status of a service
systemctl status <service_name>
βΆοΈ Start/βΉοΈ Stop/π Restart a service
sudo systemctl start <service_name>
sudo systemctl stop <service_name>
sudo systemctl restart <service_name>
π Enable a service at startup
sudo systemctl enable <service_name>
β Disable a service at startup
sudo systemctl disable <service_name>
π§ Kernel and Boot Management
π List installed kernels
ls /boot/vmlinuz*
π Update GRUB configuration
sudo grub-mkconfig -o /boot/grub/grub.cfg
π₯ Install a new kernel
sudo pacman -S linux-lts
ποΈ Remove an old kernel
sudo pacman -R linux-<version>
π Troubleshooting
πͺ΅ View system logs
journalctl -xe
π View boot logs
dmesg | less
β Check failed systemd units
systemctl --failed
β¨ Other Handy Commands
π§Ή Clean the package cache
sudo pacman -Sc
π§ Show Arch Linux system info
neofetch
π Generate a mirrorlist
sudo reflector --latest 20 --sort rate --save /etc/pacman.d/mirrorlist
βοΈ Edit pacman configuration
sudo nano /etc/pacman.conf
πΎ Save this cheat sheet, and take your Arch Linux journey to the next level! π
Have suggestions? Drop them in the comments below! π
Top comments (0)