Frequently Asked Questions

From Void Linux Wiki
Jump to: navigation, search

The basics

Is Void an Arch Linux fork?

No.

Is there a 'Stable' version of Void?

As a rolling release distribution, there are no "stable" freezes. You may choose what to update and when, and you may put packages on hold (refuse upgrades for specific packages, see XBPS), but bear in mind that upgrading some packages will occasionally require their dependencies be upgraded as well.

Installation and configuration

How should I partition my disk?

Note that Void (on x86/x86_64) keeps old kernels around, this takes about 20 MB per kernel version, so plan /boot accordingly. 20-30 GB for / is probably a good fit for an expansive desktop installation.

The installer sucks, how can I do $SPECIALTHING on installation?

You can install Void manually if you wish, see for example Install LVM LUKS or http://bougyman.voidlinux.com/void-install.sh.txt (used on Vultr and VPSie (kvm) vps's).

How can I change my users default shell?

Use chsh -l to list available shells and change it with chsh for the current user or chsh root for root or another specific user.

How do I remove old kernels?

Void Linux provides the vkpurge tool for the sole purpose of listing and removing old kernels. To list the old kernels in your system:

$ vkpurge list

To remove a specific version:

# vkpurge rm 3.8.2_1

To remove all kernels except the latest one:

# vkpurge rm all

How can I load kernel modules at boot?

To load kernel modules at boot time, a .conf file must be created in /etc/modules-load.d:

# load virtio-net
virtio-net

Multiple modules can be specified separated by newlines:

# load virtio-net virtio-pci
virtio-net
virtio-pci

How do I blacklist kernel modules?

There are two ways of accomplishing this. The first one involves creating a .conf file in /etc/modprobe.d:

# blacklist radeon
blacklist radeon

If the module being blacklisted is also available in the initramfs, don't forget to omit the module from dracut creating a file in /etc/dracut.conf.d, then rebuild the initramfs:

# blacklist radeon
omit_drivers+=" radeon "
$ dracut --force

The second method involves using the modprobe.blacklist variable in the kernel command line, like this:

... modprobe.blacklist="radeon snd-hda-intel" ...

How to get rid of "ataN: softreset failed (device not ready)" ?

Add libata.force=norst to your kernel parameters or compile your kernel with CONFIG_SATA_PMP=n.

How do I set up/start/stop services?

To list current running services:

# sv status /var/service/*

To enable a service to be started at boot time and start it in less than 5 seconds:

# ln -s /etc/sv/<foo> /var/service

To start a service (must be symlinked first):

# sv start <foo>

To stop a service:

# sv stop <foo>

To setup a service but not run it at boot time, create a file named down in the service directory:

# touch /var/service/<foo>/down

The service can still be started manually.

See also: runit

Packages

Which package contains XYZ?

$ xbps-query -Ro '*XYZ*'

If you need this more often, xlocate from the xtools package provides a caching database:

$ sudo xbps-install -Su xtools
$ xlocate -S
$ xlocate XYZ

Use man xtools after installation for more info about the commands provided by xtools.

How do I get a list of installed packages?

An example command line to get a list of all installed package names without their version is:

xbps-query -l | awk '{ print $2 }' | xargs -n1 xbps-uhelper getpkgname | fmt

This list can be used to e.g. install your package selection on another machine.

See also: xbps-query

I want to downgrade a package!

You can try using the xdowngrade script from the xtools package, like

xdowngrade /var/cache/xbps/youtube-dl-2015.07.07_1.noarch.xbps

I installed $PKGNAME and it's not in my $PATH!

Packages like openjdk-jre provide a file located at /etc/profile.d/10_openjdk.sh that sets up the right environment variables. It's necessary to re login or source your profile again after installing a package that needs environment variables set.

Development

Valgrind needs glibc-dbg, which cannot be found. Help?

Install void-repo-debug and retry. See also Subrepositories.

How do I check template files for common errors?

Use xlint from the xtools package.

Why...?

