Linux root x86 64

Installing ROOT

ROOT is available on Linux, Mac, and (as a beta release) on Windows.
The latest stable ROOT release is 6.24/06 (about ROOT versioning scheme).

There are several ways to install ROOT on your computer: they are all listed in the table of content on the right. Which one is best for you depends on your operating system and usage requirements. In all cases, make sure to always use the most recent ROOT release possible to get the latest bug fixes, features and quick user support.

Download a pre-compiled binary distribution

We distribute pre-compiled ROOT for several major Linux distributions as well as MacOS and (as a beta) Windows. The steps to install a pre-compiled binary are simple:

  1. Install all required dependencies with the system package manager
  2. Download the release for the desired platform and ROOT version
  3. Unpack the archive
  4. Add the ROOT libraries and executables to your environment by sourcing the appropriate thisroot.* script. These setup scripts can be found in the ROOT binary release, in the bin directory.

For example, on Ubuntu 20, a user could execute the following bash commands to install ROOT v6.24/02, after installing all required dependencies:

To avoid having to source thisroot.sh every time one needs to use ROOT, it is typical to add the command to .bashrc , .profile or analogous configuration files. Note, however, that sourcing thisroot.sh might interfere with ROOT versions installed with different methods.

And on Windows, for example, after the installation, open a x86 Native Tools Command Prompt for VS 2019 , cd to your home directory ( cd %USERPROFILE% ) and call thisroot.bat (let’s assume you installed ROOT in C:\root ). Then you can start ROOT:

Install via a package manager

Supported by the community: these packages are not maintained by the ROOT team, but by helpful members of the community. Please go through each package manager’s standard channels to report any related issue. If you package ROOT and would like to be added to the list below, please contact us by clicking the letter icon at the bottom of the page.

Conda

For any Linux distribution and MacOS, ROOT is available as a conda package. To create a new conda environment containing ROOT and activate it, execute

Setting channel_priority to strict is required to avoid conflicts on some platforms, see the relevant conda docs for more information.

The conda package uses C++17.

More instructions about using this package are available in this blog post.

Please report any issues with the conda package here.

On many Linux distributions, ROOT can be installed via Snap. For example, on Ubuntu:

The Snap package uses C++17. See our dedicated blog post for more information, or visit the official ROOT Snap package page.

Linux package managers

ROOT can be directly installed from the operating system’s package manager in the following Linux distributions:

Fedora

Fedora’s ROOT package can be installed with

More typically, however, users will want more than just the base package. The full list of components can be seen at https://src.fedoraproject.org/rpms/root/ by clicking in one of the offered versions. To install ROOT with support for python and notebooks, for example, run

Читайте также:  Ksxbar ax windows 10

CentOS

ROOT is available on CentOS via EPEL. To install ROOT on CentOS, just run

Arch Linux

Arch’s ROOT package can be installed with

The Arch package uses C++17.

Gentoo

The Gentoo package for ROOT is sci-physics/root. It can be installed with

NixOS/Nix/Nixpkgs

The package name for ROOT in nixpkgs is root . It can be installed into the user environment using

Running in a temporary environment can be achieved with

A root5 package is provided for the legacy software support.

If you encounter any issues, feel free report them to the nixpkgs issue tracker.

Ubuntu and Debian-based distributions

The ROOT team is working on the release of an official .deb package. More news on this topic very soon.
In the meanwhile, ROOT is available on Ubuntu via conda or our pre-compiled binaries.

MacOS package managers

Homebrew

On Mac, ROOT is also available as a homebrew formula. You can install it with

Macports

After installing macports, the ROOT port can be installed with

Nix/Nixpkgs

The same instructions as for Linux apply when running on macOS.

LCG releases on CVMFS

Standalone ROOT

If your platform mounts CVMFS ROOT is directly available via LCG releases.

ROOT installations with minimal external dependencies are available for Fedora, Ubuntu, CentOS7 and MacOS at:

For example, to set up ROOT 6.24/02 on a CentOS7 machine, just run:

Make sure you use your system’s default compiler, just like this ROOT build.

Complete environment

ROOT, Geant4 and many other packages with all their dependencies are available as LCG views:

