Running LHCb software on Ubuntu 10.10
a modern operating system with a nice desktop environment, support for
hardware drivers, ... no comparison with slcxxx, cernvm, ...
recipe is also valid for Ubuntu 10.04
-
-
Create a Virtual Machine
(in case Ubuntu is used as native operating system, this step is
of course not needed)
-
Download Virtual Box for your host operating
system
- Start Virtual Box
- Select New: Give it a name,
select Linux as operating
system, select Ubuntu
(I am using 64bit Ubuntu on a
64bit Windows7 host)
- Select RAM: for single CPU,
2GB is ok.
(I am running with 8 core host
with 12GB RAM, can afford
7 cores for VM with 6GB RAM)
- Create hard disk,
suggest to use fixed size, 40GB
if you can afford.
- Select number of cores,
should always be less than on
the host
- Graphics: 64 MB, select 3d
acceleration
- Network: Intel PRO/1000 MT
Desktop (NAT)
- Under Harddisks, add
secondary master:
VBoxGuestAddtions.iso
- There is possibility to
share containers with your host.
Name of folder has to match name
in fstab. Example:
- windows
folder
W:Data
- create
folder: sudo
mkdir
/media/Data
- for
automatic
mounting
add to /etc/fstab:
Data
/media/Data
vboxsf defaults
0 0
-
Setup Ubuntu 10.10 / 11.04
- start Ubuntu
- for VM only: install Vbox additions: sudo -i, cd
/media/VBOXADDITIONS... , run
VBoxLinuxAdditions-amd64.run for 64 bit or
VBoxLinuxAdditions-x86.run for 32 bit, reboot
- create 2 directories in your home directory:
- mkdir cmtuser
- mkdir LHCb_software
- missing libraries and software package not
included in ISO image, download using package
installer
- openafs-client, krb5,
krb5-user
- when
installing enter
cern.ch for afs
cell
- configuring
kerberos, see
http://linux.web.cern.ch/linux/docs/kerberos-access.shtml
essentially copy
config file from
lxplus to local
machine, same
place:
/etc/krb5.conf
- svn, cvs
(not anymore
needed for
latest LHCb
software),
checksecurity
(was not needed
for Ubuntu
11.04)
- procmail
(needed to make
cmt happy,
contains
lockfile
- g++4.3
(g++4.4 for
Ubuntu 11.04)
-
libglu1-mesa-dev
- from lxplus copy and create
symbolic links for (only for
Ubuntu 10.10):
- sudo ln -s /usr/lib64/libtiff.so.3.8.2
/usr/lib64/libtiff.so.3
sudo ln -s /usr/lib64/libungif.so.4.1.3
/usr/lib64/libungif.so.4
sudo ln -s /usr/lib64/libgi
/usr/lib64/libungif.so.4
- for virtual box: sudo ln -s
/usr/lib/VBoxOGL.so /usr/lib/libGL.so
- install LHCb software
- in your login script, add
- setenv CMTUSERCONTEXT /home/truf/LHCb_software/fixCompiler
alias g++ /usr/bin/g++-4.3
(g++-4.4 for Ubuntu 11.04)
source /home/truf/LHCb_software/LbLogin.csh
-c x86_64-slc5-gcc43-opt
setenv CVSROOT :ext:isscvs.cern.ch:/local/reps/lhcb
(not needed if CVS is not used
- create directory /home/truf/LHCb_software/fixCompiler,
with file requirement containing:
- macro_remove cpp_name "lcg-"
macro_remove cpp_name "-$(gcc_config_version)"
macro cpp_name "g++-4.3"
(g++-4.4 for Ubuntu 11.04
- For Panoramix was necessary to cp ~/LHCb_software/lcg/external/Python/2.5/x86_64-slc5-gcc43-opt/lib/libpython2.5.so.1.0
~/LHCb_software/lhcb/COMPAT/COMPAT_v1r8/CompatSys/x86_64-slc5-gcc43-opt/lib/
- This should be all what is needed to get the
LHCb environment.
-
Access to Castor
- use castorfs from Alexander Mazurov (LHCb
Online), downloads:
http://github.com/mazurov/castorfs/archives/master
more info:
https://lbtwiki.cern.ch/bin/view/Online/CastorFS
- create directory castorfs in your home
directory
- mount castor using: castorfs -o castor_user=truf
-o castor_uid=.... -o castor_gid=... /home/truf/castorfs
where uid and gid are the ones of your userid on
lxplus
- files in castor are then seen and accessible
using ls, cp, rm, ... ~/castorfs/cern.ch/user/t/truf/...
or ~/castorfs/cern.ch/grid/lhcb/data/...
copy does not work yet in virtual machine.
According to Alexander, should work, under
investigation
-
Access to files on the Grid
- use Dirac: install_project -b LHCbDirac
- requires to magic environment variables to
be set in your login script
- setenv X509_CERT_DIR /afs/cern.ch/project/gd/LCG-share/current/external/etc/grid-security/certificates
setenv X509_VOMS_DIR /afs/cern.ch/project/gd/LCG-share/current/external/etc/grid-security/vomsdir
- for some reason, a file is missing in the
distribution. Copy from lxplus:
- cp
/afs/cern.ch/lhcb/sw/releases/DIRAC/DIRAC_v5r9p2/etc/dirac.cfg
/home/truf/LHCb_software/lhcb/DIRAC/DIRAC_v5r9p2/etc/dirac.cfg
- for installing Grid certificate, see
https://twiki.cern.ch/twiki/bin/view/LHCb/FAQ/Certificate
- Files can then be copied using: dirac-dms-get-file
-
Access to files on AFS
- (don't forget about the right setup file to
be copied from afs:
/etc/krb5.conf
- kinit username@CERN.CH
- aklog cern.ch # somehow needed to get
write access