View source for netinstall

{{anchor href="top"}}
Hits :  **{{hits}}**

== Install Archlinux with media 2012.08.04 ==

basic net-installation

  * without any menu installer
  * without any automate script


!!this is an unofficial guide - plz blame only me!!


{{ToC from="h2" to="h4"}}


=== ~DownLoad iso & files === 

%%(bash)

wget -c http://ftp.otenet.gr/linux/archlinux/iso/latest/archlinux-2012.08.04-dual.iso
wget -c http://ftp.otenet.gr/linux/archlinux/iso/latest/archlinux-2012.08.04-dual.iso.sig
wget -c http://ftp.otenet.gr/linux/archlinux/iso/latest/md5sums.txt
wget -c http://ftp.otenet.gr/linux/archlinux/iso/latest/sha1sums.txt

%%

((#top))
-----------

=== Verify iso & Signature ===

%%(bash)

# md5sum archlinux-2012.08.04-dual.iso 
83f3b08a58ce7397ec760817de05d8cb  archlinux-2012.08.04-dual.iso

# sha1sum archlinux-2012.08.04-dual.iso
d5fb2364f9967e458984b8050724c749213152b2  archlinux-2012.08.04-dual.iso

# pacman-key -v archlinux-2012.08.04-dual.iso.sig 
gpg: Signature made Sat Aug  4 03:25:33 2012 EEST using RSA key ID 9741E8AC
gpg: Good signature from "Pierre Schmitz <pierre@archlinux.de>"

%%

((#top))
-----------

=== Write iso to usb ===

%%(bash)

# dd if=archlinux-2012.08.04-dual.iso of=/dev/sdb
786432+0 records in
786432+0 records out
402653184 bytes (403 MB) copied, 5.35343 s, 75.2 MB/s

%%

((#top))
-----------

=== Boot from usb ===

https://balaskas.gr/img/archlinux-2012.08.04/01.png

https://balaskas.gr/img/archlinux-2012.08.04/02.png

((#top))
-----------

=== Make partitions ===

==== GUID Partition Table (GPT)  ====

===== Using gdisk =====

if you want a GUID Partition Table (GPT) 
take a look on the below url if you would like to use gdisk: 

https://balaskas.gr/wiki/archlinux/gdisk


===== Using parted =====

if you want a GUID Partition Table (GPT) 
take a look on the below url if you would like to use parted: 

https://balaskas.gr/wiki/archlinux/parted


((#top))
-----------


==== MS-DOS/MBR Partition Table  ====

===== Using cfdisk =====

%%(bash)
cfdisk /dev/sda
%%

https://balaskas.gr/img/archlinux-2012.08.04/03.png

https://balaskas.gr/img/archlinux-2012.08.04/04.png


===== Using fdisk =====

find your disk

%%(bash)
fdisk -l | grep '^Disk'
%%


https://balaskas.gr/img/archlinux-2012.08.04/28.png

Fdisk your disk and print the partitions 

%%(bash)
fdisk /dev/sda

p
%%

https://balaskas.gr/img/archlinux-2012.08.04/29.png

Create your rootfs partition and make it bootable

%%(bash)
n
Primary/extended : [enter]
Partition number : [enter]
First sector : [enter]
Last sector : +25G
%%

%%(bash)
a
Partition number : 1
%%

https://balaskas.gr/img/archlinux-2012.08.04/30.png

Create your swap partition :

%%(bash)
n
p
2
[enter]
[enter]

%%

change type :

%%(bash)
t
2
82
%%

https://balaskas.gr/img/archlinux-2012.08.04/31.png

Verify your partition table and write table to disk:

%%(bash)
p
w
%%


https://balaskas.gr/img/archlinux-2012.08.04/32.png

confirm it via listing :

%%(bash)
fdisk -l /dev/sda
%%

https://balaskas.gr/img/archlinux-2012.08.04/33.png

((#top))
-----------

=== Format partitions ===

%%(bash)
mkfs.ext4 /dev/sda1 -L rootfs
%%

https://balaskas.gr/img/archlinux-2012.08.04/05.png


%%(bash)
mkswap /dev/sda2 -L swapfs
%%

https://balaskas.gr/img/archlinux-2012.08.04/06.png


((#top))
-----------

=== Mount root partition ===

%%(bash)
mount /dev/sda1 /mnt
%%

https://balaskas.gr/img/archlinux-2012.08.04/07.png

((#top))
-----------

=== Configure network ===

With the new 2012.08.04 archlinux installation media, you dont even need to configure your network if you are using dhcp.


%%(bash)
ip a

ip r
%%

https://balaskas.gr/img/archlinux-2012.08.04/08.png


But you are not using dhcp, the below commands must be applied 
Find a free IP address, before continue

%%(bash)
ip addr add 10.0.2.15/24 dev eth0

ip a

ip route add default via 10.0.2.2 dev eth0

ip r 


%%

https://balaskas.gr/img/archlinux-2012.08.04/09.png




((#top))
-----------

=== Prepare ~RootFS ===

%%(bash)
mkdir -pv /mnt/var/lib/pacman
%%

https://balaskas.gr/img/archlinux-2012.08.04/10.png



((#top))
-----------

=== Install Archlinux ===

%%(bash)
pacman -r /mnt -Sy base
%%

https://balaskas.gr/img/archlinux-2012.08.04/11.png


==== Select all packages ====

https://balaskas.gr/img/archlinux-2012.08.04/12.png

==== Packages are being downloaded  ====

https://balaskas.gr/img/archlinux-2012.08.04/13.png

==== Finished ====

https://balaskas.gr/img/archlinux-2012.08.04/14.png


==== ~CacheDir to disk ====

if you have problems with the ~130Mb size of download packages
then you have to create cachedir to your new environment 

%%(bash)
mkdir -pv /mnt//var/cache/pacman/pkg/
%%

and use an alternative installation command:

%%(bash)
pacman -r /mnt --cachedir /mnt//var/cache/pacman/pkg/ -Sy base
%%


https://balaskas.gr/img/archlinux-2012.08.04/48.png


((#top))
-----------

=== Pacman Keys ===

Signing Keys

%%(bash)
rsync -rav /etc/pacman.d/gnupg/ /mnt/etc/pacman.d/gnupg/
%%

https://balaskas.gr/img/archlinux-2012.08.04/47.png


((#top))
-----------

=== Chroot to your new enviroment ===

%%(bash)
mount --bind /dev /mnt/dev
mount --bind /sys /mnt/sys
mount --bind /proc /mnt/proc

chroot /mnt /bin/bash

%%

https://balaskas.gr/img/archlinux-2012.08.04/15.png



((#top))
-----------

=== Edit your fstab ===

%%(bash)
vi /etc/fstab
%%

%%
/dev/sda1    /    ext4   defaults    0    1
/dev/sda2    none    swap    defaults    0    1
%%

https://balaskas.gr/img/archlinux-2012.08.04/16.png



If you are want to use UUID instead, run 

%%(bash)
blkid
%%

before configure your **/etc/fstab** file

((#top))
-----------

=== ~HostName ===

Configure your hostname by this:

%%(bash)
echo myarch > /etc/hostname

%%

https://balaskas.gr/img/archlinux-2012.08.04/17.png



=== ~TimeZone ===

Configure your timezone 

%%(bash)
ln -s /usr/share/zoneinfo/Europe/Athens /etc/localtime
%%

https://balaskas.gr/img/archlinux-2012.08.04/18.png



=== Locale ===

%%(bash)
vi /etc/locale.gen
%%

eg.
%%(bash)
grep -E -v '^#|^$' /etc/locale.gen
el_GR.UTF-8 UTF-8
en_US.UTF-8 UTF-8
%%

and then 

%%(bash)
locale-gen

Generating locales ...
    el_GR.UTF-8 ... done
    en_US.UTF-8 ... done

%%

https://balaskas.gr/img/archlinux-2012.08.04/19.png


((#top))
-----------


=== Build initial RAM disk ===

%%(bash)
mkinitcpio -p linux
%%

https://balaskas.gr/img/archlinux-2012.08.04/20.png

https://balaskas.gr/img/archlinux-2012.08.04/21.png



((#top))
-----------

=== Install ~Grub2 ===

exit from your chroot 

%%(bash)
grub-install --boot-directory=/mnt/boot /dev/sda
%%

https://balaskas.gr/img/archlinux-2012.08.04/22.png

==== Create grub.cfg ===

%%(bash)
grub-mkconfig -o /mnt/boot/grub/grub.cfg
%%

https://balaskas.gr/img/archlinux-2012.08.04/23.png


==== Create Menu List ==== 

%%(bash)
vi /mnt/boot/grub/grub.cfg
%%


%%
menuentry "Archlinux" {
    set root=(hd0,1)
    linux /boot/vmlinuz-linux root=/dev/sda1
    initrd /boot/initramfs-linux.img
}
%%

https://balaskas.gr/img/archlinux-2012.08.04/24.png



((#top))
-----------

=== Reboot ===

https://balaskas.gr/img/archlinux-2012.08.04/25.png

https://balaskas.gr/img/archlinux-2012.08.04/26.png



==== Login ==== 

https://balaskas.gr/img/archlinux-2012.08.04/27.png

((#top))
-----------


=== Beginners' Guide ===

https://wiki.archlinux.org/index.php/Beginners%27_Guide

((#top))
-----------