Table of Contents

This page is still in progress, so please dont aprove this draft yet! (very very WIP¿?)

TODO

We might need to change template, some suggestions:

And we might need toggle plugin

In orther to make this page as user consumable as possible

The Installation Guide

The intention of this reference Guide is to assist users in the process of installing Hyperbola GNU/Linux-libre from the live system booted with the official installation image. This page assumes you have some level of experience with GNU/Linux systems and utilities, especially with the command line. If you'd like a assited, step-by-step guide through the installation process, see the Beginners guide. Before beginning, we recommend you also check our Frequently Asked Questions, the Arch FAQ, and employ the man command to read the man page of any command they are not familiar with. The Hyperbola wiki (known as HyperWiki), as well as the ArchWiki, should be the primary source of information and your first resource during trouble-shooting.

Create bootable image

Download live image

Make sure to change your BIOS settings so that your computer will boot from your optical disk or USB stick.

Download the new Hyperbola ISO from the download page.

Verify the live image

Once you have downloaded the Live image as described you should verify it following:

This page explains how to verify their integrity and authenticity.
Preparation
  1. Create a directory called live_image in your home directory.
  2. Move the live image you downloaded in this directory.
  3. Download the following files and move them into the live_image directory.
Hyperbola live image

File Description
hyperbola-milky-way-v0.4.4-dual.iso.sha512 Contains the SHA512 sums to check the integrity of the Hyperbola live image.
hyperbola-milky-way-v0.4.4-dual.iso.sha512.sig Signed by the Hyperbola team to check the authenticity of the sha512sum file of the Hyperbola live image.

Your live_image directory should now contain 3 files: Your live image and the sha512 file and the signed one, like this:

  • hyperbola-milky-way-v0.4.4-dual.iso
  • hyperbola-milky-way-v0.4.4-dual.iso.sha512
  • hyperbola-milky-way-v0.4.4-dual.iso.sha512.sig
Integrity check

To verify the integrity of your live image, generate its SHA512 sum and compare it to the one found in the sha512sum file.

In most GNU/Linux distributions the SHA512 sum can be generated by opening a terminal and running the following commands:

cd
cd live_image
sha512sum -b *.iso

The last command should show you the SHA512 sum of your live file. Compare it to the sha512sum file. If it match, you've successfully verified the integrity of your live image.

If you have coreutils version 8.25 or newer, another way of checking the sum is to ask the sha512sum command to check the file against the sha512sum file, like this:
sha512sum -c hyperbola-milky-way-v0.4.4-dual.iso.sha512
Authenticity check

To verify the authenticity of the sha512sum file, we need to check the signature on the signed file.

Import the Hyperbola signing key:

gpg --keyserver keyserver.ubuntu.com --recv-key "C92B AA71 3B8D 53D3 CAE6 3FC9 E697 4752 F970 4456"
If gpg complains about the key ID, try the following commands instead:
gpg --keyserver keyserver.ubuntu.com --recv-key F9704456
gpg --list-key --with-fingerprint F9704456

Check the output of the last command, to make sure the fingerprint is C92B AA71 3B8D 53D3 CAE6 3FC9 E697 4752 F970 4456.

Verify the authenticity of the sha512sum file, like this:

cd
cd live_image
gpg --verify hyperbola-milky-way-v0.4.4-dual.iso.sha512.sig

The output of the last command should tell you that the file signature is 'good' and that it was signed with the following key: F9704456.

Acknowledgement

This wiki article is based on Mint's download page. We may have removed non-FSDG bits from it.

2017/09/27 01:49

.

Writing a Hyperbola ISO image to an USB drive

Burn the image to your optical disk

To create a disk to use as your install medium, insert a blank or re-writable disk, CD or DVD, into your disk drive. Next, you will need to mount the disk.

# mount sr0

Provided your computer has a disk drive. Sr0 should the first or only, if you only have one disk drive, mount point of disk drives. You will need to address the correct destination for the command to work.

# dd if=~/hyperbola-milky-way-v0.2.1-dual.iso of=/dev/sr0 bs=2048 conv=noerror && sync

Write the image to your USB

If you don’t have an ISO writer, go (change directory) to the folder where you saved the downloaded Live image (probably the Downloads folder) and type the following into your terminal:

# dd if=hyperbola-milky-way-v0.2.1-dual.iso of=/dev/sdb bs=2048 && sync
Usually works fine, even though I’ve seen other commands; feel free to modify it.

To find out what’s the name of the USB device, type fdisk -l

You’ll probably see something like this:

Device             Boot    Start                  End              Sectors               Size        Id    Type
/dev/sda1                    2048                   8390655       8388608              4G           82    Linux swap /Solaris
/dev/sda2       *          8390656             976773167  968382512          461,8G   83    Linux
Device             Boot    Start                 End              Sectors                Size        Id    Type
/dev/sdb1       *           0                         1255423      1255424               613M      0     Empty
/dev/sdb2                     172                    63659           63488                   31M        ef    EFI (FAT-12/16/32)

From the above, sda is your HDD, and the sdb is your USB device where you’re going to write your Live image.

Also take a note of your partitions, you will come to need it when you’re creating the file system and mounting the root partition during the installation.

Once you’ve downloaded, verified and written the Live image to your USB device, you can move on to boot your computer from your USB.

# dd if=''[iso file]'' of=''[usb device file]'' bs=1M && sync
[iso file] is the path to the ISO image file.
[usb device file] is the path to the USB device file. dmesg or lsblk –fs can be used to learn this path. It is often similar to device filenames of storage devices like hard drives and SSDs, e.g. /dev/sdb 'It is very important to use the correct value' to avoid overwriting other storage devices.

Keyboard layout

If you’re not using an English keyboard, various keyboard types and keymaps are available.

you can set your correct country by using the command loadkeys followed by you language.

Available keymap files can be found in /usr/share/kbd/keymaps/ (you can omit the keymap path and file extension when using loadkeys).

For example, Greek users, type:

# loadkeys gr

Connect to the Internet

As of v197, udev no longer assigns network interface names according to the wlanX and ethX naming scheme. If you are coming from a different distribution or are reinstalling Hyperbola and not aware of the new interface naming style, please do not assume that your wireless interface is named wlan0, or that your wired interface is named eth0. You can use the command ip link to discover the names of your interfaces.

