Sign in New API Help About

ArchLinux Cheat Sheet

4.1 KB of Plain text
Created 3 months, 2 weeks ago — expires in 255 days
Viewed 82 times
ArchLinux Cheat Sheet

Network configuration

    List network devices

      # ip link

    Enabling and disabling network interfaces

      # ip link set <network interface> up
      # ip link set <network interface> down

    To check the result:

      # ip link show dev <network interface>

    Start the DHCP service :

      # systemctl start dhcpcd@<network interface>.service

    Enable DHCP service to be started on bootup:

      # systemctl enable dhcpcd@<network interface>.service

    Install and start Network File System (NFS) :

      # pacman -S nfs-utils
      # systemctl start nfs-server.service
      # systemctl enable nfs-server.service

Manage packages with pacman

    Install a new package

      # pacman -S <package name>

    Update all package

      # pacman -Syu

    Remove all the cached packages that are not currently installed

      # pacman -Sc

    Recursively removing orphans packages and their configuration files

      # pacman -Rns $(pacman -Qtdq)

System and service manager : systemd

Arch Linux uses systemd as the init process.

    List running units

      # systemctl

    Start a unit immediately

      # systemctl start <unit>

    Stop a unit immediately

      # systemctl stop <unit>

    Restart a unit

      # systemctl restart <unit>

    Reload configuration

      # systemctl reload <unit>

    Show the status of a unit

      $ systemctl status <unit>

    Check whether a unit is already enabled or not

      $ systemctl is-enabled <unit>

    Enable a unit to be started on bootup

      # systemctl enable <unit>

    Disable a unit to not start during bootup

      # systemctl disable <unit>

    Check if any systemd services have entered in a failed state

      # systemctl --failed


    Kernel warning : "intel_rapl : no valid rapl domains found in package 0"

    Create and edit /etc/modprobe.d/blacklist.conf file with :

      blacklist intel_rapl

    Add an user

      # useradd -m -G users -s /bin/bash <username>

    Kernel warning : "ACPI : No IRQ available for PCI Interrupt Link [LNKS]. Try pci=noa"

        Open /boot/grub/grub.cfg

        In the Arch Linux entry menu, find the line beginning with linux

        At the end of this line add


        Example :

        	linux   /vmlinuz-linux root=UUID=a590453b-f844-4cf5-a74f-66a945eb2434 rw  quiet acpi=noirq

    To test this change before on a temporary grub.cfg modification, type e on menu entry in the boot loader to enter in edit mode.
    Show boot log

      journalctl -b

    Enable SSH service to be started on bootup:

      systemctl enable sshd.service

General recommendations

System maintenance

pacman -S samba gvfs gvfs-smb sshfs


Pacman cheat sheet (Arch Linux)

This is a list of commonly used commands for pacman package manager in Arch Linux distro.

Show help

# pacman -Sh

Install a package:

# pacman -S screen

Search for packages:

# pacman -Ss emacs

-- extra/emacs 25.1-1
The extensible, customizable, self-documenting real-time display editor
-- extra/texmacs 1.99.5-2
Free scientific text editor, inspired by TeX and GNU Emacs. WYSIWYG editor TeX-fonts and CAS-interface (Giac, GTybalt, Macaulay 2, Maxima, Octave, Pari, Qcl, R and Yacas) in one.
-- community/auctex 11.89-3
An extensible package for writing and formatting TeX files in Emacs
-- community/bbdb 3.1.2-4
A rolodex-like database for Emacs

Show packages of group xorg:

# pacman -Sg xorg

Remove packages

Remove only a package:

# pacman -R lsof

Remove a package and its dependencies not used by other packages:

# pacman -Rs lsof

Upgrade all packages on the system:

# pacman -Syu

Show extensive info about a package:

# pacman -Si vim

List files installed by screen package:

# pacman -Ql screen

Clean package cache:

# pacman -Sc