Storage Element (SE) name change
In case the FQDN of a SE changes, some entries need to be modified in the LFC databases.
This is taken care of automatically by the
update-LFC-after-SE-renamed.pl
script.
It is not yet included in any
LFC
RPM, but can be found in the gLite CVS repository :
-
LCG-DM
module
- under
script/change-se-name
Note : the script only supports Oracle as a database backend for the moment.
Requirements
To run the
update-LFC-after-SE-renamed.pl
script, the following packages need to be installed :
-
perl
-
perl-DBI
-
perl-DBD
(for Mysql or Oracle)
Note : if using
Mysql
>= 4.1,
perl-DBD-mysql
>= 2.9003 should be used.
Note2 : the script only supports Oracle as a database backend for the moment.
Example for Oracle
The
dummy
option only shows the SQL statements that will be executed in the LFC database. But no change will actually be made.
./update-LFC-after-SE-renamed.pl --db LFC_SID --user lfc_user --pwd XXXXX --oldSE castorgrid.cern.ch --newSE castor.cern.ch --dummy
SQL : UPDATE Cns_file_replica SET host='castor.cern.ch' WHERE fileid=596 and sfn='sfn://castorgrid.cern.ch/castor/cern.ch/grid/atlas/bphys/
digit/017502.bb_mu6mu6X/data/bphys.017502.digit.bb_mu6mu6X._00048.pool.root.1'
SQL : UPDATE Cns_file_replica SET sfn='sfn://castor.cern.ch/castor/cern.ch/grid/atlas/bphys/digit/017502.bb_mu6mu6X/data/bphys.017502.digit
.bb_mu6mu6X._00048.pool.root.1' WHERE fileid=596 and sfn='sfn://castorgrid.cern.ch/castor/cern.ch/grid/atlas/bphys/digit/017502.bb_mu6mu6X/dat
a/bphys.017502.digit.bb_mu6mu6X._00048.pool.root.1'
...
Dummy run completed. 343 rows to change.
./update-LFC-after-SE-renamed.pl --db LFC_SID --user lfc_user --pwd XXXXX --oldSE castorgrid.cern.ch --newSE castor.cern.ch
Update complete. 343 rows changed.
Troubleshooting
In case the script complains about
NLS_XXXX
parameters, just unset all the
NLS_XXXX
environment variables before running the script :
unset NLS_LANG
unset ORA_NLS33
unset NLS_DATE_FORMAT
Help !
In case of problems, contact
helpdesk@ggusNOSPAMPLEASE.org (remove the NOSPAM !) : your ROC will help you and contact the appropriate experts if needed.
--
SophieLemaitre - 17 May 2006