A DHCP service is already enabled for all available devices. If you need to setup a static IP or use management tools, you should stop this service first:

# rc-service dhcpcd stop

For more information read Configuring Network.

The dhcpcd network daemon starts automatically during boot and it will attempt to start a wired connection. Try to ping a server to see if a connection was established. For example, gnu.org:

# ping -c 3 gnu.org
 
PING gnu.org (208.118.235.148) 56(84) bytes of data.
64 bytes from wildebeest.gnu.org (208.118.235.148): icmp_seq=1 ttl=47 time=183 ms
64 bytes from wildebeest.gnu.org (208.118.235.148): icmp_seq=2 ttl=47 time=168 ms
64 bytes from wildebeest.gnu.org (208.118.235.148): icmp_seq=3 ttl=47 time=183 ms
 
--- gnu.org ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2002ms
rtt min/avg/max/mdev = 168.131/178.357/183.914/7.248 ms

If you get a ping: unknown host error, first check if there is an issue with your cable or wireless signal strength. If not, you will need to set up the network manually, as explained below.

Wired

Follow this procedure if you need to set up a wired connection via a static IP address.

First, disable the dhcpcd service which was started automatically at boot:

# rc-service dhcpcd stop

Identify the name of your Ethernet interface.

# ip link
 
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: enp2s0f0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:11:25:31:69:20 brd ff:ff:ff:ff:ff:ff
3: wlp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DORMANT qlen 1000
    link/ether 01:02:03:04:05:06 brd ff:ff:ff:ff:ff:ff

In this example, the Ethernet interface is enp2s0f0. If you are unsure, your Ethernet interface is likely to start with the letter “e”, and unlikely to be “lo” or start with the letter “w”. You can also use iwconfig and see which interfaces are not wireless:

# iwconfig
 
enp2s0f0  no wireless extensions.
wlp3s0    IEEE 802.11bgn  ESSID:"NETGEAR97"
          Mode:Managed  Frequency:2.427 GHz  Access Point: 2C:B0:5D:9C:72:BF
          Bit Rate=65 Mb/s   Tx-Power=16 dBm
          Retry  long limit:7   RTS thr:off   Fragment thr:off
          Power Management:on
          Link Quality=61/70  Signal level=-49 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:430   Missed beacon:0
lo        no wireless extensions.

In this example, neither enp2s0f0 nor the loopback device have wireless extensions, meaning enp2s0f0 is our Ethernet interface.

You also need to know these settings:

Activate the connected Ethernet interface (e.g. enp2s0f0):

# ip link set enp2s0f0 up

Add the address:

# ip addr add ip_address/subnetmask dev interface_name

For example:

# ip addr add 192.168.1.2/24 dev enp2s0f0

For more options, run man ip.

Add your gateway like this, substituting your own gateway's IP address:

# ip route add default via ip_address

For example:

# ip route add default via 192.168.1.1

Edit resolv.conf, substituting your name servers' IP addresses and your local domain name:

# nano /etc/resolv.conf
 
nameserver 61.23.173.5
nameserver 61.95.849.8
search example.com
Currently, you may include a maximum of three nameserver lines. In order to overcome this limitation, you can use a locally caching nameserver like Dnsmasq.

You should now have a working network connection. If you do not, check the detailed Network Configuration page.

Wireless

Follow this procedure if you need wireless connectivity (Wi-Fi) during the installation process.

First, identify the name of your wireless interface.

# iw dev
 
phy#0
        Interface wlp3s0
                ifindex 3
                wdev 0x1
                addr 00:21:6a:5e:52:bc
                type managed

In this example, wlp3s0 is the available wireless interface. If you are unsure, your wireless interface is likely to start with the letter “w”, and unlikely to be “lo” or start with the letter “e”.

If you do not see output similar to this, then your wireless driver has not been loaded. Please see Wireless Setup for more detailed information.

Bring the interface up with:

# ip link set wlp3s0 up
If you get this error message:
SIOCSIFFLAGS: No such file or directory

Then, your wireless chipset could need a non-free firmware to function. This is not supported on Hyperbola. Please see Wireless Setup if you are unsure if this is the true for your particular chipset.

Next, use iw dev wlp3s0 scan | grep SSID to scan for available networks, then connect to a network with:

# wpa_supplicant -B -i wlp3s0 -c <(wpa_passphrase "ssid" "psk")

You need to replace ssid with the name of your network (e.g. “Linksys etc…”) and psk with your wireless password, leaving the quotes around the network name and password.

Finally, you have to give your interface an IP address. This can be set manually or using the dhcp:

# dhcpcd wlp3s0

If that does not work, issue the following commands:

# echo 'ctrl_interface=DIR=/run/wpa_supplicant' > /etc/wpa_supplicant.conf
# wpa_passphrase <ssid> <passphrase> >> /etc/wpa_supplicant.conf
# ip link set <interface> up # May not be needed as dhcpcd should bring it up but may be needed for wpa_supplicant.
# wpa_supplicant -B -D nl80211 -c /foobar.conf -i <interface name>
# dhcpcd -A <interface name>

ADSL with PPPoE/PPPoA

Follow this procedure if you need ADSL with PPPoE/PPPoA during the installation process.

First, identify the name of your Ethernet interface.

# ip link
 
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: enp2s0f0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:11:25:31:69:20 brd ff:ff:ff:ff:ff:ff
3: wlp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DORMANT qlen 1000
    link/ether 01:02:03:04:05:06 brd ff:ff:ff:ff:ff:ff

In this example, the Ethernet interface is enp2s0f0.

Second, create the PPP net script and the net script for the Ethernet interface to be used by PPP:

# ln -s /etc/init.d/net.lo /etc/init.d/net.ppp0
# ln -s /etc/init.d/net.lo /etc/init.d/net.enp2s0f0
Be sure to set rc_depend_strict to YES in /etc/rc.conf.

Now we need to configure /etc/conf.d/net.

# nano /etc/conf.d/net

