Skip to content

Void Linux

Reference guide for Void Linux covering package management, runit service management, and networking.

Void Linux Handbook

Package Management

Void Linux uses xbps as its package manager.

Install a package (sync repos + install)
xbps-install -S <package>
Update all packages
xbps-install -Su
Search for a package
xbps-query -Rs <keyword>
List installed packages
xbps-query -l
Show package info
xbps-query -S <package>
Remove a package
xbps-remove <package>
Remove a package and its orphaned dependencies
xbps-remove -R <package>
Reconfigure all packages
xbps-reconfigure -fa

Runit Services

Void Linux uses runit for service management. Services are enabled by symlinking them into /var/service/:

Enable core services
ln -s /etc/sv/dbus /var/service/
ln -s /etc/sv/iwd /var/service/
Check service status
sv status dbus
sv status iwd

DHCP for Wireless Interface

Copy the default dhcpcd service template for your wireless interface:

Create a dhcpcd service for wlp2s0
cp -r /etc/sv/dhcpcd-eth0 /etc/sv/dhcpcd-wlp2s0

Edit the run script to reference the correct interface:

/etc/sv/dhcpcd-wlp2s0/run
#!/bin/sh
exec dhcpcd -B wlp2s0
Enable and start the service
ln -s /etc/sv/dhcpcd-wlp2s0 /var/service/
sv up dhcpcd-wlp2s0

Essential Packages

Install useful packages
xbps-install -S vim htop lm_sensors zellij fastfetch alsa-utils

Timezone

Set timezone to Asia/Tokyo
ln -sf /usr/share/zoneinfo/Asia/Tokyo /etc/localtime

DNS

If DNS is not working after connecting to WiFi, set a resolver manually:

/etc/resolv.conf
nameserver 1.1.1.1