Install Arch Linux
Edited by Anabasis, Maria, Eng, Alma
Arch Linux is a unique distribution of Linux that is similar in structure to other UNIX-based operating systems but has numerous quirks that set it apart from the more familiar distributions like Ubuntu or Debian. Arch Linux was originally developed by Judd Vinet started in March of 2002, and inspired by a distribution call CRUX. To put it simply, it's constructed with the purpose of letting you choose nearly everything and as a result, a fresh installation of it won't have many of the types of programs you might be familiar with. For example, it doesn't come with any graphical user interface.
While it may seem daunting at first, Arch Linux facilitates a greater understanding of how Linux works and can be an excellent learning experience. While it's not the best choice for beginners, if you're up for the challenge, give it a try!
- 1Downloading Arch Linux and Creating Installation Medium.Advertisement
- You need to download the latest release of Arch Linux from the Arch Linux website.
- After selecting a mirror, you'll see a simple HTML webpage containing files available for download. Click on the latest dual architecture ISO to download it. The current release is labeled "archlinux-2017.02.01-dual.ISO" but the date will vary as the operating system is updated. You should save the file to a location on your computer that you'll remember, so you can find it easily.
- Burning the Disk. For this step, you'll need a blank DVD and computer with a disk drive that can write to DVDs Both OS X and Windows have standard utilities for burning ISO images to disks so you won't need to download a 3rd party program. Here are two great guides for burning disks on Mac and Windows
- 2Booting From the Disk.Advertisement
- The next step is to boot from the disk you've just burned that contains Arch Linux. This requires that you reboot your computer and that you have the disk inserted. The boot order in the BIOS of most computers is such that it will ask if you'd like to boot from the disk.
- If your computer simply boots to the existing operating system, you'll need to change the boot order in your BIOS. The BIOS page can be accessed shortly after powering on your computer, and the keys for accessing it vary by manufacturer. Common keys for accessing the BIOS are Delete, F2, holding F10, or Control+Alt+Escape. Here is an example of what a BIOS page looks like:
- From here, use the arrow keys to navigate to the Boot section and place your CD/DVD drive at the top of the list. The next step is to save the changes in the BIOS, reboot, and your computer will boot from the disk. If you're having trouble, refer to this guide.
- Setting up Networking. Installing Arch Linux requires a working internet connection. It is strongly recommended that you use a wired internet connection, as the installation disk will configure networking automatically when booting. Be sure that you've connected your computer to a wired connection (Ethernet) before moving on, or configure wireless networking after booting from the disk. if you don't have a wired internet connection at home, libraries are a great place to look. Setting up wireless networks on Arch Linux is a complicated process that extends beyond the scope of this article, and you can find any information about the process here for wireless networks, and here for wired networks.
- Starting Arch Linux. If your computer booted from the disk, you should see something very similar to the following image:
- Select "Boot Arch Linux" using your arrow keys and press enter. Arch Linux will then boot up, and when finished should display the following image:
- 4Run the following command in the terminal to check for an internet connection: ping archlinux.org. If the server is unreachable, refer to the links for setting up wired and wireless networks in the "Setting up Networking" section of the article.Checking for internet connection.
- 5Run the following command to sync the computer's clock to NTP (Network Time Protocol) timedatectl set-ntp trueSyncing The System Clock.
- 6Partitioning The Disks.
- Run cfdisk by typing cfdisk in the terminal and select the storage device. Delete any existing partitions on the device that you wish to install Arch Linux on. This will destroy any existing data on the device, so beware. On Linux, hard disks are labeled "sdax" where x is a number, such as sda1.
- Use the command lsblk to list all storage devices available to help you determine which storage device is which.
- After deleting any existing partitions on the device you'd like to use, write a new partition to the device by selecting it and pressing enter. cfdisk will then ask you what size to make the partition. It should be at least several gigabytes, but it's up to you to determine how you'd like to partition your disk.
- Make sure you write the changes to the disk by selecting "Write" and pressing enter. Once finished, quit cfdisk to return to the terminal.
- 7Run mkfs.ext4 /dev/sdax where x is the device number you've just partitioned, and enter "y" if asked to proceed if the program finds an existing filesystem.Making the File System.
- 8To mount the newly created file system, run mount /dev/sdax /mnt then mkdir /mnt/boot and mount /dev/sdax /mnt/bootMounting The File System.
- 9Run the following to install Arch Linux: pacstrap /mnt baseInstalling The Base System.
- 10Run the following command to generate an fstab file genfstab -U /mnt >> /mnt/etc/fstabGenerating fstab File.
- 11Change the root directory to the new installation with the following command: arch-chroot /mntChroot Into The New System.
- 12Uncomment en_US.UTF-8 UTF-8 using a text editor such as nano, and uncomment other needed localizations and generate them with: locale-genLocale.
- 13Create the hostname file by navigating to the directory "/etc" by entering CD /etc and run the program nano to create the hostname file. Simply enter the desired hostname, and press Ctrl+o to write the changes. Make sure to name the file "hostname."Hostname.
- For more details on using nano, type man nano in the terminal.
- 14GRUB is a universal Linux bootloader, so this guide will only cover the configuration of GRUBBootloader.
- Install GRUB by entering Pacman -S grub.
- After it finishes installing. Enter grub-install --target=i386-pc --force /dev/sdax then grub-mkconfig -o /boot/grub/grub.cfg
Exit and Reboot
Type exit then reboot in the terminal After rebooting, you'll see this image again:
Only this time use the arrow keys to select "Boot existing OS" and Arch Linux should boot from your hard drive.
This guide has covered the basic installation of Arch Linux, but this doesn't mean your system is fully configured. You should refer to the general recommendations page on the Arch Linux wiki, and if you've encounter errors in the process, your best resource is the Arch Linux forums.
Categories : Operating System
Recent edits by: Eng, Maria, Anabasis