Setting up a BaBar Xrootd Server
From GridPP Wiki
Revision as of 16:57, 26 October 2005 by Chris brew (Talk | contribs)
The initial setup and configuration of the daemon needs to be done as root, once that is done configuring the BaBar software to use the xrootd server and importing data to it can be done as a bfactory equivalant account.
This write up assumes the processes will be run as bfactory and the data will be held in /data
Contents
Setting up the Daemon
- Install the base rpm (from http://xrootd.slac.stanford.edu/):
rpm -Uvh http://xrootd.slac.stanford.edu/download/<version>/xrootd-<version>.i386_rhel30.i386.rpm
- Write a config file /opt/xrootd/etc/xrootd.cf
Example xrootd.cf File
# Simple xrootd config for Bham # CAJB 20050908 # Xrd Configuration # xrootd configuration xrootd.fslib /opt/xrootd/lib/libXrdOfs.so xrootd.export /store #xrootd.trace request #OSS Configuration oss.path /store r/o oss.localroot /data/ ofs.trace open
- Create a local StartXRD.cf startup config file by editing the example file:
Example StartXrd.cf Diffs
18c18 < XRDUSER=bbdatsrv --- > XRDUSER=bfactory 28c28 < XRDVER=prod --- > XRDVER= 42c42 < XRDHOMEDIR=/var/adm/xrootd/core --- > XRDHOMEDIR=/opt/xrootd/core 47c47 < XRDLOGDIR=/var/adm/xrootd/logs --- > XRDLOGDIR=/opt/xrootd/logs 59,73c59,73 < RESP=`/usr/local/bin/taylor -q opts | grep '^olbd=.*super'` < if [ $? -eq 0 ]; then < XRDMODE='-r -t' < XRDTYPE='supervisor' < fi < RESP=`/usr/local/bin/taylor -q opts | grep '^olbd=.*server'` < if [ $? -eq 0 ]; then < XRDMODE='-t' < XRDTYPE='target' < fi < RESP=`/usr/local/bin/taylor -q opts | grep '^olbd=.*manager'` < if [ $? -eq 0 ]; then < XRDMODE='-r' < XRDTYPE='manager' < fi --- > #RESP=`/usr/local/bin/taylor -q opts | grep '^olbd=.*super'` #if [ $? > -eq 0 ]; then #XRDMODE='-r -t' > #XRDTYPE='supervisor' > #fi > #RESP=`/usr/local/bin/taylor -q opts | grep '^olbd=.*server'` #if [ $? > -eq 0 ]; then #XRDMODE='-t' > #XRDTYPE='target' > #fi > #RESP=`/usr/local/bin/taylor -q opts | grep '^olbd=.*manager'` #if [ > $? -eq 0 ]; then #XRDMODE='-r' > #XRDTYPE='manager' > #fi
- Create and set the ownership of the log and core dirs:
mkdir /opt/xrootd/logs /opt/xrootd/core chown bfactory:babar /opt/xrootd/logs /opt/xrootd/core
- Copy over and set up the sysV init script and set xrootd to start at system startup
chkconfig xrootd on
- Make the data directory
mkdir /data/store chown bfactory:babar /data/store
Configuring the BaBar Software to use the Server
This should be done as bfactory
- Write the $BFROOT/kanga/config/KanAccess.cfg file
Sample simple SP only KanAccess.cfg from Birmingham
read /store/SP/BkgTriggers* xrootd epbf002.ph.bham.ac.uk
This file should be copied to the VO_BABAR_SW_AREA at part of the Site setup.
- Make the BkgTriggers Area
mkdir -p /data/store/SP/BkgTriggers
- Import some Collections
scp 'bbdatsrv@csfmove01.rl.ac.uk:/stage/bdata-data37/kanga/store/SP/BkgTriggers/BkgTriggers_200201_O*' .
--Chris brew 17:57, 26 Oct 2005 (BST)