Void linux установка пакетов

Installation

This section includes general information about the process of installing Void. For specific guides, see the «Advanced Installation» section.

Base system requirements

Void can be installed on very minimalist hardware, though we recommend the following minimums for most installations:

Architecture CPU RAM Storage
x86_64-glibc x86_64 96MB 700MB
x86_64-musl x86_64 96MB 600MB
i686-glibc Pentium 4 (SSE2) 96MB 700MB

Note that flavor installations require more resources; how much more depends on the flavor.

Void is not available for the i386, i486, or i586 architectures.

Before installing musl Void, please read the «musl» section of this Handbook, so that you are aware of software incompatibilities.

It is highly recommended to have a network connection available during install to download updates, but this is not required. ISO images contain installation data on-disk and can be installed without network connectivity.

Downloading installation media

The most recent live images and rootfs tarballs can be downloaded from https://alpha.de.repo.voidlinux.org/live/current/. They can also be downloaded from other mirrors. Previous releases can be found under https://alpha.de.repo.voidlinux.org/live/, organized by date.

Verifying images

Each image release’s directory contains two files used to verify the image(s) you download. First, there is a sha256sum.txt file containing image checksums to verify the integrity of the downloaded images. Second is the sha256sum.sig file, used to verify the authenticity of the checksums.

It is necessary to verify both the image’s integrity and authenticity. It is, therefore, recommended that you download both files.

Verifying image integrity

You can verify the integrity of a downloaded file using sha256sum(1) with the sha256sum.txt file downloaded above. The following command will check the integrity of only the image(s) you have downloaded:

This verifies that the image is not corrupt.

Verifying digital signature

Prior to using any image you’re strongly encouraged to validate the signatures on the image to ensure they haven’t been tampered with.

Current images are signed using a signify key that is specific to the release. If you’re on Void already, you can obtain the keys from the void-release-keys package, which will be downloaded using your existing XBPS trust relationship with your mirror. You will also need a copy of signify(1); on Void this is provided by the outils package.

To obtain signify when using a Linux distribution or operating system other than Void Linux:

  • Install the signify package in Arch Linux and Arch-based distros.
  • Install the signify-openbsd package in Debian and Debian-based distros.
  • Install the package listed here for your distribution.
  • Install signify-osx with homebrew in macOS.

If you can’t obtain signify for some reason (e.g. you are on Windows and can’t use WSL or MinGW), you can use minisign(1) to verify the file.

If you are not currently using Void Linux, it will also be necessary to obtain the appropriate signing key from our Git repository here.

Once you’ve obtained the key, you can verify your image with the sha256sum.sig file. The following example demonstrates the verification of the GCP musl filesystem from the 20191109 release:

If the verification process does not produce the expected «OK» status, do not use it! Please alert the Void Linux team of where you got the image and how you verified it, and we will follow up on it.

For verification with minisign , it is necessary to rename the sha256sum.sig file to sha256sum.txt.minisig and remove the first line from the .pub release key. The following example demonstrates the verification of the sha256sum.txt file from the 20191109 release:

The same warning as above applies. If the verification process isn’t successful, do not use the file — warn the Void Linux team about it.

Источник

Post Installation

This article provides a list of basic functions to perform after finishing the installation of Void.

(If you cannot login after doing an install from a GUI Live ISO, you may need to create an account from a virtual console first. CTRL + Alt + F2 should get you to one where you will be able to create the account as documented below. After that you should see that user account listed on the login page.)

Contents

Updates

After installation, the first thing you should do on your new void system is update your remote repository information and update your installed packages. This is especially important if you used the Local source during installation – it is highly likely that at least some of your packages will be out of date. To update all packages to the most recent version, run:

Repeat this command until there are no more updates. After updating your system, you may want to reboot depending on the updates installed (such as kernel updates).

In the event that there is no network connection e.g. need to set up wireless, proceed to the network section below and return.

Setting a keymap

To see all available keymaps on your system, run:

To configure the console keymap, modify /etc/rc.conf with your keymap code. Using the results from the above command, remove the .map.gz suffix and assign it like this (for example, using the «Español» keymap):

which becomes active after the next reboot. If you just want to change the keymap ad hoc, the loadkeys utility can be used:

Xorg keymap (Optional)

If you install Xorg, then that has its own settings for keyboard layout.

While the default keyboard layout can be overriden by running setxkbmap in a user’s .xinitrc , or during session startup (depending on DE/WM used), this can be globally set by adding configuration snippets to /etc/X11/xorg.conf.d/ (thus should work regardless of whether one uses a login manager or starts X from a logged-in console).

