Archlinux Installation

preparation

開VM
指定archlinux installation DVD disk

1
2
3
4
5
6
7
8
cgdisk /dev/sda
primary /dev/sda1 bootable 83 linux
primary /dev/sda2 82 swap
mkswap /dev/sda2
mkfs.ext4 /dev/sda1
mount /dev/sda1 /mnt
nano /etc/pacman.d/mirrorlit
最前加上 Server=http://archlinux.cs.nctu.edu.tw/$repo/os/$arch

installation

1
2
3
~~pacstrap /mnt base base-devel brub~~
pacstrap /mnt base
genfstab -p -U /mnt > /mnt/etc/fstab

setup

1
2
3
arch-chroot /mnt
echo "archserver" > /etc/hostname
ln -s /usr/share/zoneinfo/Asia/Taipei /etc/localtime

lang

1
2
3
4
5
6
vi /etc/locale.gen
en_us.UTF-8 UTF-8
zh_TW.UTF-8 UTF-8
zh_CN.UTF-8 UTF-8
vi /etc/locale.conf
LANG="en_us.UTF-8

make boot image

1
mkinitcpio -p linux

setup brub

1
2
3
4
pacman -S grub-bios
modprobe dm-mod
grub -install --recheck /dev/sda
grub-mkconfig -o /boot/grub/grub.cfg

setup

1
passwd

finalize & reboot

1
2
3
exit
umount -R /mnt
reboot

after reboot check swap

1
2
3
cat /proc/swaps
~~swapoff -a; swapon /dev/sda2~~
echo "/dev/sda2 none swap default 0 0" >> /etc/fstab

install X11

1
2
3
pacman -S xorg-twm xorg-xclock xterm
~~xinit~~
startx

install KDE

1
2
~~pacman -S kde~~
#pacman -S kde-meta-* 要查一下