LCG views are available for CentOS7, CentOS8 and the latest MacOS and Ubuntu releases. For example, on CERN LXPLUS, you can set up a full environment that contains ROOT 6.24/00 with:

To check what ROOT version is contained in an LCG release, you can visit lcginfo.cern.ch.

Gentoo Prefix on CVMFS

ROOT is also experimentally available in a Gentoo Prefix installation inside the contrib area of the SFT CVMFS repository. To use it from there, run

This will drop you into a new shell where all software from the prefix is available.

Run in a Docker container

ROOT Docker containers for several linux flavours are available at ROOT’s official DockerHub.

For example, to try out the latest ROOT release just run docker run -it rootproject/root .

Run on CERN LXPLUS

Users with a CERN computing account can simply connect to lxplus.cern.ch via SSH and start root : the latest stable version is installed as a normal system package.

Note that certain features (e.g. multi-threading capabilities) are not available on lxplus.cern.ch (or, equivalently, lxplus7.cern.ch ) due to incompatible versions of certain ROOT dependencies on CentOS7. You can use lxplus8.cern.ch to get access to CentOS8, where this limitation is not present.

Build from source

In case no other installation method is available, or if you want full control over the options ROOT is built with, it is possible to compile ROOT from source. See Building ROOT from source for detailed instructions.

As a quick summary, after installing all required dependencies, ROOT can be compiled with these commands on most UNIX-like systems:

And similarly, on Windows, inside a x86 Native Tools Command Prompt for VS 2019 , ROOT can be compiled with these commands:

Источник

Installation via chroot (x86/x86_64/aarch64)

This guide details the process of manually installing Void via a chroot on an x86, x86_64 or aarch64 architecture. It is assumed that you have a familiarity with Linux, but not necessarily with installing a Linux system via a chroot. This guide can be used to create a «typical» setup, using a single partition on a single SATA/IDE/USB disk. Each step may be modified to create less typical setups, such as full disk encryption.

Читайте также:  Как изменить системный язык windows

Void provides two options for bootstrapping the new installation. The XBPS method uses the XBPS Package Manager running on a host operating system to install the base system. The ROOTFS method installs the base system by unpacking a ROOTFS tarball.

The XBPS method requires that the host operating system have XBPS installed. This may be an existing installation of Void, an official live image, or any Linux installation running a statically linked XBPS.

The ROOTFS method requires only a host operating system that can enter a Linux chroot and that has both tar(1) and xz(1) installed. This method may be preferable if you wish to install Void using a different Linux distribution.

Prepare Filesystems

Partition your disks and format them using mke2fs(8), mkfs.xfs(8), mkfs.btrfs(8) or whatever tools are necessary for your filesystem(s) of choice.

mkfs.vfat(8) is also available to create FAT32 partitions. However, due to restrictions associated with FAT filesystems, it should only be used when no other filesystem is suitable (such as for the EFI System Partition).

cfdisk(8) and fdisk(8) are available on the live images for partitioning, but you may wish to use gdisk(8) (from the package gptfdisk ) or parted(8) instead.

For a UEFI booting system, make sure to create an EFI System Partition (ESP). The ESP should have the partition type «EFI System» (code EF00 ) and be formatted as FAT32 using mkfs.vfat(8).

If you’re unsure what partitions to create, create a 1GB partition of type «EFI System» (code EF00 ), then create a second partition of type «Linux Filesystem» (code 8300 ) using the remainder of the drive.

Format these partitions as FAT32 and ext4, respectively:

Create a New Root and Mount Filesystems

This guide will assume the new root filesystem is mounted on /mnt . You may wish to mount it elsewhere.

If using UEFI, mount the EFI System Partition as /mnt/boot/efi .

For example, if /dev/sda2 is to be mounted as / and dev/sda1 is the EFI System Partition:

Initialize swap space, if desired, using mkswap(8).

Base Installation

Follow only one of the two following subsections.

If on aarch64, it will be necessary to install a kernel package in addition to base-system . For example, linux is a kernel package that points to the latest stable kernel packaged by Void.

The XBPS Method

Select a mirror and use the appropriate URL for the type of system you wish to install. For simplicity, save this URL to a shell variable. A glibc installation, for example, would use:

