2015/05/14

How to install Arch Linux with BIOS boot loader and GPT partition table

We are going to install 64bit arch linux with BIOS and GPT partition table and boot loader is GRUB
Arch Linux is hard to install, because it needs a lot of basic knowledge of computer
Please read the following document carefully.
If you have any question, try to figure it out until you fully understand what you are doing now.
Simple Install guide
Detail Install guide

Partition the disks

On a BIOS/GPT configuration a BIOS boot partition is required. GRUB embeds its core.img into this partition.
Assume your disk is 20GB
our partition guide is
  • BIOS 1MB
  • swap 1GB
  • root 19GB
    gdisk /dev/sda
    

BIOS

n
Enter
Enter
+1M
ef02

swap

n
Enter
Enter
+1G
8200

root

n
Enter
Enter
Enter
8300
w

fs and swap

mkfs.ex4 /dev/sda3
mkswap /dev/sda2
swapon /dev/sda2

mount

mount /dev/sda3 /mnt

Install system

pacstrap -i /mnt base base-devel

Generate the fstab

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

Chroot and cofigure base system

arch-chroot /mnt /bin/bash

Locale

vi /etc/locale.gen
en_US.UTF-8 UTF-8
locale-gen
echo LANG=en_US.UTF-8 > /etc/locale.conf
export LANG=en_US.UTF-8

Time zone

ln -s /usr/share/zoneinfo/Asia/Taipei /etc/localtime

Hardware clock

 hwclock --systohc --utc

Hostname

echo bananaapple.nctucs.net > /etc/hostname

Edit /etc/hosts and add your hostname

Configure the network

systemctl enable dhcpcd.service

Set the root password

passwd

Install GRUB

pacman -S grub
grub-install --target=i386-pc --recheck --debug /dev/sdx
grub-mkconfig -o /boot/grub/grub.cfg

Unmount the partitions and reboot

exit
reboot

沒有留言:

張貼留言