Install RPMs using Yum

Table of contents

If you are running a RPM-based distribution, such as Scientific Linux, you can now get the same versions of ALICE software we deploy on the Grid via Yum.

RPM support is currently under testing. Only tagged AliPhysics versions are available for now.

Install the CERN CA certificate

Our packages are downloadable from a HTTPS server whose certificate is signed by CERN. This is to ensure that data transferred during package download does not get tampered by a third party.

SLC5, SLC6, CC7

There exists a package for that. Check if you have it installed and install it if missing. As root:

rpm -q CERN-CA-certs || yum install CERN-CA-certs

Prior to CC7 you also need to run (once again as root):

update-ca-trust enable && update-ca-trust

Other RHEL-compatible distributions

Alternatively you can use the following sequence:

curl -o /etc/pki/ca-trust/source/anchors/CERN_Grid_CA.pem \
     https://cafiles.cern.ch/cafiles/certificates/CERN%20Grid%20Certification%20Authority.crt && \
update-ca-trust enable && \
update-ca-trust && \
echo "all ok"

You should see all ok if everything went right. If this does not work for you, there is some extensive documentation on the web.

You can also check out the place where to manually download the CERN Grid CA certificate.

Configure the ALICE Yum repository

As root, you can create the repository file by copying-pasting the following lines to your prompt:

cat > /etc/yum.repos.d/alisw-el5.repo <<EOF
[alisw-el5]
name=ALICE Software - EL5
baseurl=https://ali-ci.cern.ch/repo/RPMS/el5.x86_64/
enabled=1
gpgcheck=0
EOF

List, install, remove packages

In order to avoid conflicts with other software installed on your system, ALICE packages are fully installed under /opt/alisw and no other directory is affected. Moreover, you will need to enable the “environment” for running them explicitly.

All ALICE package names are prefixed with alisw, so, once you have installed the repository manifest, you can simply do:

yum search alisw

or, to list all AliPhysics versions:

yum search alisw-AliPhysics

To install a certain version:

yum install alisw-AliPhysics+vAN-20151013-1

All dependencies are installed automatically.

Do not remove packages by deleting the /opt/alisw directory! Instead, use Yum:

yum remove alisw-AliPhysics+vAN-20151013-1

Recent RHEL/Fedora/etc. versions have a better remove that uninstalls dangling dependencies, so it is actually recommended doing:

yum autoremove alisw-AliPhysics+vAN-20151013-1

Installed ALICE packages can be listed by using the following command:

rpm -qa | grep ^alisw

You can also remove every ALICE package installed by typing:

rpm -qa | grep ^alisw | xargs -L1 --no-run-if-empty yum remove -y

Use installed ALICE software

ALICE software is not “loaded” or “enabled” automatically on your environment: you need to enable it explicitly.

Once for all, configure your .bashrc in order to export the following variable:

export MODULEPATH=/opt/alisw/el5/modulefiles:$MODULEPATH

Exit and re-enter your shell (or re-source your `.bashrc) when done.

Loading the environment uses Environment Modules, which makes it very easy to load and unload environment configurations. Please refer to its documentation for an exhaustive explanation. A quick guide follows.

List all available software:

modulecmd bash avail

Load a certain version of AliPhysics from the list of available modules:

eval $(modulecmd bash load AliPhysics/vAN-20151013-1)

Note that this affects the current shell only. All dependencies are loaded automatically.

You can also list the modules currently loaded in the current shell:

modulecmd bash list

And finally you can unload a module (and its dependencies):

eval $(modulecmd bash unload AliPhysics/vAN-20151013-1)

modulecmd takes the shell type as first argument: if you do not use Bash, you can type your shell name instead, such as ksh or csh.