Experimental High Energy Physics
The Niels Bohr Institute at the University of Copenhagen
Pages for physicists | Pages for the public

Installing the ATLAS Distribution Kit on RHEL3

UPDATE June 3rd, 2005: Since the quality of the instructions in the Atlas Wiki have improved dramatically, I no longer update these pages.

I do however keep a few private (unsupported) notes on my own pages

Here follows a small recipe of how to install an Atlas release on your RHEL3 workstation using the Atlas Distribution Kit, i.e. one of the heppc's.

It is known to work with at least releases 9.0.3 and 9.3.0. For older releases, you could try the previous version of this page.

The recipe is likely to work with minor modifications on other redhat-like distributions. See for instance the notes regarding Mandrake 10.1 below.

The following recipes assumes the following:

Obviously these assumptions are only valid for exactly one person (me!), so modify the commands below appropriately for your info. That is a general remark - these instructions are not "for dummies", you need to think about each step! Also, please read the entire instructions through before starting.

You will probably only have to do step 1 to 3 the first time around (but you must always go into the pacman dir and source the setup file in step 2 as well as sourcing the gcc setup file from step 3).

You might also find the instructions in the Atlas Wiki helpful in case of problems.

Installating the Kit

Step 1 : Decide where to install all of this

Lets start by making the directory where we plan to install atlas releases. If on a heppc you should install it in the /scr area of your machine - do NOT try to install it in your hep home directory (it requires approximately 4GB). If on your laptop you can pretty much choose to install it wherever you feel like it (what about /opt/atlasdist ?). On heppc07 I did the following:

cd /scr/kittel/
mkdir atlasdist
cd atlasdist/

Step 2 : Installing Pacman

The installation of the Atlas distribution kit is done by using a tool called pacman - a program which is kind of like rpm (but one doesn't need to be root to use it). We get it installed by doing (from the atlasdist directory we made before):

wget http://physics.bu.edu/pacman/sample_cache/tarballs/pacman-2.125.tar.gz
tar xvzf pacman-2.125.tar.gz
cd pacman-2.125/
. setup.sh
cd ..

Step 3 : Installing the right version of GCC

The version of gcc that is installed on RHEL3 (and on RH7.3 for that matter) will give you crashes if you try to mate it with Atlas releases.

The solution is to install an alternative version just for when you must work with Atlas releases. Since you already installed pacman and sourced its setup file, you can do

mkdir gcc
cd gcc
pacman -get -trust-all-caches http://classis01.roma1.infn.it/pacman/cache:gcc32
cd ..

Answer yes when pacman asks you whether to do the installation. This install provides a setup file for working with that compiler, but it doesn't quite cut it, so let us make one that does. So

emacs -nw /scr/kittel/atlasdist/setup-atlas-gcc-3.2.sh

and put the following in it:

#!/bin/sh
. /scr/kittel/atlasdist/gcc/setup.sh
export GCC_DIR_GCC3=$GCC_SITE
export GCC_DIR=$GCC_SITE
export PATH=$GCC_DIR/bin:$PATH
export LD_LIBRARY_PATH=$GCC_DIR/lib:$LD_LIBRARY_PATH

To use our newly downloaded compiler, do

. /scr/kittel/atlasdist/setup-atlas-gcc-3.2.sh

Step 4 : Installing an Atlas Distribution Kit

Having completed step 1-3 we can now install an Atlas Distribution Kit. First we make a specific directory for the release we want to install:

mkdir 9.0.3
cd 9.0.3/

And then, lets do the installation (yes, pacman has an -atlas !!):

export ATLAS=http://atlas.web.cern.ch/Atlas/GROUPS/SOFTWARE/OO/pacman/cache
pacman -get -atlas -trust-all-caches ${ATLAS}:9.0.3/AtlasRelease-opt
Answer "y" when it asks you if you want to install (obviously).

Wait a couple of hours while it hopefully installs without problems. While it installs you can watch the progress from another terminal by doing:

du -sh /scr/kittel/atlasdist/9.0.3

For 9.0.3 the final size should be something like 4.4GB.

Step 5 : Getting extra Red Hat 7.3 Libs

It turns out that we need a couple of libraries from 7.3 to work. So do:

mkdir /scr/kittel/atlasdist/EXTRALIBS
scp tkittel@lxplus7.cern.ch:/usr/local/lib/libcrypto.so.2 /scr/kittel/atlasdist/EXTRALIBS
scp tkittel@lxplus7.cern.ch:/usr/local/lib/libssl.so.2 /scr/kittel/atlasdist/EXTRALIBS

If you are going to compile your own libraries you might also (for unexplainable reasons) need to get hold of libshift. So in that case also do:

scp tkittel@lxplus7.cern.ch:/usr/local/lib/libshift.so /scr/kittel/atlasdist/EXTRALIBS

Step 6 : Making a setup file

Then we need to create a setup file that you can source when you want to work against the release later.

So do

emacs -nw /scr/kittel/atlasdist/setup-9.0.3.sh

And put something like the following in the content:

#!/bin/sh
#get right stdlibs and compiler:
. /scr/kittel/atlasdist/setup-atlas-gcc-3.2.sh
#setup release:
. /scr/kittel/atlasdist/9.0.3/setup.sh
#setup runtime environment:
. /scr/kittel/atlasdist/9.0.3/dist/9.0.3/Control/AthenaRunTime/AthenaRunTime-*/cmt/setup.sh
#add special rh7.3 libs to the end of the library search path:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/scr/kittel/atlasdist/EXTRALIBS
#for convenience:
alias athena=athena.py

Using the Release

Now you are all set. Lets assume that you have just logged in and want to work against the release you just installed and you want to work in ~/somerundir/ (create it if it doesnt exist).

cd ~/somerundir/
. /scr/kittel/atlasdist/setup-9.0.3.sh

What you do next really depends on what you want to do. Example:

get_files jobOptions.AtlasGeoG4Sim.py
get_files PDGTABLE.MeV
athena jobOptions.AtlasGeoG4Sim.py

Developing against the Release

If you want to use updated versions of packages with the release you can of course copy some local InstallArea (remember to get the content of symlinks with the -h flag to tar) from lxplus and make sure that its content is accessed first in various PATH variables (I will add instructions here at some point - sooner if urged to).

A better option is probably to follow Esben Bryndt Klinkby's instructions of how to do proper development against the kit on the heppc's, since this also allows you to checkout and compile the packages locally.

Doing Kit Validation

Jørgen Beck Hansen found the following recipe for using the Atlas KitValidation. First, enter the atlasdist area and set up pacman as usual:

cd /scr/kittel/atlasdist
cd pacman-2.125/
. setup.sh
cd ..
Then do (the name "Validation-9.0.3" is arbitrary)
mkdir Validation-9.0.3
cd Validation-9.0.3
pacman -get -trust-all-caches http://classis01.roma1.infn.it/pacman/cache:9.0.3/KitValidation
As usual, answer "y" when it asks you if you want to install. Now the validation kit should be installed, so run it by doing
. /scr/kittel/atlasdist/setup-9.0.3.sh
./KitValidation/KitValidation-*/share/KitValidation -r 9.0.3 \
      -p /scr/kittel/atlasdist/9.0.3 -kng -t `pwd` \
      -c /scr/kittel/atlasdist/gcc/gcc-alt-3.2 --use-root
It takes about an hour to run.

Notes