config_eth0=null (Specify the ethernet interface)
config_ppp0="ppp"
link_ppp0="enp2s0f0" (Specify the ethernet interface)
plugins_ppp0="pppoe"
username_ppp0='user'
password_ppp0='password'
pppd_ppp0="
noauth
defaultroute
usepeerdns
holdoff 3
child-timeout 60
lcp-echo-interval 15
lcp-echo-failure 3
noaccomp noccp nobsdcomp nodeflate nopcomp novj novjccomp"
  
rc_net_ppp0_need="net.enp2s0f0"
It is also possible to set the password in /etc/ppp/pap-secrets.
Please carefully read the section on ADSL and PPP in /usr/share/doc/netifrc-*/net.example.bz2. It contains many more detailed explanations of all the settings any particular PPP setup will likely need.

Now that the interface is configured, we can start it using the following commands:

rc-service net.ppp0 start

Behind a proxy server

If you are behind a proxy server, you will need to export the http_proxy and ftp_proxy environment variables. See Proxy settings for more information.

Check Internet Connection

Now we can check if there is an Internet connection, and everything is working has expected:

# ping -c 3 gnu.org

If don´t get any connection, repeat various steps above to achieve connection:

Preparing the storage device for installation

You need to prepare the storage device that we will use to install the operating system. You can use same device name that you used earlier, to determine the installation device for the ISO.

Wipe storage device

You want to make sure that the device you’re using doesn’t contain any plaintext copies of your personal data. If the drive is new, then you can skip the rest of this section; if it’s not new, then there are two ways to handle it:

  1. If the drive were not previously encrypted, securely wipe it with the dd command; you can either choose to fill it with zeroes or random data; I chose random data (e.g., urandom), because it’s more secure. Depending on the size of the drive, this could take a while to complete:
    # dd if=/dev/urandom of=/dev/sdX; sync
  2. If the drive were previously encrypted, all you need to do is wipe the LUKS header. The size of the header depends upon the specific model of the hard drive; you can find this information by doing some research online. Refer to this article, for more information about LUKS headers. You can either fill the header with zeroes, or with random data; again, I chose random data, using urandom:
    # head -c 3145728 /dev/urandom > /dev/sdX; sync

Also, if you’re using an SSD, there are a two things you should keep in mind:

Formatting the storage device

Now that all the personal data has been deleted from the disk, it’s time to format it. We’ll begin by creating a single, large partition on it, and then encrypting it using LUKS.

Initial setup

First you will need to install cryptsetup package, given it is a utility we will use to create all the neccessary volume groups and locical volumes for a encrypted drive

# pacman -Syy cryptsetup
You can ignore error messages given this is only temporary and later cryptsetup will be installed in correct kernel has well

You will need the device-mapper kernel module during the installation; this will enable us to set up our encrypted disk. To load it, use the following command:

# modprobe dm-mod

Disk configuration

Partition disk

We then need to select the device name of the drive we’re installing the operating system on; see the above method, if needed, for figuring out device names.

# lsblk

Now that we have the name of the correct device, we need to create the partition on it. For this, we will use the cfdisk command:

You can allways use other utilities like cfdisk, or others if prefered.
# cfdisk /dev/sdX

This will bring up a graphical partitioning table, use the Tab and arrow keys to navigate. This is assuming that you want Hyperbola installed on your HDD.

If there are no partitions present select dos, try to avoid gpt only for very large disks. If intended to leave any partition on the drive, select Delete, to clear some space for new system installation.

To make a new partitions use the arrow keys and select your partition, choose New, to create intended partition sizes.

First we need make a boot partition. When creating it, will see an option for Primary or Logical; choose Primary, and make sure that the partition type is Linux (83), then choose the Boot flag to make this partition “bootable”, for the partition size is advised to use 500 MB for the unencrypted boot. Then create a partition with the rest of the disk where the encrypted LUKS container would be allocated. Again chose as Primary go to “Type” option and select Linux (83) from list, then choose the End flag.

Select Write; it will ask you if you are sure that you want to overwrite the drive. Type yes, and press enter to save your changes to disk. A message at the bottom will appear, telling you that the partition table has been altered. Select Quit, to return you to the main terminal.

You will then have something like this:

Recommendations:
/boot     = 500MB                      sda1  Boot  Primary  Linux
(encrypted)                               sda2           Primary Linux

WIP This is for encrypt exclude boot

add fde parts or maybe even opposite add exclude parts here isntead

Create the LUKS partition

Now that you have created the partition, it’s time to create the encrypted volume on it.

See partitioning for details.

Remember to create any stacked block devices like LVM, LUKS, or RAID. After reading this articles, will follow the good advice and run:

# cryptsetup benchmark (to make sure that the list below is populated)

Then:

# cat /proc/crypto

This gives us the crypto options that can be used. It also provides a representation of the best way to set up LUKS. In our case, security is a priority and speed a distant second. Following Dm-crypt/Device encryption, considering the above requirements, we do the following based on Encryption options for LUKS mode. Reading through, it seems like Serpent (encryption) and Whirlpool (hash) is the best option, according to the performance test executed by previous commands.

using the cryptsetup command, like this:

cryptsetup -v –cipher serpent-xts-plain64 –key-size 512 –hash whirlpool –iter-time 500 –use-random –verify-passphrase luksFormat –type luks1 /dev/sdXY

given luks2 support is limited in stable version of grub yet, is advised to use luks1 rather then luks2
non fde bellow wip
# cryptsetup -v --cipher serpent-xts-plain64 --key-size 512 --hash whirlpool --iter-time 500 --use-random --verify-passphrase luksFormat /dev/sdXY

You will now be asked twice for a password for this LUKS partition.

NOOOTE!! sda2

These are just recommended defaults; if you want to use anything else, or to find out what options there are in order to gain a better understandment of this programme, run man cryptsetup, and read through its manual pages.

The default iteration time is 2000ms (2 seconds), if not specified when running the cryptsetup command. You should set a lower time than this; otherwise, there will be an approximately 20-second delay when booting your system. We recommend 500ms (0.5 seconds), and this is included in the prepared cryptsetup command above. Keep in mind that the iteration time is for security purposes (it mitigates brute force attacks), so anything lower than 5 seconds is probably not very secure.