XBPS also needs to know what architecture is being installed. Available options are x86_64 , x86_64-musl , i686 for PC architecture computers and aarch64 . For example:

This architecture must be compatible with your current operating system, but does not need to be the same. If your host is running an x86_64 operating system, any of the three architectures can be installed (whether the host is musl or glibc), but an i686 host can only install i686 distributions.

Use xbps-install(1) to bootstrap the installation by installing the base-system metapackage:

xbps-install might ask you to verify the RSA keys for the packages you are installing.

The ROOTFS Method

Unpack the tarball into the newly configured filesystems:

Configuration

With the exception of the section «Install base-system (ROOTFS method only)», the remainder of this guide is common to both the XBPS and ROOTFS installation methods.

Entering the Chroot

Mount the pseudo-filesystems needed for a chroot:

Читайте также:  Прошивка роутер tftp linux

Copy the DNS configuration into the new root so that XBPS can still download new packages inside the chroot:

Chroot into the new installation:

Install base-system (ROOTFS method only)

ROOTFS images generally contain out of date software, due to being a snapshot of the time when they were built, and do not come with a complete base-system . Update the package manager and install base-system :

Installation Configuration

Specify the hostname in /etc/hostname . Go through the options in /etc/rc.conf . If installing a glibc distribution, edit /etc/default/libc-locales , uncommenting desired locales.

nvi(1) is available in the chroot, but you may wish to install your preferred text editor at this time.

For glibc builds, generate locale files with:

Set a Root Password

Configure at least one super user account. Other user accounts can be configured later, but there should either be a root password, or a new user account with sudo(8) privileges.

To set a root password, run:

Configure fstab

The fstab(5) file can be automatically generated from currently mounted filesystems by copying the file /proc/mounts :

Remove lines in /etc/fstab that refer to proc , sys , devtmpfs and pts .

Replace references to /dev/sdXX , /dev/nvmeXnYpZ , etc. with their respective UUID, which can be found by running blkid(8). Referring to filesystems by their UUID guarantees they will be found even if they are assigned a different name at a later time. In some situations, such as booting from USB, this is absolutely essential. In other situations, disks will always have the same name unless drives are physically added or removed. Therefore, this step may not be strictly necessary, but is almost always recommended.

Change the last zero of the entry for / to 1 , and the last zero of every other line to 2 . These values configure the behaviour of fsck(8).

For example, the partition scheme used throughout previous examples yields the following fstab :

The information from blkid results in the following /etc/fstab :

Note: The output of /proc/mounts will have a single space between each field. The columns are aligned here for readability.

Add an entry to mount /tmp in RAM:

If using swap space, add an entry for any swap partitions:

Installing GRUB

Use grub-install to install GRUB onto your boot disk.

On a BIOS computer, install the package grub , then run grub-install /dev/sdX , where /dev/sdX is the drive (not partition) that you wish to install GRUB to. For example:

On a UEFI computer, install either grub-x86_64-efi , grub-i386-efi or grub-arm64-efi , depending on your architecture, then run grub-install , optionally specifying a bootloader label (this label may be used by your computer’s firmware when manually selecting a boot device):

Troubleshooting GRUB installation

If EFI variables are not available, add the option —no-nvram to the grub-install command.

Installing on removable media or non-compliant UEFI systems

Unfortunately, not all systems have a fully standards compliant UEFI implementation. In some cases, it is necessary to «trick» the firmware into booting by using the default fallback location for the bootloader instead of a custom one. In that case, or if installing onto a removable disk (such as USB), add the option —removable to the grub-install command.

Alternatively, use mkdir(1) to create the /boot/efi/EFI/boot directory and copy the installed GRUB executable, usually located in /boot/efi/void/grubx64.efi (its location can be found using efibootmgr(8)), into the new folder:

Finalization

Use xbps-reconfigure(1) to ensure all installed packages are configured properly:

This will make dracut(8) generate an initramfs, and will make GRUB generate a working configuration.

At this point, the installation is complete. Exit the chroot and reboot your computer:

After booting into your Void installation for the first time, perform a system update.

Источник

Оцените статью