A note on the Driver option: In recent Xorg versions, it seems that this is not necessary. If a driver is listed, then Xorg will use it if it exists, otherwise it will use whatever module is available for keyboards. The layout settings will still be applied. (Previously, incorrectly selecting the driver could leave you without keyboard input in Xorg).

Also note that if multiple keyboard layouts are to be switched between, the line

will allow you to switch between multiple layouts by pressing both Left Shift and Right Shift keys simultaneously.

Keyboard layouts are defined in /usr/share/X11/xkb/symbols/ and multiple variants of a language/layout are defined in one file.

Services

Now is a good time to customize the running services. Void uses Runit as an init and service supervisor. Since the settings were most likely copied from the live system, there are possibly a few services running that you do not really need. Check the contents of /var/service and consider if you need each service. If you do not know or are unsure about a particular service, better leave it in place. These are relatively safe bets:

  • You probably won’t need 6 TTYs, so you can safely delete some of the higher-numbered agetty-ttyX entries. Just make sure you leave at least agetty-tty1
  • You only need mdadm if you are using software RAID
  • If you do not plan to connect to this system via SSH from another computer, you can remove sshd
  • If you are using a static network configuration you can (and should) remove dhcpcd

A selection of possible firewall services and associated packages to add is discussed at Firewall Configuration.

Seat management

Install elogind and enable elogind, polkit and dbus services if not done already.

Network

If your network provides configuration via DHCP, the default setup should already work fine. If not you may need to enable the dhcpcd service first:

If you need a static configuration, first get the necessary data:

  • Network interface name. We’ll be using «enp0s3» in this example. The name can be obtained from the output of ip link on your system.
  • IP-Address, eg «192.168.1.2»
  • Network mask, eg «255.255.255.0»
  • Broadcast Address, eg «192.168.1.255»
  • Gateway address, eg «192.168.1.1»

When you have the data, put these lines into /etc/rc.local and adapt them to your settings:

Now, after you reboot, you should have a working network connection.

Wireless-only access

If you only have access to wireless, you will have to connect through wpa_supplicant.

First you need to find the wireless interface name. It is most likely wlp2s0, and that name will be used for the following examples. However you can check the interface name with:

Next you need to find the ssid (the name) of the available wireless networks:

After you have picked the network you want, we must generate a configuration for it and add that to /etc/wpa_supplicant/wpa_supplicant.conf .

To generate a new configuration you must run:

where is replaced by the actual network name, and is replaced by the real password.

Finally, to actually connect you must run:

You should now have a working wireless connection.

User Account

The next step, if only the root account exists, is to create an additional user account, put it into all the appropriate groups and set a password for it.

First, create a user using the useradd command. The below example creates a user named voiduser, sets the user’s default shell to bash , and adds the user to the wheel, users, audio, video, cdrom, and input groups:

Next, set the user’s password using passwd :

To allow this user (and other administrators) system access via the sudo command, you need to configure that behaviour. Edit /etc/sudoers by running

and uncomment this line:

Graphical User Interface

At this point you have a fully functional Void Linux environment and a regular user account to use it. Unless you installed Void with a DE already on top (in which case you can skip this and probably also the next section altogether), the next step is generally to setup a GUI. Void uses Xorg to provide a graphical environment. Please see the Xorg page for more information on installing and configuring Xorg.

The following steps will help you get a basic XFCE setup running. You can choose any desktop environment or window manager you want; the steps are essentially the same for each one. The following commands assume you are logged in as root.

Install Xorg

The xorg package is a metapackage that installs pretty much everything closely related to Xorg. This will give you a quick start but will also clobber your system with many unneeded packages. xorg-minimal is another metapackage with fewer dependencies, e.g. without any video drivers.

Quick start with Xorg:

Or, you can install xorg-minimal instead if you own e.g. an Intel-based notebook. This will suffice to continue with installation of a desktop environment:

Note that xf86-video-intel is not required on Sandy Bridge-based processors or newer.

Install a Desktop Environment

In this example, we will install xfce4. Other options include LXQT, Mate or even just a window manager like bspwm. See Desktop Environments.

As root (or sudo):

It is recommended you only run a DE/WM as a regular user, and not as root. Many DEs will warn you of the danger, but will also allow you to do so at your own risk, if you so insist.

To configure a global xkbmap, see the above section Xorg keymap.

If you want to override the default X keymap on a per-user basis, create and edit the file .xinitrc in the user’s home directory, and put these lines at the end:

Lastly, run startx to start an Xfce4 session. If you did not override the global X keymap, then you may simply run startxfce4 . Some DEs will work this way, some will not (for instance, LXQT should be launched via your .xinitrc if not launching from a GUI login manager).