You will now be prompted to enter a passphrase; be sure to make it secure. For passphrase security, length is more important than complexity (e.g., correct-horse-battery-staple is more secure than bf20$3Jhy3), but it’s helpful to include several different types of characters (e.g., uppercase/lowercase letters, numbers, special characters). The password length should be as long as you are able to remember, without having to write it down, or store it anywhere.

Use of the diceware method is recommended, for generating secure passphrases (rather than passwords).

Create the volume group and logical volumes

The next step is to create two logical volumes within the LUKS-encrypted partition: one will contain your main installation, and the other will contain your swap space.

We will create this using, the Logical Volume Manager (LVM).

Open LUKS partition

First, we need to open the LUKS partition, at /dev/mapper/lvm:

# cryptsetup open /dev/sdXY lvm

Create physical volume

Then, we create LVM partition:

# pvcreate /dev/mapper/lvm

Check to make sure that the partition was created:

# pvdisplay

Create volume group

Next, we create the volume group, inside of which the logical volumes will be created. For this example, we will call this group matrix. You can call yours whatever you would like; just make sure that you remember its name:

# vgcreate matrix /dev/mapper/lvm

Check to make sure that the group was created:

# vgdisplay

Setup logical volumes

Lastly, we need to create the logical volumes themselves, inside the volume group; first will create our / logical volume, cleverly named rootvol, another will be our /swap volume, again named as swapvol, the following will be our /usr volume, equally cleverly named as usrvol, then we have /var volume, again named as varvol and finally the last will be our /home volume, consequently named as homevol.

For example, if you will be running a web/mail server then you want the latter (where logs are stored) in its own volume, so that if it fills up with logs, it won’t crash your system. For a home/laptop system (typical use case), just a root and a swap volumes will do.
Boot volume

- Now, we will create a partition, for bootvol:

# lvcreate -L 1G matrix -n bootvol
==== Boot Setup ==== Setup the boot partition:
# mkfs.ext4 /dev/sda1
# mkdir -p /mnt/boot
# mount /dev/sda1 /mnt/boot

You could also create two separate partitions for /boot and /home, but such a setup would be for advanced users, and is thus not covered in this guide. For more information on how to do this, refer to the Arch wiki on partitions.

WIPP??!! note had here that option….

The setup of the drive and partitions is now complete; it’s time to actually install Hyperbola.

Swap volume

- Secondly create the swapvol (again, choose your own name, if you feel like). With 8 GB of available memory, your Swap would then be arround the same equivalent size to your computer’s memory should be more then enough. Chose as swap go to “Type” option and select 82 (Linux swap) from list, then choose the End flag.

Make sure to choose an appropriate swap size (e.g., G refers to two gigabytes; change this however you see fit):

# lvcreate -L 8G matrix -n swapvol

For checking how much RAM memory you have installed on your computer check the line “MemTotal” of the results given by the following command:

cat /proc/meminfo A

Alternatively these commands maybe be used for the same purpose: vmstat -s. Other recommendations here: https://itsfoss.com/swap-size/

Root volume

- Next, we will create partition, for rootvol:

# lvcreate -L 70G matrix -n rootvol
== User Volume ==

text

# lvcreate -L $G matrix -n usrvol

== Logs Volume ==

text

# lvcreate -L $G matrix -n varvol
Home Volume

And now finally, we will create a single, large partition in the rest of the space, for homevol:

# lvcreate -l +100%FREE matrix -n homevol

Verify that the logical volumes were created correctly:

# lvdisplay

Swap creation

First we have to format swapvol, to make it an active swap partition.

Activate swap

To make swapvol into a swap partition, we run the mkswap (i.e., make swap) command:

# mkswap /dev/mapper/matrix-swapvol
Enable swap partition

Activate the swapvol, allowing it to now be used as swap, using swapon (i.e., turn swap on) command:

# swapon /dev/mapper/matrix-swapvol

Filesystem Configuration

The last steps of setting up the drive for installation are to make drive ready to receive installation.

, to make it ready for installation; we do this with the mkfs (i.e., make file system) command. We choose the ext4 filesystem, but you could use a different one, depending on your use case:

Partition Formatting

Create a file system

To create the ext4 file system, type:

Boot

Now we have to format `/`, ext4 will be used for bootvol.

# mkfs.ext3 /dev/mapper/matrix-bootvol
Root

Then we have to format `/`, ext4 will be used for rootvol.

# mkfs.ext4 /dev/mapper/matrix-rootvol
== User == Now we have to format `/usr`, ext4 will be used for homevol.
# mkfs.ext4 /dev/mapper/matrix-usrvol

== Logs == Now we have to format `/var`, ext4 will be used for varvol.

# mkfs.ext4 /dev/mapper/matrix-varvol
Home

Now we have to format `/home`, ext4 will be used for homevol.

# mkfs.ext4 /dev/mapper/matrix-homevol

Format the partitions

See File Systems for details.

If you are using (U)EFI you will most probably need another partition to host the UEFI System partition. Read Create an UEFI System Partition in GNU/Linux.

Make remaining directories

Create boot
# mkdir -p /mnt/boot
== Create User ==
# mkdir -p /mnt/usr

== Create Var ==

# mkdir -p /mnt/var
Create home
# mkdir -p /mnt/home

Create root partition

We now must mount the root partition on /mnt. You should also create directories for and mount any other partitions (/mnt/boot, /mnt/home, …) and mount your swap partition if you want them to be detected by genfstab.

Mount root in /mnt

So to mount rootvol. GNUlinux has a directory for this very purpose: /mnt:

# mount /dev/mapper/matrix-rootvol /mnt

Since rootvol has been mounted at /mnt, now is needed to create the remaining directories. This is where will do so, using mkdir. These folders contain each user’s personal documents, videos, log files, etc:

Mount other partitions

== Mount User ==
# mount /dev/mapper/matrix-usrvol /mnt/usr

== Mount Var ==

# mount /dev/mapper/matrix-varvol /mnt/var

Mount home ==

# mount /dev/mapper/matrix-bootvol /mnt/boot
Mount home
# mount /dev/mapper/matrix-homevol /mnt/home

(NOTE maybe move activation of swap to here after all file system setup is finished.WIP¿?)

