-
Notifications
You must be signed in to change notification settings - Fork 176
migrateDIRACOS
This wiki page aims at giving you guidelines to migrate from an existing installation with Externals/LcgBundle to an installation with DIRACOS. Once your installation will have been migrated to DIRACOS, no more manual actions will be needed. We recommend to stop all the services and agents on the server while doing the migration.
For more information about DIRACOS itself, see DIRACOS repo
DIRACOS will not come with runit
anymore. This means that, if you have not already done it, you must make sure that your runit installation does not depend on DIRAC.
Please see here for how it should be.
The bashrc
file is not compatible with the existing one, and need to be adapted.
dirac-install
generates a bashrc
only at the first installation, but never modifies it, so you likely have its definition in a configuration management tool (puppet, chef, quattor if masochist, ...).
This is what a fresh bashrc
of v6r22 looks when installed with Externals/LcgBundle:
# DIRAC bashrc file, used by service and agent run scripts to set environment
export PYTHONUNBUFFERED=yes
export PYTHONOPTIMIZE=x
[ -z "$HOME" ] && export HOME=/afs/cern.ch/user/c/chaen
# CAs path for SSL verification
export X509_CERT_DIR=/etc/grid-security/certificates
export SSL_CERT_DIR=/etc/grid-security/certificates
export X509_VOMS_DIR=/tmp/chaen/SLC6/v6r22p11/etc/grid-security/vomsdir
# Some DIRAC locations
[ -z "$DIRAC" ] && export DIRAC=/tmp/chaen/SLC6/v6r22p11
export DIRACBIN=$DIRAC/Linux_x86_64_glibc-2.12/bin
export DIRACSCRIPTS=$DIRAC/scripts
export DIRACLIB=$DIRAC/Linux_x86_64_glibc-2.12/lib
export TERMINFO=$DIRAC/Linux_x86_64_glibc-2.12/share/terminfo:/usr/share/terminfo:/etc/terminfo
export RRD_DEFAULT_FONT=$DIRAC/Linux_x86_64_glibc-2.12/share/rrdtool/fonts/DejaVuSansMono-Roman.ttf
# Prepend the PYTHONPATH, the LD_LIBRARY_PATH, and the DYLD_LIBRARY_PATH
( echo $PATH | grep -q $DIRACBIN ) || export PATH=$DIRACBIN:$PATH
( echo $PATH | grep -q $DIRACSCRIPTS ) || export PATH=$DIRACSCRIPTS:$PATH
( echo $LD_LIBRARY_PATH | grep -q $DIRACLIB ) || export LD_LIBRARY_PATH=$DIRACLIB:$LD_LIBRARY_PATH
( echo $LD_LIBRARY_PATH | grep -q $DIRACLIB/mysql ) || export LD_LIBRARY_PATH=$DIRACLIB/mysql:$LD_LIBRARY_PATH
( echo $DYLD_LIBRARY_PATH | grep -q $DIRACLIB ) || export DYLD_LIBRARY_PATH=$DIRACLIB:$DYLD_LIBRARY_PATH
( echo $DYLD_LIBRARY_PATH | grep -q $DIRACLIB/mysql ) || export DYLD_LIBRARY_PATH=$DIRACLIB/mysql:$DYLD_LIBRARY_PATH
( echo $PYTHONPATH | grep -q $DIRAC ) || export PYTHONPATH=$DIRAC:$PYTHONPATH
# new OpenSSL version require OPENSSL_CONF to point to some accessible location
export OPENSSL_CONF=/tmp
# Gfal2 configuration and plugins
export GFAL_CONFIG_DIR=$DIRAC/Linux_x86_64_glibc-2.12/etc/gfal2.d
export GFAL_PLUGIN_DIR=$DIRACLIB/gfal2-plugins
# DIRAC platform
[ -z "$DIRACPLAT" ] && export DIRACPLAT=`$DIRAC/scripts/dirac-platform`
# IPv6 support
export GLOBUS_IO_IPV6=TRUE
export GLOBUS_FTP_CLIENT_IPV6=TRUE
# ARC Computing Element
export ARC_PLUGIN_PATH=$DIRACLIB/arc
# Fork support for xrootd
export XRD_RUNFORKHANDLER=1
This is what a fresh bashrc
looks when installed with DIRACOS:
# DIRAC bashrc file, used by service and agent run scripts to set environment
export PYTHONUNBUFFERED=yes
export PYTHONOPTIMIZE=x
[ -z "$DIRAC" ] && export DIRAC=/tmp/chaen/SLC6/v6r22p11
[ -z "$DIRACOS" ] && export DIRACOS=$DIRAC/diracos
. $DIRACOS/diracosrc
[ -z "$HOME" ] && export HOME=/afs/cern.ch/user/c/chaen
# CAs path for SSL verification
export X509_CERT_DIR=/etc/grid-security/certificates
export SSL_CERT_DIR=/etc/grid-security/certificates
export X509_VOMS_DIR=/tmp/chaen/SLC6/v6r22p11/etc/grid-security/vomsdir
# Some DIRAC locations
export DIRACSCRIPTS=$DIRAC/scripts
export TERMINFO=$DIRACOS/usr/share/terminfo:/usr/share/terminfo:/etc/terminfo
export RRD_DEFAULT_FONT=$DIRACOS/usr/share/fonts/DejaVuSansMono-Roman.ttf
# Prepend the PATH and set the PYTHONPATH
( echo $PATH | grep -q $DIRACSCRIPTS ) || export PATH=$DIRACSCRIPTS:$PATH
( echo $PYTHONPATH | grep -q $DIRAC ) || export PYTHONPATH=$DIRAC:$PYTHONPATH
# new OpenSSL version require OPENSSL_CONF to point to some accessible location
export OPENSSL_CONF=/tmp
# Gfal2 configuration and plugins
export GFAL_CONFIG_DIR=$DIRACOS/etc/gfal2.d
export GFAL_PLUGIN_DIR=$DIRACOS/usr/lib64/gfal2-plugins/
# DIRAC platform
[ -z "$DIRACPLAT" ] && export DIRACPLAT=`$DIRAC/scripts/dirac-platform`
# IPv6 support
export GLOBUS_IO_IPV6=TRUE
export GLOBUS_FTP_CLIENT_IPV6=TRUE
# ARC Computing Element
export ARC_PLUGIN_PATH=$DIRACOS/usr/lib64/arc
# Fork support for xrootd
export XRD_RUNFORKHANDLER=1
Two possibilities to migrate:
- Check the differences and adapt it to your setup
- make sure you do not have
bashrc
andcshrc
in the directory where DIRAC installed /opt/dirac:
mv bashrc bashrc_backup
rm cshrc (you can delete it because DIRACOS does not support anymore.
and let dirac-install
to generate bashrc
. If you added something to bashrc
please adapt.
DIRACOS is available as of DIRAC v6r21.
You just have to call dirac-install
as you normally do, adding --dirac-os
.
Updating via the web interface is not supported for this migration.
As of v7r0, you do not need this option anymore
There is a change of MySQL client version between the bundle and DIRACOS, the later one being more recent. This has several consequences on the MySQL server side:
- The server certificate has to support recent encryption
- The query cache should be disabled, otherwise there is a bug in MySQL resulting in the older or the newer client crashing if they are used in parallel. This can be done by setting
query-cache-size=0
and orquery-cache-type=0
(more details https://cern.service-now.com/service-portal/view-incident.do?n=INC2043147) - MySQL server 5.6 only: because of different Cipher list between server and client, the encryption has to be disabled. Comment out all the
ssl-*
options of your server configuration
In some cases the LCG software is preinstalled on the hosts running DIRAC services. This software is no more needed with the DIRACOS and can interfere destructively. In particular, GridEnv configuration option used in several places defined the location of the script to set up the preinstalled LCG software environment. When using DIRACOS, these options must be removed. These options can be defined in your installation on the System level, for example:
Systems/WorkloadManagement/Production/GridEnv=/usr/libexec/grid-env
It can be also defined as an option of the SiteDirector agent.