... doesn't $MANWIDTH change the man pages' width?

That's because Void Linux uses Wikipedia-logo.png Mandoc (formerly known as mdocml) by default instead of man-db. Users who wish to use man-db can install the man-db package through XBPS.

To change the default width of man pages, open the file /etc/man.conf in your editor of choice and append this line to the end of the file:

option width 200

You can substitute 200 with the maximum number of columns a line should be long. 200 is a good value for 1080p displays; the default is 78. Save the file and test the changes with man man.

If you want to preview your changes without changing man.conf, just execute the following command: man man | fmt -w 200. Change 200 to your preferred value.

... is tar/Engrampa/XYZ unable to unpack *tar.xz archives?

If you keep getting

tar: Child returned status 2
tar: Error is not recoverable: exiting now

while trying to unpack a *tar.xz archive with tar or your favourite unpacker fails to open these archives, that's because you need to install xz, the package with the xz compression utilities. A simple

# xbps-install xz

will sort this out for you.

... isn't my gamepad detected by some apps (e.g. supertux2)?

Make sure you are in the input group by executing the command getent group. If you're not in the group, execute the command usermod -a -G input user replacing user with your username. This isn't necessary on systems using elogind.

... isn't a newly packaged kernel immediately offered by XBPS for installation?

Void Linux developers wait usually a bit until it is set as the new default for the linux meta package, and this usually depends on dkms modules and stability. It's up to the package maintainer to decide when the update becomes the new default, but you are free to install it by explicitely telling XBPS about the package. You are doing that at your own risk, though.

How...?

... do I add an user account?

Besides root, an user account with access to sudo (and thus able to gain root privileges) is created as part of the installation process when you use the installer. However, if you installed Void Linux manually or you fiddled with the default groups assigned to this account in the installer (which includes wheel) you might need to create another account. In fact, some Void software might run into problems if only the root account exists.

To create another user account using the console you do this as root:

# useradd -m john
# passwd john
...  ← here you enter the password for the new "john" account

See the man pages for useradd, usermod and passwd for more info.

Some DEs like Cinnamon or MATE come with a suitable GUI based application for this task so you don't have to use the console if you don't like to.

See also: Post installation

... do I set up my locale?

If your DE of choice doesn't come with an editor for this job, you can always use the console. To see a listing of available locales:

$ locale -a

To set up a locale for your system:

# echo "LANG=es_ES.UTF-8" > /etc/locale.conf

If your locale is not available in the locale -a output, edit /etc/default/libc-locales and uncomment the one you need. After that, rebuild the GNU libc locales:

# xbps-reconfigure -f glibc-locales

... do I set the timezone?

Again some DEs come with an editor for this job, but in case you need/want to use the console, you can set your timezone like this:

# echo 'TIMEZONE="Europe/Madrid"' >> /etc/rc.conf

To set up RTC to be in local time rather than UTC:

# echo 'HARDWARECLOCK=localtime' >> /etc/rc.conf

See hwclock(8) for more information.

... do I suspend/hibernate/shutdown/reboot the system using the console?

Use zzz to suspend your system to RAM, or ZZZ to suspend to disk (hibernation). To shut down (power off) the system use shutdown -h now. To reboot, use shutdown -r now or just reboot. All these commands require root privileges.

See also halt(8), shutdown(8), zzz(8)

... do I make my NTFS partitions writable?

By default, NTFS partitions are mounted as read-only in Void Linux. This may lead to problems if you have e.g. a VirtualBox disk image stored in such a partition; VirtualBox will complain that the image is read only and will refuse to open it.

The simplest way to solve this matter is to install the ntfs-3g package, like thus:

# xbps-install ntfs-3g

After the next reboot, your NTFS partitions will be both readable and writable, and you also gain extra utilities that enable you to e.g. relabel NTFS partitions. See ntfs-3g(8) for more info about ntfs-3g.

Other help resources

Is there a Void Linux mailing list?

Yes, at https://groups.google.com/forum/#!forum/voidlinux