Verification of package signatures

New packager keys are necessary by default to install Hyperbola from current ISOs. Because changes in existing keys might happen since rthe ISO release, it is recommended, if not mandatory, to update the keys before attempting an install.

Keep in mind these steps will fail if your system is not set to the correct time, or if you are not connected to the internet. See above for internet setup instructions.

To check that your computer has the correct time, enter date in the terminal.

# date

If the date is incorrect, you will need to manually set the correct time.

# date MMDDhhmm[[CC]YY][.ss]

where MM is the month, DD the day, hh the hour, mm the minutes, CC the century, YY the year and .SS the seconds of current time, the seconds can be omitted (and then also the dot before them should be omitted), the year can also be submitted or just the century. for instance if the current time is 32 seconds and 44 minutes past 18 (6 pm) on the 13th November 2013. Then the command would be:

# date 111318442013.32

Once the date is correct, we need to initialize the gnupg directory and update pacman's keys.

# pacman-key --init
# mount -o remount,size=100M,noatime /etc/pacman.d/gnupg
# pacman-key --populate hyperbola
# pacman-key --refresh-keys

If you get GPG errors updating those packages, you can try running these commands to start over:

# rm -r /etc/pacman.d/gnupg/*
# pacman-key --init
# pacman-key --populate hyperbola
# pacman-key --refresh-keys

If you get an error related to dirmngr, you can get rid of it with:

# mkdir /root/.gnupg && chmod go-rx /root/.gnupg && touch /root/.gnupg/dirmngr_ldapservers.conf

For the time being, running the previous command might also be needed in the newly installed system.

Base system installation

Before installing, you may want to edit /etc/pacman.d/mirrorlist such that your preferred mirror is first. This copy of the mirrorlist will be installed on your new system by pacstrap as well, so it's worth getting it right.

Update keys of hyperiso:

# pacman -Syy hyperbola-keyring

Install the base system using pacstrap:

# pacstrap /mnt base cryptsetup

You can install additional packages passing base and the names of these packages as arguments after the root directory of the new installation (all packages from the base group are installed if no package is specified).

You can also use package group base-devel to include developement and contribution tools Install base packages:

Install `xenocara-input-synaptics` only on laptops

# pacstrap /mnt xenocara-input-synaptics

WIP

# pacstrap /mnt kernel-firmware ldns
If you have a btrfs root, you probably want to install also btrfs-progs.
If you face GPG errors when running, you can try to fix them with:
# rm -r /etc/pacman.d/gnupg/*
# pacman-key --init
# pacman-key --populate hyperbola
# pacman-key --refresh-keys

System configuration

Generate an fstab

Generate a fstab with the following command (if you prefer to use UUIDs or labels, add the -U or -L option, respectively):

# genfstab -p /mnt >> /mnt/etc/fstab
If you prefer to use UUIDs or labels, add the -U or -L flag, respectively, for example:
# genfstab -U -p /mnt >> /mnt/etc/fstab

Chroot and configure the base system

Next, chroot into our newly installed system:

# arch-chroot /mnt

WIP??!question in forum guide greek fellow uses #arch-chroot /mnt /bin/bash endWIP??!

Hostname

Usually it’s best, for privacy and security reasons to set your hostname to localhost, but here will use hyperpc has a example.

Set hostname, by editing /etc/hostname file:

# echo hyperpc > /etc/hostname

Add the same hostname, i.e. hyperpc, to /etc/hosts.

Type:

# nano /etc/hosts
# <ip-address> <hostname.domain.org> <hostname>
127.0.0.1                localhost.localdomain     localhost hyperpc
::1                             localhost.localdomain     localhost hyperpc

WIP??!question in forum guide greek fellow only sets hostname later on when doing network configuration, after intaling grub and making kernel images, is this best practice? or is ok to do it here before all that … endWIP??!

Locale

To enable location, edit locale in /etc/locale.gen:

# nano /etc/locale.gen

By uncomment the selected language locale, For color #620BB9/#EEDDFF>us</color>, English, it should look like this:

