Home » Linux » Linux Distributions » Install Arch Linux

Install Arch Linux

Arch linux for those people who want to build their system, from very scratch. It is like to build their own house, from foundation to roof. Arch linux installation is not like other popular linux distribution, it does not comes with pre built installer. In this post I will show you how to install Arch linux using text based command line.

Download Arch linux ISO from the official arch linux website, burn it to cd or make bootable USB.

Install Arch Linux

After boot up with the archlinux, you should see the screen like this

arch-linux-boot

Select “Boot Arch Linux (x86_64)”

It will automatically login to a live os system

Now follow the steps to install Arch Linux

Create the disk partition

# cfdisk /dev/sda

A Typical disk partition should looks like the following screenshot

arch-linux-disk-partition

Make the filesystem and start swap partition

# mkfs.ext4 /dev/sda1
# mkswap /dev/sda2
# swapon /dev/sda2

Mount the partition /dev/sda1 to live OS

# mount /dev/sda1 /mnt

Install OS base packages to it

# pacstrap /mnt base base-devel

Login to the mounted filesystem and adjust the locale and password

# arch-chroot /mnt
# passwd
# nano /etc/locale.gen
# locale-gen
# ln -s /usr/share/zoneinfo/Asia/Kolkata /etc/localtime
# echo vbox > /etc/hostname

Install and configure the boot loader

# pacman –S grub os-prober
# grub-install /dev/sda
# os-prober
# mkinitcpio -p linux
# grub-mkconfig –o /boot/grub/grub.cfg
# exit

Now generate the fstab

# genfstab /mnt >> /mnt/etc/fstab

Unmount the filesyatem and reboot the system

# umount /mnt
# reboot

After boot up with the OS from hard disk you have to setup network configuration. Arch linux will not setup network automatically. Hence you have to configure it manually.

Check the network interface assigned and create an interface file with same name

# ip link show

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00

2: ens18: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000
    link/ether 26:e1:97:19:36:47 brd ff:ff:ff:ff:ff:ff

# cp /etc/netctl/examples/ethernet-static /etc/netctl/ens18

Configure the interface file ‘/etc/netctl/ens18’, the complete configuration should looks like this:

## For IPv4 static address configuration
 Interface=ens18
 Connection=ethernet
 IP=static
 Address=('10.0.50.45/8')
 Gateway=('10.0.50.254')
 DNS=('10.0.50.1')

Start and enable the network service

# netctl start ens18
# netctl enable ens18

Congratulation! your system is ready to use now. Now you could start installing your important software. It is very great full to me if this tutorial ‘Install Arch Linux’ helpful to you.

Leave a Reply

Your email address will not be published. Required fields are marked *

%d bloggers like this: