0
In this tutorial, we are going to see how to install Arch Linux 2015.04.01 in VirtualBox, an x86 and AMD64/Intel64 virtualization software for enterprise as well as home use.

First of all, download the most recent Arch Linux ISO image (currently 2015.04.01) from here. Select the appropriate architecture that meets with your system hardware. Also an internet connection is required because there are some packages are needed to be downloaded from remote repositories.

Instructions

Open VirtualBox and click New:


Type Arch Linux in the name box and set the architecture you are going to use (32/64 bit):


Select now the amount of memory (RAM) you want to allocate to the virtual machine (don't exceed the limit):



Leave the 'Create a virtual hard drive now' option selected and click Create:


Leave the 'VDI (Virtual Disk Image)' option selected and click Next:


Leave also 'Dynamically allocated' selected and press Next:


Select now the size of the virtual hard drive and click Create:


The VM is created. Let's start now the installation of Arch Linux. Select the VM we have just created and click the Start button:


A small window will pop-up, click the yellow icon to select the Arch Linux ISO image:


Browse to where you saved the iso image and click Open:


Click Start:


In the next screen, select 'Boot Arch Linux...' (32 or 64 bit) and press Enter:


Arch Linux will boot in CLI mode. You can check if you are connected to the internet by using the ping command as follows (use CTRL+C to end the process):

ping linuxserve.com



Let's now partition the VM. We will use the cfdisk command-line too. Run it using this command:

cfdisk

In the next screen, set this option and press Enter:

Select label type ---> dos


Let's create three partitions for Arch Linux. The first partition needs to be bootable, press New and set any size of your choice depending on the free space you have:


Set it as Primary and press enter:


Hit now Bootable to make this new partition bootable:


Next, we are going to create the SWAP. Select the remaining free space and hit New, set the size to 2048 MB for example and press Enter then set it as Primary:



Next create the last partition with the remaining free space which will contain our OS (New >> Primary). After creating it, select it (/dev/sda3) and hit Write:


Type 'yes' and press Enter:



All partitions are now created. Let's now apply a new file system to the partitions we have just created. Quit cfdisk, then run this command:

mkfs.ext4 /dev/sda1


Do the same thing for /dev/sda3:

mkfs.ext4 /dev/sda3


Now we will run this command for swap device (/dev/sda2):

mkswap /dev/sda2


Then run this cvommand:

swapon /dev/sda2

Next, run this command to mount /dev/sda1:

pacstrap /mnt

Create a directory called home using this command:

mkdir /mnt/home

Run now this command to mount /dev/sda3:

mount /dev/sda3 /mnt/home

Now all partitions are created and mounted and it's time to install Arch Linux. Run this command and wait until download completes:

pacstrap /mnt base base-devel

Next run this command to generate the file system table:

genfstab /mnt >> /mnt/etc/fstab

Now we are going to do a chroot (Change root). Run this command:

arch-chroot /mnt

Now set a root password using this command:

passwd

Next run this command:

echo vbox /etc/hostname

Let's now download grub using this command:

pacman -S grub-bios

Then install GRUB with this command:

grub-install /dev/sda

Finally, to generate grub configuration, run this command:

grub-mkconfig -o /boot/grub/grub.cfg

Run now this command:

umount /mnt/home

Then reboot and select now 'Boot existing OS':



That's the end of the first part. Wait for next part which will be published soon.

Post a Comment

 
Top