Arch Linux
Published on
This is a description of how to setup a basic system with Arch Linux based on this guide. Infos on the Thinkpad T410 can be found here.
-
Change keyboard layout:
loadkeys de
-
Create partitions using
gdisk /dev/sda
.Type
n
to create these partitions with the default configurations except the mentioned ones:-
boot
- Last sector:
+250M
- Last sector:
-
swap
- Last sector:
+2G
- Hex code or GUID:
8200
- Last sector:
-
root
- Last sector:
+15G
- Last sector:
-
home
Type
p
to confirm andw
to write changes to the disk. -
-
Make filesystems
mkfs -t ext4 /dev/sda1 mkswap /dev/sda2 mkfs -t ext4 /dev/sda3 mkfs -t ext4 /dev/sda4
-
Mount
swapon /dev/sda2 mount /dev/sda3 /mnt cd /mnt mkdir boot home mount /dev/sda1 boot mount /dev/sda4 home
-
Install
pacstrap /mnt base base-devel gdisk
-
Generate
fstab
genfstab -p /mnt >> /mnt/etc/fstab more /mnt/etc/fstab
-
Bootloader
pacstrap /mnt syslinux
Configure it inside the new system.
arch-chroot /mnt bash
Write to
/etc/locale.conf
:LANG="en_US.UTF-8"
Uncomment in
/etc/locale.gen
:en_US.UTF-8 UTF-8 en_US ISO-8859-1 locale-gen
-
Timezone
ln -s /usr/share/zoneinfo/Europe/Berlin /etc/localtime
-
Set
/etc/hostname
-
Copy bootloader files
cd /boot/syslinux/ cp /usr/lib/syslinux/menu.c32 . cp /usr/lib/syslinux/vesamenu.c32 . cp /usr/lib/syslinux/chain.c32 . cp /usr/lib/syslinux/hdt.c32 . cp /usr/lib/syslinux/reboot.c32 . cp /usr/lib/syslinux/poweroff.com . extlinux --install /boot/syslinux dd conv=notrunc bs=440 count=1 if=/usr/lib/syslinux/gptmbr.bin of=/dev/sda
Altenative:
syslinux-install_update -iam
-
Setup ramdisk
mkinitcpio -p linux
-
Set root password
passwd
-
Exit system
exit exit
-
Unmount
umount /mnt/boot umount /mnt/home swapoff /dev/sda2 umount /mnt
Set legacy BIOS bootable on partition 1:
sgdisk /dev/sda --attributes=1:set:2 reboot
-
Configure network
dhcpcd
or for wifi
pacman -S net-tools wireless_tools wpa_supplicant wpa_actiond dialog
wifi-menu <interface>
use netcfg for network profiles
-
Add a user
useradd -m -g users -s /bin/bash <name> passwd <name>
-
Install sudo and make user a sudoer
pacman -S sudo
In
/etc/sudoers
add<name> ALL=(ALL) ALL
-
Log in
exit
-
Set default keyborad layout in
/etc/vconsole.conf
KEYMAP=de-latin1-nodeadkeys
-
Enable auto network configuration
sudo systemctl enable dhcpcd.service
-
Install X
sudo pacman -S xorg-server xorg-xinit xorg-server-utils
-
Install mesa (for 3d-graphics)
sudo pacman -S mesa
or nvidia driver
sudo pacman -S nvidia
or
nvidia-utils-bumblebee
andnvidia-bumblebee
for optimus and startgpasswd -a <username> bumblebee exit systemctl enable bumblebeed reboot
or for Intel
-
Virtualbox utils
sudo pacman -S virtualbox-guest-utils
Add to
/etc/modules-load.d/virtualbox.conf
vboxguest vboxsf vboxvideo
-
ZSH
sudo pacman -S zsh chsh -s $(which zsh)
settings in
.zshrc
autoload -U compinit promptinit compinit promptinit # This will set the default prompt to the walters theme prompt walters
-
xfce
sudo pacman -S xfce4 xfce4-goodies
copy
cp /etc/skel/.xinitrc ~/.xinitrc
add line
exec startxfce4