Void Linux
Installation
Live CD
The installation process is pretty staightforward. Boot a live image and run
void-installer
This should take care of the most basic installation tasks and will leave us with a bootable Void Linux installation.
Xen DomU
One can also install Void Linux as a Xen DomU. The ROOTFS images can be used for that:
lvcreate -L 2G -n void-root vg0 mkfs.ext4 /dev/vg0/void-root tune2fs -e remount-ro -c 20 -i 6m /dev/vg0/void-root mount -t ext4 /dev/vg0/void-root /mnt/disk/ tar -C /mnt/disk/ -xvJf void-x86_64-musl-ROOTFS*.tar.xz
The tricky part was how to get the correct initrd
in place so that we can actually boot the domain.
for d in /dev /proc /sys; do mount --bind ${d} /mnt/disk/${d}; done chroot /mnt/disk/
Now, in the chroot
, we'll install a kernel and tools to generate an initrd
:
% xbps-install linux5.6 cpio dracut % ls -d /boot/vm* /lib/modules/* /boot/vmlinuz-5.6.6_1 /lib/modules/5.6.6_1 % mkinitrd /boot/initramfs-5.6.6_1
With these files now present, we can exit the chroot
, copy both kernel and initrd
and configure our domain accordingly:
$ grep -A3 ^type /etc/xen/tor.cfg type = "pvh" kernel = "/var/local/vm/tor/vmlinuz" ramdisk = "/var/local/vm/tor/initramfs" extra = "root=/dev/xvda rootfstype=ext4 console=hvc0 nomodeset"
Post Install
They even have an article on Post Installation tasks. Let's install and configure some packages:
xbps-install -Sv acpi base-system checksec cryptsetup grub haveged lm_sensors pv pwgen spectre-meltdown-checker thermald wget
Enable some services - adjust as needed:
for s in acpid haveged sshd thermald; do ln -s /etc/sv/${s} /var/service/; done
After a service is enabled, it should already be running:
$ sv status acpid haveged sshd thermald run: acpid: (pid 866) 1s run: haveged: (pid 2823) 1s run: sshd: (pid 862) 2s down: thermald: 0s, normally up, want up
Update
As Void Linux is implemented as a rolling release, we can use xbps (X Binary Package System) to update the system:
xbps-install --sync --update --verbose
For some reason Void Linux appears to leave old kernel images and modules in place, but provides a tool to remove them too:
$ vkpurge list 4.19.13_1 4.19.18_1 4.19.6_1 $ uname -r 4.19.25_1 $ vkpurge rm all