Notes to self about reinstalling Arch Linux
I got a new 500 GB SSD drive for my laptop, so I'm installing Arch on it.
Before installation, copy all of ~ to my network drive:
cp -rpP .
Turns out my network drive doesn't support the 'p' option, so no timestamps were saved. Note also that this command copies everything, including all the dot files and the 35GB of crap that was in the trash folder that I forgot about.
Burn the latest Arch installation .iso to a DVD. The file is a little too large for a CD.
Remove the old hard drive, install the new one.
Insert the Arch installation disk, reboot.
Choose 'Boot Arch Linux'. This gets to a command prompt as root.
Check the networking, just ping google or somewhere, it should just work.
Partition the drive. Partition plan:
/dev/sda1 ext4 / 50 GB
/dev/sda2 swap 1 GB
/dev/sda3 ext4 /home All remaining space
I used fdisk to create the partitions. Before creating the above partitions, use the 'o' option to create an MBR sector. All 3 were set as primary partitions. Use the 'a' option to set /dev/sda1 as bootable.
Format the partitions:
mkfs -t ext4 /dev/sda1
mkfs -t ext4 /dev/sda3
Mount the partitions:
mount /dev/sda1 /mnt
mount /dev/sda3 /mnt/home
Base Arch installation:
pacstrap /mnt base base-devel
This takes a while.
genfstab /mnt >> /mnt/etc/fstab
Check it with
There should be an entry for / and one for /home.
Chroot into the new system:
Set the timezone:
ln -s /usr/share/zoneinfo/US/Mountain /etc/localtime
Set the hardware clock:
hwclock -systohc --utc
Set the locale:
Find the line with en_US.UTF-8 and uncomment it, then save the file and
Set the LANG variable:
echo LANG=en_US.UTF-8 > /etc/locale.conf
I actually set the locale much later when I found out that Perl whines non-stop about it.
Set the hostname:
echo deadlock > /etc/hostname
Update /etc/hosts and add an entry for deadlock.
Set the root password:
pacman -S grub-bios
grub-mkconfig -o /boot/grub/grub.cfg
Unmount the partitions:
exit (gets out of chroot environment)
reboot (leave the installation disk in)
When the Arch installation choices come up, choose boot from existing OS.
Turn on dhcp:
systemctl enable dhcpcd
Then reboot again, but this time remove the Arch installation disk first.
pacman -S alsa-utils
pacman -S xorg-server xorg-server-utils xorg-xinit
pacman -S xfce4 xfcd4-goodies
lightdm: (display manager, starts xfce and asks for username/password)
pacman -S lightdm
systemctl enable lightdm.service
add myself as a user:
uncomment the line %wheel ALL=(ALL) ALL, save
useradd -m -g users -G storage,power,wheel -s /bin/bash danson
Reboot. The system should come up with the new lightdm display manager asking for a user name and password.
Copy all the files from the network drive to ~.
Spend the next couple of weeks installing and configuring stuff, like there aren't any printers, ssh isn't available yet, java needs installed, etc.
Update 12 Sep 2016:
I realized I didn't install the wireless network stuff. The kernel driver is already installed, so first, add me to the 'users' group:
gpasswd -a danson users
Log out and log back in for this to take effect. Install wicd and the gtk gui:
pacman -S wicd wicd-gtk
systemctl start wicd
Have wicd start on start up:
systemctl enable wicd
Kill and disable dhcpcd:
kill -9 dhcpcd
systemctl disable dhcpcd
Update 19 Sep 2016:
The touchpad is wonky. I've been using a regular mouse, so didn't notice this until I was traveling for a few days.
pacman -S xf86-input-synaptics
Create /etc/X11/xorg.conf.d/70-synaptics.conf with this content:
Option "TapButton1" "1"
Option "TapButton2" "3"
Option "TapButton3" "2"
Option "VertEdgeScroll" "on"
Option "VertTwoFingerScroll" "on"
Option "HorizEdgeScroll" "on"
Option "HorizTwoFingerScroll" "on"
Option "CircularScrolling" "on"
Option "CircScrollTrigger" "2"
Option "EmulateTwoFingerMinZ" "40"
Option "EmulateTwoFingerMinW" "8"
Option "CoastingSpeed" "0"
Option "FingerLow" "30"
Option "FingerHigh" "50"
Option "MaxTapTime" "125"
Log out and log back in (or otherwise restart X)