Installation Handbook

This guide goes into detail on how to install Everest.

Prerequisites

There are 2 officially supported ways of installing Everest, systemd/glibc/GNU or sysv/musl/busybox. This guide covers the musl/busybox installation as it recieves the most support and is the intended way. For the GNU installation, it may be a good idea to read the Linux from Scratch wiki.

For highly customized installations (such as a custom init), it is recommended to know exactly what you're doing.

Everest may be installed through 2 methods:

- ISO: can be flashed to a usb and booted

- rootfs tarball (RECOMMENDED): unpacked to a directory (usually /mnt) and instaled through an existing distribution.

Note that no matter what option you choose, you will need the rootfs tarball.

If you wish to install Everest Hike instead of Everest Summit, you can run setup-everest.

First Steps

Create a disk partition for your root filesystem, a boot partition, and any other partitions you may want to make.

Create valid filesystems on the partitions (FAT32 for boot, and Ext4/Btrfs/XFS/ZFS on root).

# mkfs.vfat -F32 /dev/boot

# mkfs.ext4 /dev/root

Mount the newly created root partition to /mnt/everest.

# mkdir /mnt/everest

# mount /dev/root /mnt/everest

Create the "EV" variable, which will save some typing down the road.

# export EV=/mnt/everest

Ensure the variable was created correctly. It will be very important to check this multiple times during installation.

# echo $EV

Unpacking Tarball

To install Everest, you will need the rootfs tarball containing the necessary toolchain.

# wget https://github.com/everest-linux/everest/releases/download/vX.X.X-systemd-rc/everestlinux-summit-X.X.X-systemd-rc.tar.xz

To unpack the tarball:

# tar xpvf everestlinux-summit-X.X.X-systemd.tar.xz --xattrs-include='*.*' --numeric-owner

Enter the chroot environment. This will allow you to install system packages.

# chroot "$EV" /usr/bin/env -i \

HOME=/root \

TERM="$TERM" \

PS1='[everest-chroot] \u:\w \$ ' \

PATH=/usr/bin:/usr/sbin \

/bin/bash --login

Installing System Packages

Now that we are inside the chroot environment, we can install packages to the system.

Before we start, creating /etc/make.conf is recommended. This is so you can specify extra makeflags, most notably, the -jX flag will allow make to utilize more than 1 core.

# /etc/make.conf

MAKEFLAGS=-jX

The following symbols will be used to describe packages

-(!) Vital system package, do not omit.

-(S) Source package

-(B) Binary package

-(L) Long installation time

(!) (B) Glacier

This package contains the Glacier package manager, which manages installed packages on the system. It uses wget and tar as its backens, both of which are included in the tarball.

To install Glacier: # rm -rf /tmp/glacier && cd /tmp && git clone https://github.com/everest-linux/glacier && cd glacier/install && chmod +x INSTALL-GLACIER.sh && sudo ./INSTALL-GLACIER.sh || doas ./INSTALL-GLACIER.sh

Note that Glacier cannot manage itself, so you will need to update every month or so.

(S) Man-pages

This package contains 2,000+ manpages for the system.

To install man-pages:

# glacier -f

[ ? ] man-pages

(!) (B) Iana-Etc

This package contains vital networking protocols.

To install Iana-Etc:

# glacier -f

[ ? ] iana-etc

(!) (S) libgcc

This package contains libraries for GCC.

To install libgcc:

# glacier -f

[ ? ] libgcc

(!) (S) (L) musl

This package contains the musl standard C library.

To install musl:

# glacier -f

[ ? ] musl

(!) (S) busybox

This package contains common UNIX utilities in a single binary.

To install busybox:

# glacier -f

[ ? ] busybox

(!) (S) (L) vim

This package contains the Vim text editor.

To install vim:

# glacier -f

[ ? ] vim

(!) (S) (L) Linux

This package contains the Linux kernel