...
#en_SG ISO-8859-1
en_US.UTF-8 UTF-8
#en_US ISO-8859-1
...
All locales are commented out (preceded by #) by default. to uncomment (remove the #) for your chosen locale.

After you’ve uncommented your language, generate the locale by runnning:

# locale-gen

Then set locale preferences in /etc/locale.conf:

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

Then export your chosen locale

# export LANG=en_US.UTF-8

Keymap

Setup the console keymap and font preferences, by configure and changing the file /etc/conf.d/keymaps:

keymap="gr"

WIP??!! “ # sed -e 's/^keymap=“us”/keymap=“uk”/g' -i /etc/conf.d/keymaps”

If you have an advanced usage of your keymap, you can watch the other functionalities, documented in the comments. You can find all the available keymaps in /usr/share/kbd/keymaps. Then run:

# rc-update add keymaps default
This only applies for TTY, if you are using X11, this won't affect your graphical environment.

WIP??!question Both our FDE guide and encryted excluding /boot guide on our forum done by one of greek fellow only sets keymap later on when doing network configuration, after intaling grub and making kernel images, is this best practice? or is ok to do it here before all that … also we should add section in begining of install guide for keymap on live system outside chroot that is. endWIP??

Time zone

Set localtime, by creating a symbolic link /etc/localtime to your subzone file /usr/share/zoneinfo/Zone/SubZone:

# ln -s /usr/share/zoneinfo/Zone/SubZone /etc/localtime

For example, here replace Zone and Subzone to Europe and Athens, respectively:

# ln -s /usr/share/zoneinfo/Europe/Athens /etc/localtime
If you get ln: failed to create symbolic link ’/etc/localtime’: File exists, then run:
# ln -s -f /usr/share/zoneinfo/Zone/SubZone /etc/localtime

Hardware clock

Set the hardware clock to UTC (Optional):

# hwclock --systohc --utc

Root password

Set root user, password with passwd:

# passwd
Remember when you’re typing in your root password (as any password) into the terminal, it won’t show. Just carefully type in your chosen root password and repeat it when asked to.

Add an user

Finally, lets add a normal user:

Create user group, for example: `libre`

# groupadd libre

Create user `freedom` and add it to basic groups

# useradd -m -G audio,disk,http,input,lp,network,optical,power,scanner,storage,sys,video,wheel -g libre -s /bin/bash freedom

Assign password

# passwd freedom

Basic setup

In config file, to allow members of group wheel to run commands as other users, create a configuration file with the following content:

permit :wheel

The owner and group for /etc/doas.conf should both be 0, file permissions should be set to 0400:

 # chown -c root:root /etc/doas.conf
 # chmod -c 0400 /etc/doas.conf
To check /etc/doas.conf for syntax errors, run:
 # doas -C /etc/doas.conf && echo "config ok" || echo "config error" 
It is imperative that /etc/doas.conf is free of syntax errors!
2022/03/26 20:14 · i3_relativism

Add your user to the relevant group such as:

# gpasswd -a <username> video

For more information, please check User management.

WIP??!question 1. Where should this be because our guides advise to do it here before bootloader and ramdisk, but heyckel conecimentos livre and greek fellow forum guides do it after 2. What other groups could he add here endWIP??!

Create Ramdisk

linux-libre-lts is our default kernel since we are a long-term support distro.

(W·IP¿?)

Setting up the kernel modules

Now we need to make sure that the kernel has all the modules that it needs to boot the operating system. To do this, we need to edit a file called mkinitcpio.conf. More information about this file can be found in the Arch wiki, but for the sake of this guide, you simply need to run the following command.

# nano /etc/mkinitcpio.conf

There are several modifications that we need to make to the file:

  1. Change the value of the uncommented MODULES line to i915.
    • This forces the driver to load earlier, so that the console font you selected earlier isn’t wiped out after getting to login.
    • Be aware, when you add i915 into the uncommented modules line, that you remove these “ “ before you add i915, otherwise, it will not boot and will drop to a shell. When you install with full disk encryption, this is a requirement.
    • If you are using a Macbook 2,1 you will also need to add hid-generic, hid, and hid-apple inside the quotation marks, in order to have a working keyboard when asked to enter the LUKS password. Make sure to separate each module by one space.
  2. Change the value of the uncommented HOOKS line to the following:
    # nano /etc/mkinitcpio.conf
     
    "base udev autodetect modconf block keyboard keymap consolefont encrypt lvm2 filesystems fsck shutdown"

    Here’s what each module does:

    • keymap adds to initramfs the keymap that you specified in /etc/conf.d/keymaps
    • consolefont adds to initramfs the font that you specified in /etc/conf.d/keymaps
    • lvm2 adds LVM support to the initramfs - needed to mount the LVM partitions at boot time
    • shutdown is needed according to Arch wiki, for unmounting devices (such as LUKS/LVM) during shutdown

After modifying the file and saving it, we need to update the kernel(s) with the new settings.

Then, we update both kernels like this, using the mkinitcpio command:

# mkinitcpio -p linux-libre-lts

(W·IP¿?)

Bootloader installation and configuration

GRUB

Finally follow these steps:

# pacman -S grub

WIP??!question check if any packages are missing above or any need toadding rc-services, and look into why after testing grub-bios works in pacman but doesnt seem to be present on our repos endWIP??!

WIP??!
# pacman -S freetype2 fuse2 dosfstools efibootmgr libisoburn os-prober mtools xen xen-docs
 nano /etc/default/grub 
 

To use LUKS uncoment:

 GRUB_ENABLE_CRYPTODISK=y 
 

Install grub in your

# grub-install --target=i386-pc --recheck /dev/sdX
If you want to install GRUB on a Libre versions of coreboot, like GNUboot system, keep in mind your system does not use UEFI or Legacy BIOS, but instead loads GRUB as its only payload. So you we will run this command instead:
grub-install --target=i386-coreboot --recheck --no-bootsector /dev/sdX

BIOS and EFI

For EFI32bit like it is the case for early macbooks with support for gnuboot, but still running apple firmware use:

WIP??!!

# grub-install --target=i386-efi --recheck /dev/sdX
Here, use /boot partition and do NOT append a partition number, i.e. /dev/sdaX)

See GRUB for further details. WIP??!!

Create grub.cfg file

# grub-mkconfig -o /boot/grub/grub.cfg

WiP

nano /boot/grub/grub.cfg

Add “cryptdevice=/dev/sda2:matrix” between “root=…” and “rw” in the line that starts with linux.

This needs to be done for “linux-libre” and “linux-libre-fallback”.

Syslinux

# pacman -S syslinux

See Syslinux for further details.

Bootloader on external drive

If you are following the gnuboot encrypted installation instructions, be sure to save a copy of grub.cfg on a thumbdrive in case the one flashed to gnubooot is incorrect. You can use the grub shell to boot from the extra copy.

Wireless tools installation

If your wireless network is WPA protected, you'll need wpa_supplicant to connect to it:

# pacman -S iw iputils iproute2 wpa_supplicant

Configure Wireless

wpa_suplicant

- Configure [wpa_supplicant][wpa_link]{:target='_blank' rel='noopener noreferrer'}

# nano -w /etc/wpa_supplicant/wpa_supplicant.conf

Inside:

        ctrl_interface=/var/run/wpa_supplicant
        ctrl_interface_group=wheel
        update_config=1
 
        network = {
            ssid="<network-name>"
	        psk="your-pass"
        }

Add to service by default

# rc-update add wpa_supplicant default

dhcpcd

Add to service by default

# rc-update add dhcpcd default
For further details on how to configure the network, for newly installed environment. See Network Configuration and Wireless Setup.

Unmount and reboot

If you are still in the chroot environment type exit or press Ctrl+D in order to exit.

# exit

Earlier we mounted the partitions under /mnt. In this step we will unmount them:

# umount -R /mnt
If you have made separate partitions on your system, do this instead:
# umount ´/mnt/{boot,home,}´

Next we can turn off the swap volume:

# swapoff -a

Desactivate the logical volumes rootvol, swapvol and homevol.

# lvchange -an /dev/matrix/bootvol
# lvchange -an /dev/matrix/swapvol
# lvchange -an /dev/matrix/rootvol
# lvchange -an /dev/matrix/homevol

And lock the encrypted partition:

