Difference between revisions of "Installation guide"

From ArchWiki
Jump to: navigation, search
(Appendix: rm template)
(Hostname: move wiki links to separate sentence to reduce repetition of "hostname", see talk - a single link suffices as Network_configuration#Local_network_hostname_resolution is a subsection of Network configuration#Set the hostname)
 
(403 intermediate revisions by 9 users not shown)
Line 1: Line 1:
[[Category:About Arch]]
 
 
[[Category:Getting and installing Arch]]
 
[[Category:Getting and installing Arch]]
[[cs:Installation Guide]]
+
[[ar:Installation guide]]
 +
[[bg:Installation guide]]
 +
[[cs:Installation guide]]
 +
[[da:Installation guide]]
 
[[de:Arch Install Scripts]]
 
[[de:Arch Install Scripts]]
[[el:Installation Guide]]
+
[[el:Installation guide]]
[[es:Installation Guide]]
+
[[es:Installation guide]]
[[fr:Arch_install_scripts]]
+
[[fi:Installation guide]]
[[it:Installation Guide]]
+
[[fr:Arch install scripts]]
[[ko:Installation Guide]]
+
[[hr:Installation guide]]
[[pl:Installation Guide]]
+
[[hu:Installation guide]]
[[pt:Installation Guide]]
+
[[id:Installation guide]]
 +
[[it:Installation guide]]
 +
[[ja:インストールガイド]]
 +
[[ko:Installation guide]]
 +
[[lt:Installation guide]]
 +
[[nl:Installation guide]]
 +
[[pl:Installation guide]]
 +
[[pt:Installation guide]]
 
[[ro:Ghid de instalare]]
 
[[ro:Ghid de instalare]]
[[ru:Installation Guide]]
+
[[ru:Installation guide]]
[[uk:Installation Guide]]
+
[[sk:Installation guide]]
[[zh-CN:Installation Guide]]
+
[[sr:Installation guide]]
[[zh-TW:Installation Guide]]
+
[[th:Installation guide]]
This document will guide you through the process of installing [[Arch Linux]] using the [https://github.com/falconindy/arch-install-scripts Arch Install Scripts]. Before installing, you are advised to skim over the [[FAQ]].
+
[[uk:Installation guide]]
 +
[[zh-cn:Installation guide]]
 +
[[zh-tw:Installation guide]]
 +
This document is a guide for installing [[Arch Linux]] from the live system booted with the official installation image. Before installing, it would be advised to view the [[FAQ]]. For conventions used in this document, see [[Help:Reading]].
  
The community-maintained [[Main Page|Arch wiki]] is an excellent resource and should be consulted for issues first. The [[Wikipedia:IRC|IRC]] channel (irc://irc.freenode.net/#archlinux), and the [https://bbs.archlinux.org/ forums] are also available if the answer cannot be found elsewhere. Also, be sure to check out the {{ic|man}} pages for any command you are unfamiliar with; this can usually be invoked with {{ic|man ''command''}}.
+
For more detailed instructions, see the respective [[ArchWiki:About|ArchWiki]] articles or the various programs' [[man page]]s, both linked from this guide. See {{man|7|archlinux|url=https://projects.archlinux.org/svntogit/packages.git/tree/filesystem/trunk/archlinux.7.txt}} for an overview of the configuration. For interactive help, the [[IRC channel]] and the [https://bbs.archlinux.org/ forums] are also available.
  
== Download ==
+
== Pre-installation ==
Download the new Arch Linux ISO from the [https://www.archlinux.org/download/ Arch Linux download page].
+
* A single image is provided which can be booted into an i686 and x86_64 live system to install Arch Linux over the network. Media containing the [core] repository are no longer provided.
+
* Install images are signed and it is highly recommend to verify their signature before use. On Arch Linux, this can be done by using {{bc|pacman-key -v <iso-file>.sig}}
+
* The image can be burned to a CD, mounted as an ISO file, or directly written to a USB stick using a utility like {{ic|dd}}. It is intended for new installations only; an existing Arch Linux system can always be updated with {{ic|pacman -Syu}}.
+
  
== Installation ==
+
Arch Linux should run on any [[w:P6 (microarchitecture)|i686]] or [[w:X86-64|x86_64]] compatible machine with a minimum of 256 MB RAM. A basic installation with all packages from the {{Grp|base}} group should take less than 800 MB of disk space. As the installation process needs to retrieve packages from a remote repository, a working internet connection is required.
 +
 
 +
Download and boot the installation medium as explained in [[:Category:Getting and installing Arch]]. You will be logged in on the first [[w:Virtual console|virtual console]] as the root user, and presented with a [[Zsh]] shell prompt; common commands such as {{man|1|systemctl}} can be [[w:Command-line completion|tab-completed]].
 +
 
 +
To switch to a different console—for example, to view this guide with [[ELinks]] alongside the installation—use the {{ic|Alt+''arrow''}} [[Keyboard_shortcuts|shortcut]]. To [[textedit|edit]] configuration files, [[nano#Usage|nano]], [[w:vi|vi]] and [[vim#Usage|vim]] are available.
 +
 
 +
=== Set the keyboard layout ===
 +
 
 +
The default [[Keyboard configuration in console|console keymap]] is [[w:File:KB United States-NoAltGr.svg|US]]. To list available layouts, run {{ic|ls /usr/share/kbd/keymaps/**/*.map.gz}}.
 +
 
 +
To modify the layout, append a file name to {{man|1|loadkeys}}, omitting path and file extension. For example, run {{ic|loadkeys de-latin1}} to set a [[w:File:KB_Germany.svg|German]] keyboard layout.
 +
 
 +
[[Fonts#Console fonts|Console fonts]] are located in {{ic|/usr/share/kbd/consolefonts/}} and can likewise be set with {{man|8|setfont}}.
 +
 
 +
=== Verify the boot mode ===
 +
 
 +
If UEFI mode is enabled on an [[UEFI]] motherboard, [[Archiso]] will [[boot]] Arch Linux accordingly via [[systemd-boot]]. To verify this, list the [[UEFI#UEFI Variables|efivars]] directory:
 +
 
 +
# ls /sys/firmware/efi/efivars
 +
 
 +
If the directory does not exist, the system may be booted in [[w:BIOS|BIOS]] or CSM mode. Refer to your motherboard's manual for details.
 +
 
 +
=== Connect to the Internet ===
 +
 
 +
The [[dhcpcd]] daemon is [https://git.archlinux.org/archiso.git/tree/configs/releng/airootfs/etc/udev/rules.d/81-dhcpcd.rules enabled] on boot for '''wired''' devices, and will attempt to start a connection. Verify a connection was established, for example with [[ping]]:
 +
 
 +
# ping archlinux.org
 +
 
 +
If none is available, [[Systemd#Using units|stop]] the ''dhcpcd'' service with {{ic|systemctl stop dhcpcd@<TAB>}} and see [[Network configuration#Device driver|Network configuration]].
 +
 
 +
For '''wireless''' connections, {{man|8|iw|url=}}, {{man|8|wpa_supplicant|url=}} and [[netctl#Wireless .28WPA-PSK.29|netctl]] are available. See [[Wireless network configuration]].
 +
 
 +
=== Update the system clock ===
 +
 
 +
Use {{man|1|timedatectl}} to ensure the system clock is accurate:
 +
 
 +
# timedatectl set-ntp true
 +
 
 +
To check the service status, use {{ic|timedatectl status}}.
 +
 
 +
=== Partition the disks ===
 +
 
 +
When recognized by the live system, disks are assigned to a ''block device'' such as {{ic|/dev/sda}}. To identify these devices, use [[Core utilities#lsblk|lsblk]] or ''fdisk'' — results ending in {{ic|rom}}, {{ic|loop}} or {{ic|airoot}} may be ignored:
 +
 
 +
# fdisk -l
 +
 
 +
The following ''partitions'' (shown with a numerical suffix) are required for a chosen device:
  
=== Keyboard layout ===
+
* One partition for the root directory {{ic|/}}.
 +
* If [[UEFI]] is enabled, an [[EFI System Partition]].
  
For many countries and keyboard types appropriate keymaps are available already, and a command like {{ic|loadkeys uk}} might do what you want. More available keymap files can be found in {{ic|/usr/share/kbd/keymaps/}} (you can omit the keymap path and file extension when using loadkeys).
+
[[Swap space]] can be set on a separate partition or a [[Swap#Swap file|swap file]].
  
=== Partition disks ===
+
To modify ''partition tables'', use [[fdisk]] or [[parted]]. See [[Partitioning]] for more information.
See [[partitioning]] for details.
+
  
Remember to create any stacked block devices like [[lvm|LVM]], [[Dm-crypt_with_LUKS|LUKS]], or [[RAID|RAID]].
+
If wanting to create any stacked block devices for [[LVM]], [[disk encryption]] or [[RAID]], do it now.
  
 
=== Format the partitions ===
 
=== Format the partitions ===
See [[File Systems#Step_2:_create_the_new_file_system|File Systems]] for details.
 
  
If you are using (U)EFI you will most probably need another partition to host the UEFI System partition. Read [[Unified_Extensible_Firmware_Interface#Create_an_UEFI_System_Partition_in_Linux|Create an UEFI System Partition in Linux]].
+
Once the partitions have been created, each must be formatted with an appropriate [[file system]]. For example, to format the root partition on {{ic|/dev/''sda1''}} with {{ic|''ext4''}}, run:
  
=== Mount the partitions ===
+
# mkfs.''ext4'' /dev/''sda1''
We now must mount the root partition on {{ic|/mnt}}. You should also create directories for and mount any other partitions ({{ic|/mnt/boot}}, {{ic|/mnt/home}}, ...) if you want them to be detected by {{ic|genfstab}}.
+
  
=== Connect to the internet ===
+
See [[File systems#Create a file system]] for details.
A DHCP service is already enabled for all available devices. If you need to setup a static IP or use management tools such as [[Netcfg#Configuration|Netcfg]], you should stop this service first: {{ic|systemctl stop dhcpcd.service}}. For more information read [[configuring network]].
+
  
==== Wireless ====
+
=== Mount the file systems ===
Run {{ic|wifi-menu}} to set up your wireless network. For details, see [[Wireless Setup]] and [[Netcfg#Configuration|Netcfg]].
+
  
=== Install the base system ===
+
[[File_systems#Mount_a_filesystem|Mount]] the file system on the root partition to {{ic|/mnt}}, for example:
Before installing, you may want to edit {{ic|/etc/pacman.d/mirrorlist}} such that your preferred mirror is first. This copy of the mirrorlist will be installed on your new system by {{ic|pacstrap}} as well, so it's worth getting it right.
+
  
Using the [https://github.com/falconindy/arch-install-scripts/blob/master/pacstrap.in pacstrap] script we install the base system. The ''base-devel'' package group should also be installed if you plan on compiling software from the [[AUR]] or using [[ABS]].
+
# mount /dev/''sda1'' /mnt
+
# pacstrap /mnt base base-devel
+
  
Other packages can be installed by appending their names to the above command (space seperated), including the bootloader if you want.
+
Create mount points for any remaining partitions and mount them accordingly, for example:
  
=== Install a bootloader ===
+
# mkdir /mnt/''boot''
==== [[GRUB2|GRUB]] ====
+
# mount /dev/''sda2'' /mnt/''boot''
  
* For BIOS:
+
[https://git.archlinux.org/arch-install-scripts.git/tree/genfstab.in genfstab] will later detect mounted file systems and swap space.
  
# arch-chroot /mnt pacman -S grub-bios
+
== Installation ==
 +
 
 +
=== Select the mirrors ===
 +
 
 +
Packages to be installed must be downloaded from [[Mirrors|mirror servers]], which are defined in {{ic|/etc/pacman.d/mirrorlist}}. On the live system, all mirrors are enabled, and sorted by their synchronization status and speed at the time the installation image was created.
 +
 
 +
The higher a mirror is placed in the list, the more priority it is given when downloading a package. You may want to edit the file accordingly, and move the geographically closest mirrors to the top of the list, although other criteria should be taken into account.
 +
 
 +
This file will later be copied to the new system by ''pacstrap'', so it is worth getting right.
 +
 
 +
=== Install the base packages ===
 +
 
 +
Use the [https://projects.archlinux.org/arch-install-scripts.git/tree/pacstrap.in pacstrap] script to install the {{Grp|base}} package group:
 +
 
 +
# pacstrap /mnt base
 +
 
 +
This group does not include all tools from the live installation, such as {{Pkg|btrfs-progs}} or specific wireless firmware; see [https://projects.archlinux.org/archiso.git/tree/configs/releng/packages.both packages.both] for comparison.
 +
 
 +
To [[Help:Reading#Installation of packages|install]] packages and other groups such as {{Grp|base-devel}}, append the names to ''pacstrap'' (space separated) or to individual [[pacman]] commands after the [[#Chroot]] step.
 +
 
 +
== Configure the system ==
 +
 
 +
=== Fstab ===
 +
 
 +
Generate an [[fstab]] file (use {{ic|-U}} or {{ic|-L}} to define by [[UUID]] or labels, respectively):
  
* For EFI (in rare cases you will need {{ic|grub-efi-i386}} instead):
+
# genfstab -U /mnt >> /mnt/etc/fstab
  
# arch-chroot /mnt pacman -S grub-efi-x86_64
+
Check the resulting file in {{ic|/mnt/etc/fstab}} afterwards, and edit it in case of errors.
  
* Install GRUB after chrooting (refer to the [[#Configure the system]] section).
+
=== Chroot ===
  
==== [[Syslinux|Syslinux]] ====
+
[[Change root]] into the new system:
+
# arch-chroot /mnt pacman -S syslinux
+
  
=== Configure the system ===
 
Generate an [[fstab]] with the following command (if you prefer to use UUIDs or labels, add the {{ic|-U}} or {{ic|-L}} option, respectively):
 
# genfstab -p /mnt >> /mnt/etc/fstab
 
Next we [[chroot]] into our newly installed system:
 
 
  # arch-chroot /mnt
 
  # arch-chroot /mnt
  
* Write your hostname to {{ic|/etc/hostname}}.
+
=== Time zone ===
* Symlink {{ic|/etc/localtime}} to {{ic|/usr/share/zoneinfo/Zone/SubZone}}. Replace {{ic|Zone}} and {{ic|Subzone}} to your liking. For example:
+
  
# ln -s /usr/share/zoneinfo/Europe/Athens /etc/localtime
+
Set the [[Time#Time zone|time zone]]:
  
* Set [[Locale#Setting system-wide locale|locale]] preferences in {{ic|/etc/locale.conf}}.
+
# ln -s /usr/share/zoneinfo/''Region''/''City'' /etc/localtime
* Add [[KEYMAP|console keymap and font]] preferences in {{ic|/etc/vconsole.conf}}
+
* Uncomment the selected locale in {{ic|/etc/locale.gen}} and generate it with {{ic|locale-gen}}.
+
* Configure {{ic|/etc/mkinitcpio.conf}} as needed (see [[mkinitcpio]]) and create an initial RAM disk with:
+
+
# mkinitcpio -p linux
+
  
* Configure the bootloader: refer back to the appropriate article from the bootloader installation section.
+
Run {{man|8|hwclock}} to generate {{ic|/etc/adjtime}}:
  
* Set a root password with {{ic|passwd}}.
+
# hwclock --systohc
  
=== Unmount and reboot ===
+
This command assumes the hardware clock is set to [[w:UTC|UTC]]. See [[Time#Time standard]] for details.
If you are still in the chroot environment type {{ic|exit}} or press {{keypress|Ctrl+D}} in order to exit.
+
Earlier we mounted the partitions under {{ic|/mnt}}. In this step we will unmount them:
+
# umount /mnt/{boot,home,}
+
  
Now reboot and then login into the new system with the root account.
+
=== Locale ===
  
== Post-installation ==
+
Uncomment {{ic|en_US.UTF-8 UTF-8}} and other needed [[localization]]s in {{ic|/etc/locale.gen}}, and generate them with:
  
=== User management ===
+
# locale-gen
  
Add any user accounts you require as as described in [[Users and Groups#User management|User management]]. It isn't good practice to use the root account for regular use, or expose it via [[SSH]] on a server. The root account should only be used for administrative tasks.
+
Set the {{ic|LANG}} [[variable]] in {{man|5|locale.conf}} accordingly, for example:
  
=== Package management ===
+
{{hc|1=/etc/locale.conf|2=
 +
LANG=''en_US.UTF-8''
 +
}}
  
See [[pacman]] and [[FAQ#Package Management]] for answers regarding installing, updating, and managing packages.
+
If you [[#Set the keyboard layout|set the keyboard layout]], make the changes persistent in {{man|5|vconsole.conf}}:
  
=== Service management ===
+
{{hc|1=/etc/vconsole.conf|2=
 +
KEYMAP=''de-latin1''
 +
}}
  
Arch Linux uses [[systemd]] as init, which is a system and service manager for Linux. For maintaining your Arch Linux installation, it is a good idea to learn the basics about it. Interaction with systemd is done through the {{ic|systemctl}} command. Read [[systemd#Basic systemctl usage]] for more information.
+
=== Hostname ===
  
=== Sound ===
+
Create the {{man|5|hostname}} file:
  
[[ALSA]] usually works out-of-the-box. It just needs to be unmuted. Install {{Pkg|alsa-utils}} (which contains {{ic|alsamixer}}) and follow [[Advanced Linux Sound Architecture#Unmuting the channels|these]] instructions.
+
{{hc|/etc/hostname|
 +
''myhostname''
 +
}}
  
ALSA is included with the kernel and it is recommended. If it does not work, [[OSS]] is a viable alternative. If you have advanced audio requirements, take a look at [[Sound system]] for an overview of various articles.
+
Consider adding a matching entry to {{man|5|hosts}}:
  
=== Video driver ===
+
{{hc|/etc/hosts|
 +
127.0.0.1 localhost.localdomain localhost
 +
::1 localhost.localdomain localhost
 +
'''127.0.1.1 ''myhostname''.localdomain ''myhostname'''''
 +
}}
  
The Linux kernel includes open-source video drivers and support for hardware accelerated framebuffers. However, userland support is required for OpenGL and 2D acceleration in X11.
+
See also [[Network configuration#Set the hostname]].
  
If you don't know which video chipset is available on your machine, run:
+
=== Network configuration ===
  
$ lspci | grep VGA
+
Configure the network for the newly installed environment: see [[Network configuration]].
  
For a complete list of open-source video drivers, search the package database:
+
For [[Wireless configuration]], [[Help:Reading#Installation of packages|install]] the {{Pkg|iw}}, {{Pkg|wpa_supplicant}}, and {{Pkg|dialog}} packages, as well as needed [[Wireless#Installing driver/firmware|firmware packages]].
  
$ pacman -Ss xf86-video | less
+
=== Initramfs ===
  
The {{ic|vesa}} driver is a generic mode-setting driver that will work with almost every GPU, but will not provide any 2D or 3D acceleration. If a better driver cannot be found or fails to load, Xorg will fall back to vesa. To install it:
+
Creating a new ''initramfs'' is usually not required, because [[mkinitcpio]] was run on installation of the {{Pkg|linux}} package with ''pacstrap''.
  
# pacman -S xf86-video-vesa
+
For special configurations, modify the {{man|5|mkinitcpio.conf|url=}} file and recreate the initramfs image:
  
In order for video acceleration to work, and often to expose all the modes that the GPU can set, a proper video driver is required:
+
# mkinitcpio -p linux
  
{| class="wikitable"  style="text-align:center"
+
=== Root password ===
|-
+
! Brand !! Type !! Driver !! [[Multilib]] Package<br><span style="font-weight: normal;">(for 32-bit applications on Arch x86_64)</span> !! Documentation
+
|-
+
| rowspan="2" bgcolor=#f7e3e3| '''<span style="color: #e62c2c;">AMD/ATI</span>'''
+
| Open source || {{Pkg|xf86-video-ati}} || {{Pkg|lib32-ati-dri}} || [[ATI]]
+
|-
+
| Proprietary || {{Pkg|catalyst-dkms}} || {{Pkg|lib32-catalyst-utils}} || [[AMD Catalyst]]
+
|-
+
| bgcolor=#e3ecf7| '''<span style="color: #2a6dc8;">Intel</span>'''
+
| Open source
+
| {{Pkg|xf86-video-intel}} || {{Pkg|lib32-intel-dri}} || [[Intel Graphics]]
+
|-
+
| rowspan="4" bgcolor=#e3f7e6| '''<span style="color: #409044;">Nvidia</span>'''
+
| rowspan="2"| Open source
+
| {{Pkg|xf86-video-nouveau}} || {{Pkg|lib32-nouveau-dri}} || [[Nouveau]]
+
|-
+
| {{Pkg|xf86-video-nv}} || – || (legacy driver)
+
|-
+
| rowspan="2"| Proprietary || {{Pkg|nvidia}} || {{Pkg|lib32-nvidia-utils}} || rowspan="2"| [[NVIDIA]]
+
|-
+
| {{Pkg|nvidia-304xx}} || {{Pkg|lib32-nvidia-304xx-utils}}
+
|}
+
  
=== Display server ===
+
Set the root [[password]]:
  
The X Window System (commonly X11, or X) is a networking and display protocol which provides windowing on bitmap displays. It is the de-facto standard for implementating graphical user interfaces. See the [[Xorg]] article for details.
+
# passwd
  
[[Wayland]] is a new display server protocol and the Weston reference implementation is available. There is very little support for it from applications at this early stage of development.
+
=== Boot loader ===
  
=== Fonts ===
+
See [[:Category:Boot loaders]] for available choices and configurations. For example, set up the boot loader with [[systemd-boot]] if your system supports UEFI, and [[GRUB#BIOS systems|GRUB]] when not.
  
You may wish to install a set of TrueType fonts, as only unscalable bitmap fonts are included by default. DejaVu is a set of high quality, general-purpose fonts with good [[Wikipedia:Unicode|Unicode]] coverage:
+
If you have an Intel CPU, install the {{Pkg|intel-ucode}} package in addition, and [[Microcode#Enabling Intel microcode updates|enable microcode updates]].
  
# pacman -S ttf-dejavu
+
== Reboot ==
  
Refer to [[Font Configuration]] for how to configure font rendering and [[Fonts]] for font suggestions and installation instructions.
+
Exit the chroot environment by typing {{ic|exit}} or pressing {{ic|Ctrl+D}}.
  
== Appendix ==
+
Optionally manually unmount all the partitions with {{ic|umount -R /mnt}}: this allows noticing any "busy" partitions, and finding the cause with {{man|1|fuser}}.
 +
 
 +
Finally, restart the machine by typing {{ic|reboot}}: any partitions still mounted will be automatically unmounted by ''systemd''. Remember to remove the installation media and then login into the new system with the root account.
 +
 
 +
== Post-installation ==
  
For a list of applications that may be of interest, see [[List of Applications]].
+
See [[General recommendations]] for system management directions and post-installation tutorials (like setting up a graphical user interface, sound or a touchpad).
  
See [[General Recommendations]] for post-installation tutorials like setting up a touchpad or font rendering.
+
For a list of applications that may be of interest, see [[List of applications]].

Latest revision as of 14:59, 20 November 2016

This document is a guide for installing Arch Linux from the live system booted with the official installation image. Before installing, it would be advised to view the FAQ. For conventions used in this document, see Help:Reading.

For more detailed instructions, see the respective ArchWiki articles or the various programs' man pages, both linked from this guide. See archlinux(7) for an overview of the configuration. For interactive help, the IRC channel and the forums are also available.

Pre-installation

Arch Linux should run on any i686 or x86_64 compatible machine with a minimum of 256 MB RAM. A basic installation with all packages from the base group should take less than 800 MB of disk space. As the installation process needs to retrieve packages from a remote repository, a working internet connection is required.

Download and boot the installation medium as explained in Category:Getting and installing Arch. You will be logged in on the first virtual console as the root user, and presented with a Zsh shell prompt; common commands such as systemctl(1) can be tab-completed.

To switch to a different console—for example, to view this guide with ELinks alongside the installation—use the Alt+arrow shortcut. To edit configuration files, nano, vi and vim are available.

Set the keyboard layout

The default console keymap is US. To list available layouts, run ls /usr/share/kbd/keymaps/**/*.map.gz.

To modify the layout, append a file name to loadkeys(1), omitting path and file extension. For example, run loadkeys de-latin1 to set a German keyboard layout.

Console fonts are located in /usr/share/kbd/consolefonts/ and can likewise be set with setfont(8).

Verify the boot mode

If UEFI mode is enabled on an UEFI motherboard, Archiso will boot Arch Linux accordingly via systemd-boot. To verify this, list the efivars directory:

# ls /sys/firmware/efi/efivars

If the directory does not exist, the system may be booted in BIOS or CSM mode. Refer to your motherboard's manual for details.

Connect to the Internet

The dhcpcd daemon is enabled on boot for wired devices, and will attempt to start a connection. Verify a connection was established, for example with ping:

# ping archlinux.org

If none is available, stop the dhcpcd service with systemctl stop dhcpcd@<TAB> and see Network configuration.

For wireless connections, iw(8), wpa_supplicant(8) and netctl are available. See Wireless network configuration.

Update the system clock

Use timedatectl(1) to ensure the system clock is accurate:

# timedatectl set-ntp true

To check the service status, use timedatectl status.

Partition the disks

When recognized by the live system, disks are assigned to a block device such as /dev/sda. To identify these devices, use lsblk or fdisk — results ending in rom, loop or airoot may be ignored:

# fdisk -l

The following partitions (shown with a numerical suffix) are required for a chosen device:

Swap space can be set on a separate partition or a swap file.

To modify partition tables, use fdisk or parted. See Partitioning for more information.

If wanting to create any stacked block devices for LVM, disk encryption or RAID, do it now.

Format the partitions

Once the partitions have been created, each must be formatted with an appropriate file system. For example, to format the root partition on /dev/sda1 with ext4, run:

# mkfs.ext4 /dev/sda1

See File systems#Create a file system for details.

Mount the file systems

Mount the file system on the root partition to /mnt, for example:

# mount /dev/sda1 /mnt

Create mount points for any remaining partitions and mount them accordingly, for example:

# mkdir /mnt/boot
# mount /dev/sda2 /mnt/boot

genfstab will later detect mounted file systems and swap space.

Installation

Select the mirrors

Packages to be installed must be downloaded from mirror servers, which are defined in /etc/pacman.d/mirrorlist. On the live system, all mirrors are enabled, and sorted by their synchronization status and speed at the time the installation image was created.

The higher a mirror is placed in the list, the more priority it is given when downloading a package. You may want to edit the file accordingly, and move the geographically closest mirrors to the top of the list, although other criteria should be taken into account.

This file will later be copied to the new system by pacstrap, so it is worth getting right.

Install the base packages

Use the pacstrap script to install the base package group:

# pacstrap /mnt base

This group does not include all tools from the live installation, such as btrfs-progs or specific wireless firmware; see packages.both for comparison.

To install packages and other groups such as base-devel, append the names to pacstrap (space separated) or to individual pacman commands after the #Chroot step.

Configure the system

Fstab

Generate an fstab file (use -U or -L to define by UUID or labels, respectively):

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

Check the resulting file in /mnt/etc/fstab afterwards, and edit it in case of errors.

Chroot

Change root into the new system:

# arch-chroot /mnt

Time zone

Set the time zone:

# ln -s /usr/share/zoneinfo/Region/City /etc/localtime

Run hwclock(8) to generate /etc/adjtime:

# hwclock --systohc

This command assumes the hardware clock is set to UTC. See Time#Time standard for details.

Locale

Uncomment en_US.UTF-8 UTF-8 and other needed localizations in /etc/locale.gen, and generate them with:

# locale-gen

Set the LANG variable in locale.conf(5) accordingly, for example:

/etc/locale.conf
LANG=en_US.UTF-8

If you set the keyboard layout, make the changes persistent in vconsole.conf(5):

/etc/vconsole.conf
KEYMAP=de-latin1

Hostname

Create the hostname(5) file:

/etc/hostname
myhostname

Consider adding a matching entry to hosts(5):

/etc/hosts
127.0.0.1	localhost.localdomain	localhost
::1		localhost.localdomain	localhost
127.0.1.1	myhostname.localdomain	myhostname

See also Network configuration#Set the hostname.

Network configuration

Configure the network for the newly installed environment: see Network configuration.

For Wireless configuration, install the iw, wpa_supplicant, and dialog packages, as well as needed firmware packages.

Initramfs

Creating a new initramfs is usually not required, because mkinitcpio was run on installation of the linux package with pacstrap.

For special configurations, modify the mkinitcpio.conf(5) file and recreate the initramfs image:

# mkinitcpio -p linux

Root password

Set the root password:

# passwd

Boot loader

See Category:Boot loaders for available choices and configurations. For example, set up the boot loader with systemd-boot if your system supports UEFI, and GRUB when not.

If you have an Intel CPU, install the intel-ucode package in addition, and enable microcode updates.

Reboot

Exit the chroot environment by typing exit or pressing Ctrl+D.

Optionally manually unmount all the partitions with umount -R /mnt: this allows noticing any "busy" partitions, and finding the cause with fuser(1).

Finally, restart the machine by typing reboot: any partitions still mounted will be automatically unmounted by systemd. Remember to remove the installation media and then login into the new system with the root account.

Post-installation

See General recommendations for system management directions and post-installation tutorials (like setting up a graphical user interface, sound or a touchpad).

For a list of applications that may be of interest, see List of applications.