You will need to cache this package if you wish to build a custom kernel. Prebuilt kernels are available under the names 'linux', 'linux-zen', 'linux-lts', etc. For a custom configuration, the package is called 'linux-custom'.

To install a prebuilt kernel:

# glacier -f

[ ? ] linux-{zen,lts,hardened,rt}

To install and configure a custom kernel:

# glacier -c

[ ? ] linux-custom

Change directory into the Glacier cache and move the package to /tmp

# cd /var/cache/glacier && mv linux-custom.tar.gz /tmp

Unpack the package

# tar xvf linux-custom.tar.gz

Ensure the kernel's source tree is clean

# make mrproper

Make desired configurations to the kernel

# make menuconfig

If using systemd as the init system, 'The IPv6 protocol [CONFIG_IPV6] is highly recommended.

Networking support --->

     Networking options --->

         <*> The IPv6 protocol [CONFIG_IPV6]

See this page from Linux From Scratch on other recommended kernel customizations.

Compile the kernel

# make

If you enabled support for modules, compile them

# make modules_install

If you intend on dual booting and are using an external boot partition, run the following command from OUTSIDE THE CHROOT ENVIRONMENT

# mount --bind /boot /mnt/ev/boot

Change the kernel image

# cp -iv arch/x86/boot/bzImage /boot/vmlinuz-X.XX.X

Install the system map file

# cp -iv System.map /boot/System.map-X.XX.X

Save your kernel's configuration

# cp -iv .config/boot/config-X.XX.X

Install kernel documentation

# install -d /usr/share/doc/linux-X.XX.X

# cp -r DOcumentation/* /usr/share/doc/linux-X.XX.X

If you wish to retain the kernel's source tree

# chown -R 0:0 /path/to/linux-X.XX.X

Warning: Some documentation for the kernel recommends symlinking /usr/src/linux to the kernel source tree, however this is specific to 2.6 series kernels and MUST NOT BE CREATED as it can cause conflics with Glacier.

Warning: The headers in /usr/include should ALWAYS be the ones against which your standard C library was compiled. They should NEVER be replaced by either the raw kernel headers or the sanitized headers of any other kernel.

Create /etc/modprobe.d/usb.conf, which will ensure USB modules are started in the correct order

install -v -m755 -d /etc/modprobe.d

cat > /etc/modprobe.d/usb.conf

# Begin /etc/modprobe.d/usb.conf << "EOF"

 

install ohci_hcd /sbin/modprobe ehci_hcd ; /sbin/modprobe -i ohci_hcd ; true

install uhci_hcd /sbin/modprobe ehci_hcd ; /sbin/modprobe -i uhci_hcd ; true

 

# End /etc/modprobe.d/usb.conf

EOF

Configuring the System

Now we must configure the system so it will boot correctly

As a recommendation for easy access to the root account, installing sudo or doas is highly recommended, as it will remove the need to log in as root with su and will only require invoking sudo or doas.

In the case of sudo, the following line will need to be uncommented from /etc/sudoers

%wheel ALL=(ALL) ALL

In the case of doas, /etc/doas.conf will need to be created, containing the following:

permit :wheel

Create /etc/hostname and enter the desired hostname for the system

Create /etc/hosts and enter the following

127.0.0.1 localhost

::1 localhost

127.0.1.1 localdomain hostname

Install a bootloader capable of loading a Linux system (such as grub)

In the case of grub, install os-prober and efibootmgr (for UEFI systems), then install grub:

Warning: Highly customized configurations may cause the bootloader to break. It is recommended to edit /etc/make.conf before building this package.

# grub-install /dev/sdX (BIOS/MBR)

# grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=grub (UEFI)

Create the GRUB configuration file

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

Once the bootloader has been installed, power off the system.

The End

You should be greeted by a shell prompt on first boot.

If you need assistaince with your installation, we have both IRC channels, a Revolt server, and a Discord server.