# cryptsetup luksClose lvm

Finally, turn off computer:

# openrc-shutdown -p now
Alternatively, you can more easily just reboot instead, in order to login into your system:
# reboot

Congratulations! You have now sucessfully installed **Hyperbola GNU/Linux-libre**.

Ounce the machine powers off, remember to remove installation medium (your USB stick, in most cases),before rebooting back to your system and proceed with your installation. To log in, you type root and your password.

Arrancando la instalación manualmente desde el GRUB

Cuando olvida configurar o configure incorrectamente grub en su hdd, debe iniciar el sistema manualmente ingresando una serie de comandos en la linea de comandos de GRUB.

Después iniciar la computadora, presione C para que aparezca la línea de comando de GRUB Aquí están los comandos:

grub> cryptomount -a
grub> set root='lvm/matrix-rootvol'
grub> linux /boot/vmlinuz-linux-libre-lts root=/dev/matrix/rootvol cryptdevice=/dev/sda1:root
grub> initrd /boot/initramfs-linux-libre-lts.img
grub> boot
En las máquinas con sata nativo, durante el arranque, una unidad de disco óptico (defectuosa) (como dvd) puede hacer que el comando cryptomount -a falle o se bloquee, así como el error:
AHCI time out out

La solución es desconectar la unidad de DVD.

Post-installation

You will now have to create a user and get user privileges like doas. And of course, you will have to install all your favourite and necessary packages including a Desktop Environment (DE), for example.

Configure pacman

Edit /etc/pacman.conf and configure pacman's options, also enabling the repositories you need.

See Pacman and repositories for details.

BASE graphical interface

Install video package (depending trademark of your video card)

Check video trademark:

# lspci | grep -e VGA

Install one, depending of trademark:

AMD
# pacman -S xenocara-video-amdgpu
Ati
# pacman -S xenocara-video-ati
Intel
# pacman -S xenocara-video-intel
Nvidia
# pacman -S xorg-video-nouveau
Vesa (generic)
# pacman -S xenocara-video-vesa

Xenocara components

# pacman -S xenocara-server xenocara-xinit xenocara

Mesa demos

# pacman -S mesa mesa-demos

Setting in keyboard language for Xenocara

Syntax of X configuration files is explained in

