{"id":34558018,"url":"https://github.com/latitov/arch","last_synced_at":"2026-05-27T01:01:50.860Z","repository":{"id":177243433,"uuid":"332817197","full_name":"latitov/arch","owner":"latitov","description":"Arch Linux Install Cheatsheet","archived":false,"fork":false,"pushed_at":"2024-08-13T07:58:33.000Z","size":64,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-08-13T21:53:38.248Z","etag":null,"topics":["arch-linux","arch-linux-installation","archlinux","cheatsheet"],"latest_commit_sha":null,"homepage":"","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/latitov.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-01-25T16:52:54.000Z","updated_at":"2024-08-13T07:58:37.000Z","dependencies_parsed_at":"2024-08-08T14:09:31.439Z","dependency_job_id":null,"html_url":"https://github.com/latitov/arch","commit_stats":null,"previous_names":["latitov/arch"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/latitov/arch","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/latitov%2Farch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/latitov%2Farch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/latitov%2Farch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/latitov%2Farch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/latitov","download_url":"https://codeload.github.com/latitov/arch/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/latitov%2Farch/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33545458,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"ssl_error","status_checked_at":"2026-05-26T15:22:15.568Z","response_time":63,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["arch-linux","arch-linux-installation","archlinux","cheatsheet"],"created_at":"2025-12-24T08:33:17.423Z","updated_at":"2026-05-27T01:01:50.821Z","avatar_url":"https://github.com/latitov.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Arch Linux Install Cheatsheet\n\n_Leonid Titov, 2024-08-08_\n\n- https://www.youtube.com/watch?v=FFXRFTrZ2Lk\n- https://www.youtube.com/watch?v=8T0vvf1xm58\n- https://www.youtube.com/watch?v=sG-dGmvZHBo\n\n# Part 1\n\n## Create a bootable USB stick\n\n## Boot \u0026 verify the boot mode\n\n\t# ls /sys/firmware/efi/efivars\n\nIf the command shows the directory without error, then the system is booted in UEFI mode.\nIf the directory does not exist, the system may be booted in BIOS (or CSM) mode.\nIf the system did not boot in the mode you desired, refer to your motherboard's manual.\n\n\t# efivar --list\n\n\n## Connect to the Internet\n\n\t# ip link\n\t# ip a\n\n\n## Check the internet is connected\n\n\t# ping archlinux.org\n\t# ping ya.ru\n\n\n## Update the system clock\n\n\t# timedatectl set-ntp true\n\n\n## Partition the disks and make filesystems\n\n\t# lsblk\n\t# fdisk -l\n\nSuppose you have a single /dev/sda disk.\n\n-- If automated, better dd random data into it first, to erase previous partitions.\n\nYou have to create at least two partitions, EFI system partition (260+ MiB), and Linux root partition.\n\n\t# fdisk /dev/sda\n\tm\n\tg\n\tw\n\nthen (approximate, be careful!):\n\n\t# fdisk /dev/sda\n\tn\n\t+300M           -- 100M min\n\tt\n\t1\n\tw\n\nthen (approximate, be careful!):\n\n\t# fdisk /dev/sda\n\tn\n\tt\n\t23\n\tw\n\nThe result must be:\n\n\t/dev/sda1 EFI system partition 300M\n\t/dev/sda2 Linux x86-64 root the remainder\n\nNow, make filesystems:\n\n\t# mkfs.fat -F32 /dev/sda1\n\t# mkfs.ext4 /dev/sda2\n\nThe UEFI specification mandates support for the FAT12, FAT16, and FAT32 file systems[4].\nTo prevent potential issues with other operating systems and also since the UEFI specification only mandates\nsupporting FAT16 and FAT12 on removable media[5], it is recommended to use FAT32.\n\nIf you get the message WARNING: Not enough clusters for a 32 bit FAT!, reduce cluster size with\nmkfs.fat -s2 -F32 ... or -s1; otherwise the partition may be unreadable by UEFI. See mkfs.fat(8)\nfor supported cluster sizes.\n\n### Non-UEFI\n\n- The same thing, except don't create the ESP/EFI/whatever partition.\n- Also, don't bother creating GPT, stick with MBR.\n- Don't forget to set bootable flag to main partition.\n\n\n## Mount the file systems\n\nFirst time, do this, in this order:\n\n\t# mount /dev/sda2 /mnt\n\t# cd /mnt\n\t# mkdir boot\n\t# mount /dev/sda1 boot\n\nNext time, do this, in this order:\n\n\t# mount /dev/sda2 /mnt\n\t# mount /dev/sda1 /mnt/boot\n\n\n## Swap partition (optional)\n\nIf you created a swap partition, e.g. /dev/sda3, then you can install it too into the system:\n\n\t# mkswap /dev/swap_partition\n\t\n\t# swapon /dev/swap_partition\n\n\n# Part 2.\n\n## Install essential packages\n\n\t# pacstrap /mnt base linux linux-firmware\n\n\t# pacstrap /mnt openssh rsync sudo iproute2 dhclient man-db man-pages texinfo nano socat netcat curl wget iptables nftables\n\nOptional:\n\n\t# pacstrap /mnt ddrescue diffutils ethtool hdparm nmap\n \t# pacstrap /mnt htop wireguard-tools nodejs\n\nAlso add grub, if you're installing non-UEFI system.\n\ndhclient is ISC dhclient, specifically.\n\n## Fstab\n\n\t# genfstab -U /mnt \u003e\u003e /mnt/etc/fstab\n\n(!) This command must be called exactly __once__, or you'll need to edit the file manually.\n\nCheck the resulting /mnt/etc/fstab file, and edit it in case of errors.\n\n__The \"relatime\" is not a typo!__\u003cbr\u003e\nrelatime updates the access time only if the previous access time was earlier than the current\nmodify or change time. In addition, since Linux 2.6.30, the access time is always updated if the\nprevious access time was more than 24 hours old. This option is used when the defaults option,\natime option (which means to use the kernel default, which is relatime; see mount(8) and\nwikipedia:Stat (system call)#Criticism of atime) or no options at all are specified.\n\nNote:\u003cbr\u003e\nIf you have several data volumes, and want them be included in fstab - please mount them\nbeforehand somewhere in the /mnt too.\n\nE.g.:\n\n\tsda1 /mnt\n\tsda2 /mnt/data_volume_A\n\tsdb1 /mnt/data_volume_B\n\n## Change root into the new system\n\n\t# arch-chroot /mnt\n\n## Time zone\n\n\t# ln -sf /usr/share/zoneinfo/\u003cRegion\u003e/\u003cCity\u003e /etc/localtime\n\n\t# hwclock --systohc\n\n\n\n## Hostname\n\n\t# echo \u003chostname\u003e \u003e /etc/hostname\n\nAdd matching entries to hosts(5):\n\n\t/etc/hosts\n\t\t127.0.0.1 localhost\n\t\t::1 localhost\n\t\t127.0.1.1 myhostname.localdomain myhostname\n\nIf the system has a permanent IP address, it should be used instead of 127.0.1.1.\n\n\n## Root password \u0026 add users\n\n\t# passwd\n\t\n\t# useradd -m op1\n\t# passwd op1\n\n\n## Boot loader\n\n\t# bootctl --path=/boot install\n\nConfigure it:\n\n\t# nano /boot/loader/loader.conf\n\n\t\ttimeout 3\n\t\tdefault arch.conf\n\n\t# nano /boot/loader/entries/arch.conf\n\n\t\ttitle Arch Linux\n\t\tlinux /vmlinuz-linux\n\t\tinitrd /initramfs-linux.img\n\t\toptions root=/dev/sda2 rw\n\n### Non-UEFI\n\n\t# pacman -S grub\n\t\n\t# grub-install --target=i386-pc /dev/sdX\n\nwhere /dev/sdX is the disk (not a partition) where GRUB is to be installed.\n\nNow you must generate the main configuration file.\n\n\t# grub-mkconfig -o /boot/grub/grub.cfg\n\n\n## Exit \u0026 Reboot\n\n\t# exit\n\n\t# systemctl reboot\n\nExit the chroot environment by typing exit or pressing Ctrl+d.\n\nOptionally manually unmount all the partitions with umount -R /mnt: this allows noticing any \"busy\" partitions,\nand finding the cause with fuser(1).\n\nFinally, restart the machine by typing reboot: any partitions still mounted will be automatically unmounted\nby systemd. Remember to remove the installation medium and then login into the new system with the root account.\n\n\n\n# Part 3.\n\n## Network config\n\n\t# systemctl enable systemd-networkd\n\t# systemctl start systemd-networkd\n\t# systemctl status systemd-networkd\n\nSee the list of network interfaces:\n\n\t# ip a\n\nEnable DHCP on enp1s0:\n\n\t# nano /etc/systemd/network/LAN1.network\n\n\t\t[Match]\n\t\tName=enp1s0\n\t\t\n\t\t[Network]\n\t\tDHCP=yes\n\n\nEnable static IP on enp2s0:\n\n\t# nano /etc/systemd/network/LAN2.network\n\n\t\t[Match]\n\t\tName=enp2s0\n\t\t\n\t\t[Network]\n\t\tAddress=10.50.0.67/8\n\t\t#Gateway=10.1.10.1\n\t\t#DNS=10.1.10.1\n\t\t#DNS=8.8.8.8\n\nRestart networkd:\n\n\t# systemctl restart systemd-networkd\n\nInstall and start DHCP client on enp1s0:\n\n\t# systemctl enable dhclient@enp1s0.servive\n\t# systemctl start dhclient@enp1s0.servive\n\t# systemctl status dhclient@enp1s0.servive\n\nCheck:\n\n\t# ip a\n\nWhile waiting for an IP to be assigned you can run something like:\n\n\t# ping \u003csome-host\u003e\n\t# watch -n 1 ping -c 1 archlinux.org\n\n\n## Install xorg, firefox, x11vnc, nodm\n\n\t# pacman -S xorg firefox x11vnc nodm xterm\n\nTo test that X works, re-log as a user, then try:\n\n\t$ startx\n\nThe xterm must open. Note, the keyboard works only when mouse is over the window.\n\nTIP:\n\n- Ctrl+Alt+F1 to terminal\n- Alt-F7 back to GUI\n\n\n## Configure VNC server\n\nhttps://wiki.archlinux.org/index.php/x11vnc\n\n## Set up nodm \u0026 firefox\n\nhttps://wiki.archlinux.org/index.php/Nodm\n\nAfter installing nodm, modify the /etc/nodm.conf file. Set the NODM_USER variable to the user which\nshould be automatically logged in, and change the NODM_XSESSION variable to point to the script that\nstarts your session. The NODM_XSESSION script must be executable!\n\nEnable nodm.service so nodm will be started on boot:\n\n\t# systemctl enable nodm\n\nLog in as a user, and:\n\n\t$ nano .xinitrc\n\n\t\t#! /bin/bash\n\t\tfirefox\n\n\t$ chmod +x .xinitrc\n\nLogin session:\u003cbr\u003e\nFor proper session handling, create pam.d file with the following content:\n\n\t# nano /etc/pam.d/nodm\n\t\n\t\t#%PAM-1.0\n\t\t\n\t\tauth      include   system-local-login\n\t\taccount   include   system-local-login\n\t\tpassword  include   system-local-login\n\t\tsession   include   system-local-login\n\nEdit the nodm.service, and add these lines:\n\n\tRestart=always\n\tRestartSec=5\n\n(Look at /etc/systemd/system or /lib/systemd/system)\n\nthen\n\n\t# systemctl daemon-reload\n\n\n## Set up SSH\n\nhttps://wiki.archlinux.org/index.php/OpenSSH\n\n\t# pacman -S openssh\n\t\n\t# systemctl enable sshd\n\t# systemctl start sshd\n\t# systemctl status sshd\n\nConfig is in the:\n\n\t/etc/ssh/sshd_config\n\n## To install the KDE\n\nhttps://wiki.archlinux.org/title/KDE\n\n\t# pacman -Syu plasma-meta\n \n Optional:\n\n \t# pacman -Syu kde-applications  -- can be huge, take care to select what you really want\n\t# pacman -Syu iw\n\nThen:\n\n  \t# pacman -Syu networkmanager\n   \t# systemctl enable NetworkManager\n\t# systemctl start NetworkManager\n\nhttps://www.reddit.com/r/archlinux/comments/vborwi/kde_plasma_on_arch_linux_not_showing_wifi/\n\nThen:\n\n  \t# systemctl enable sddm\n   \t# systemctl start sddm\n\n## Install from AUR, and yay\n\n\t# pacman -Syu git base-devel\t\t\t-- could've been installed in the beginning\n\nThen for any AUR package:\n\n \t$ git clone https://aur.archlinux.org/yay-bin.git\n\n  \t$ cd yay-bin\n   \t$ makepkg -si\n\nIf you want to use yay instead (previously installed):\n\n\t$ yay -S google-chrome\n\nSome links: https://github.com/Jguer/yay (written in Go BTW), https://aur.archlinux.org/packages\n\n## Non-obviously useful software\n\n- https://archlinux.org/packages/extra/x86_64/cherrytree/\n- https://archlinux.org/packages/extra/x86_64/doublecmd-qt6/\n- https://aur.archlinux.org/packages/amneziawg-go\n\n## Troubleshooting\n\n### Updating old system, \"is of marginal trust\" error\n\n\t# pacman -Sy archlinux-keyring\n\n## .\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flatitov%2Farch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flatitov%2Farch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flatitov%2Farch/lists"}