ConsoleKit and ck-launch-session

If you want to use dbus and ConsoleKit2, in .xinitrc replace

if you do not do that, programs utilizing dbus and ConsoleKit2 will not work, like the Browse Network feature of Thunar .

Display Manager

Now that you have such a pretty GUI, you might find it tedious or ugly to login on the console and run startx every time. In that case, you can install a display manager that takes care of that much more fashionably. In this example we will use LightDM. For this to work you also need to enable the dbus service:

Below is a sample .xinitrc file you can tweak and put in your home directory (

) to help configure xorg , automatically start a desktop environment, etc.:

Adjust screen brightness

If you just installed Void on a desktop computer, chances are that screen brightness is too high. This is especially noticeable on web browsers, where white backgrounds look too bright and mild greys are virtually white too.

Manually, when X11 is not present

To change the brightness of the screen manually, edit /sys/class/backlight/*/brightness , for example, using vi(1) :

The content of /sys/class/backlight/*/brightness should be an integer >= 0 With a script, when X11 is not present

If a POSIX-compliant shell is being used, save the following script, for instance, as

Or if ion shell is being used, save the following script instead:

Run it in CLI mode using:

Or by passing an integer argument to it. For example, to change the brightness to 10:

When X11 is used

If you use an X11-based window manager or desktop environment, you can address this matter with the xrandr(1) command. First off, run it without arguments to check and identify the available displays:

On a dual monitor setup this might return something like

Following this example and assuming we want to reduce brightness on our HDMI monitor to 80% of the nominal (max) value, we might do this:

This is a temporary change and will be lost upon the next reboot. To have the change automatically applied on startup, you should add the command as a startup application. The procedure varies depending on the DE you are using:

Cinnamon Start menu → System Settings → Preferences → Startup Applications
LXDE Applications and Settings → Preferences → Default applications for LXSession → Autostart (left sidebar)
MATE System → Control Center → Startup Applications
XFCE Start menu → Session and Startup → Application Autostart

If you are not using a desktop environment, the command should be specified in $HOME/.xinitrc .

Audio

ALSA channels have to be unmuted manually. First install alsa-utils :

Unmute the desired channels with alsamixer:

Use the arrow keys to select a channel and the m key to unmute it. Muted channels are indicated by a MM label.

Setting up Polkit

Allow users to shutdown without a password

via ConsoleKit/Polkit

If you are using a Desktop Environment/Session Manager that makes use of ConsoleKit -such as XFCE, Cinnamon, or LXQT- then you have the ability to shutdown by using those environments’ built-in logout/shutdown interfaces.

The default Polkit rules for ConsoleKit actions already allow any user to perform shutdown/suspend actions without any extra privileges on single-user systems (when other users are not logged in). On systems with multiple users logged in, the default is that only root can do this (and thus end all users’ login sessions). These defaults can be overriden by rules added to /etc/polkit-1/rules.d/ . See Polkit documentation for rules syntax at FDO or check polkit(8) .

If using a login manager such as lightdm or lxdm, the login manager will usually launch your chosen DE with ConsoleKit support, and things should «just work» out of the box.

However, if starting your DE from a console login without a DM, you may need special setup or command options for your DE’s session to connect to ConsoleKit. This will vary between DEs.

For instance, XFCE4 should be launched with the command startxfce4 —with-ck-launch or by having XFCE4_SESSION_WITH_CK in your environment when you run startxfce4. LXQT can be launched by adding exec ck-launch-session startlxqt to the end of your .xinitrc and running startx.

via sudo

This is the simplest method to give any group of users the ability to shutdown/restart without entering a password and can be useful for simpler WMs that don’t talk to ConsoleKit2, but instead allow users to customize menu actions, such as OpenBox. This requires commands be prepended with sudo.

To allow members of the group «wheel» to shutdown without a password, use this line:

via ConsoleKit/Polkit with dbus-send

It is also possible, if you really wanted to, to use Consolekit in these instances as well by using less-friendly (and less memorable) dbus-send commands for poweroff actions instead of sudo commands:

Regional Repository (Suggested)

Switching from the system default repository in Germany to another official repository nearer to you (see listing) will help relieve the workload on the main server and may speed your system updates. See this guide.

Troubleshooting

My hardware isn’t showing up!

If you have issues with hardware and it doesn’t appear with dmesg, you may need to install the linux-firmware and/or linux-firmware-network packages:

What’s next?

To further customize your new Void system, you should have a look at our Guides.

Источник

Читайте также:  Acdsee mac os аналоги
Оцените статью