WIPP??!! probably we should add note Seee also [https://fedoraproject.org/wiki/Input_device_configuration#xorg.conf.d|conf.d]

Method creates configuration for entire system, which is maintained after reboot.

Here's an example:

# nano -w /etc/X11/xorg.conf.d/00-keyboard.conf

and inside write:

    Section "InputClass"
        Identifier "system-keyboard"
        MatchIsKeyboard "on"
        Option "XkbLayout"  "us,uk"
        Option "XkbModel"   "pc105"
        Option "XkbVariant" "deadtilde,dvorak"
        Option "XkbOptions" "grp:alt_shift_toggle"
    EndSection

XkbOptions can receive various parameters for example:

(WIP¿?)(add cololur code) `”grp:alt_shift_toggle,compose:rwin,lv3:ralt_switch,numpad:pc”` (WIP¿?)

Were as a example, we have 2 keyboard layouts: English US (us) and English UK (uk), and to go from one to the other just use the `ALT+SHIFT` key combination.

Check keyboard settings
# setxkbmap -print -verbose 10
Typefaces
# pacman -S ttf-liberation ttf-bitstream-vera ttf-dejavu ttf-droid

(WIP¿?) Next, we will proceed to create the personal folders. In case you have planned to install LUMINA as a desktop environment, skip this step, since the installation automatically generates this directories. (WIP¿?)(is this true Im not sure for lumina!?)

Directory generator installation:
# pacman -S xdg-user-dirs
Automatic directory creation:
# xdg-user-dirs-update

(WIP¿?)

Audio support

Install `sndio`

# pacman -S sndio sndio-alsa alsa-utils pavucontrol

Add audio service to default

# rc-update add alsasound default

Configure sndio

(WIP¿?)

# sed -e 's/^; autospawn = yes/autospawn = yes/g' -i /etc/pulse/client.conf

(WIP¿?)

Officially supported desktop environments

Lumina Desktop

Lumina is a lightweight desktop environment, free of D-Bus and *kit, designed to have as few system dependencies and requirements as possible. Check this Wikipedia article, and the official handbook.

Installation
dont forget to update you system before you proceed

To install Lumina desktop, run:

pacman -S lumina lumina-extra
This packages groups lumina includes both lumina-core and lumina-core-utils, and lumina-extra includes own implementations: archiver, fileinfo, fm, mediaplayer, photo, screenshot, textedit, respectively

(WIP¿?) + lumina: contains basic desktop environment and applications necessary for the standard experience. + lumina-extra: contains a set of packages and optional tools which are their own implementations, like an archiver, a mediaplayer, an editor and other non-essential applications that go well with the LUMINA desktop.

(WIP¿?)

Configuration

A configuration file is installed in /etc/luminaDesktop.conf . Lumina also has a bunch of own configuration tools.

Invocation

Lumina provides its own replacement for startx to be started from console.

start-lumina-desktop

Alternatively it can be added to the ~./xinitrc file for being started via startx or a display manager

Make sure to read this article, for more information on managing startx on Arch GNU/Linux (the information applies to Hyperbola, as well). But relevant commands are bellow:

[[ -f ~/.Xresources ]] && xrdb -merge -I$HOME ~/.Xresources
exec start-lumina-desktop

How to start Xenocara?

- Write a `~/.xinitrc` file (option 1)

  Uncomment your desktop installed, example file `~/.xinitrc`:
        #!/bin/sh
        #
        # ~/.xinitrc
        #
        # Executed by startx (run your window manager from here)
        #
        # exec enlightenment_start
        # exec i3
        # exec mate-session
        # exec xmonad
        # exec startlxqt
        # exec startlxde
        # exec awesome
        # exec bspwm
        # exec gnome-session
        # exec gnome-session --session=gnome-classic
        # exec startkde
        exec startxfce4
        # exec startfluxbox
        # exec openbox-session
        # exec cinnamon-session
        # exec pekwm
        # exec catwm
        # exec dwm
        # exec startede
        # exec icewm-session
        # exec jwm
        # exec monsterwm
        # exec notion
        # exec startdde #deepin-session
  Then from a tty, you can run `startx` and your desktop will start.

Install login manager (option 2)

Example: `sddm`

# pacman -S sddm sddm-gtk-greeter

Add to service by default

# rc-update add sddm default

or

# rc-update add sddm default

- Reboot

# reboot

Tools

Disks

- gvfs to mount disks

# pacman -S gamin gvfs

Net

- dhcpcd-ui for IP management

# pacman -S dhcpcd-ui

(WIP¿?)

Key manager

- WIP-kering

# pacman -S WIP-keyring

(WIP¿?)

Volume applet

- Volume icon

# pacman -S volumeicon

Synchronize Local Time

Install NTP

# pacman -S ntp

Synchronize Time

# ntpdate -u hora.roa.es

File compressors

Normally we come across files compressed in ZIP, RAR and/or another format that are usually exchanged on the Internet. In many desktop environments, usually include theirs (File Roller in GNOME, Engrampa in MATE, Ark in KDE, and XArchiver in XFCE/LXDE). To improve functionality of these file compressors, we will add support for 7Z, RAR, ZIP and others.

GZip (known with extension ".tar.gz"):
# pacman -S zlib haskell-zlib
BZip2:
# pacman -S bzip2
RAR:
# pacman -S unar
7Zip:
# pacman -S p7zip lrzip
ZIP:
# pacman -S zip libzip unzip

Partition detector

Udisk utility:
# pacman -S udevil autofs
Reading and writing NTFS file systems:
# pacman -S ntfs-3g
FAT32 file system read and write:
# pacman -S fatsort exfat-utils dosfstools
Reading and writing XFS file systems:
# pacman -S xfsprogs

Multimedia support

To play multimedia files, you need to be able to have the codecs and player. To do this, we will proceed to install ffmpeg and gstreamer codecs, in addition to players. Here I suggest some players that you may find useful.

Codecs:
# pacman -S ffmpeg gstreamer gst-libav gst-plugins-bad gst-plugins-good gst-plugins-ugly gst-plugins-base gst-transcoder x264 libvorbis libvpx libtheora opus vorbis-tools

(WIP¿?)

Audacious player:
# pacman -S audacious

(WIP¿? needs revision given recent corporate take over and related fork, need to check and update package as well WIP audacium and tenacity provide alternatives to now own audacity MUSE own editor)

SMPlayer:
# pacman -S smplayer smplayer-themes smplayer-skins
VLC player:
# pacman -S vlc
MPV player:
# pacman -S mpv
Lightweight image viewer
# pacman -S viewnior
PDF viewer
# pacman -S epdfview

Aplicaciones UXP

Thanks to the developers, in Hyperbola we have [Iceweasel-UXP][iceweasel-uxp]{:target='_blank' rel='noopener noreferrer'} a web browser, [Iceape-UXP][iceape-uxp]{:target='_blank' rel='noopener noreferrer'} internet suite and a email-manager called [Icedove-UXP][icedove-uxp]{:target='_blank' rel='noopener noreferrer'}.

Iceweasel-UXP:
# pacman -S iceweasel-uxp
Iceape-UXP:
# pacman -S iceape-uxp
Icedove-UXP:
# pacman -S icedove-uxp

Office

In general, when using an Operating System, at least you have an office suite. In GNU/Linux, it's customary to have one. Fortunately in Hyperbola, Libreoffice is presented in its stable version. For install, run:

LibreOffice
# pacman -S libreoffice-still

Spell check

To check spelling you will need hunspell and a hunspell dictionary (such as hunspell-en_US, hunspell-es, etc)

# pacman -S hunspell hunspell-en_US

Hyphenation and justification

To have provide rules you also need `hyphen` + a set of rules (hyphen-en, hyphen-de, etc)

# pacman -S hyphen hyphen-en

Synonyms

For Synonyms option you will need `mythes` + a mythes synonym library (`mythes-en` `mythes-es`)

# pacman -S mythes mythes-en

Security

Security is important when browsing the Internet, that's why Hyperbola provides a tool called [firejail][firejail]{:target='_blank' rel='noopener noreferrer'} in combination with a graphical interface [firetools][firetools]{:target='_blank' rel='noopener noreferrer'}.

# pacman -S firejail firetools

Social

Hyperbola have programs for communication:

Tox

qtox:

# pacman -S qtox

toxic:

# pacman -S toxic

Identifying keycodes

Showkey utility reports key codes for the virtual console. showkey waits for a key to be pressed and, if there is none for 10 seconds, closes. To run showkey you need to be in a virtual console, not in a graphical environment:

# showkey --keycodes

Update the system

At this point you should update your system.

Upgrade system

$ sudo pacman -Syu

See Upgrading packages for instructions.

Service management

Since Hyperbola removed entire systemd support, we suggest you read about OpenRC which is our main default init system.

SEEALSO (see what word to use for here)

[video-guide]: https://lablibre.tuxfamily.org/hyperbola-gnu-linux-libre-base/ [firejail]: https://github.com/netblue30/firejail [firetools]: https://l3net.wordpress.com/projects/firejail/#firetools [usb-boot]: https://wiki.hyperbola.info/doku.php?id=en:guide:beginners#write_the_image_to_your_usb [cd-boot]: https://wiki.hyperbola.info/doku.php?id=en:guide:beginners#burn_the_image_to_your_optical_disk [wpa_link]: https://wiki.archlinux.org/index.php/WPA_supplicant [dhcpcd_link]: https://wiki.archlinux.org/index.php/Dhcpcd [iceweasel-uxp]: https://wiki.hyperbola.info/iceweasel-uxp [iceape-uxp]: https://wiki.hyperbola.info/iceape-uxp [icedove-uxp]: https://wiki.hyperbola.info/icedove-uxp [xe-conf]: https://fedoraproject.org/wiki/Input_device_configuration#xorg.conf.d

Conclusion

Your new Hyperbola GNU/Linux-libre base system is now a functional GNU/Linux environment.

Acknowledgement

This wiki article is based on ArchWiki, GentooWiki and ParabolaWiki. We may have removed non-FSDG bits from it.