Difference between revisions of "BaBar: Updating ProdTools at RAL"
Chris brew (Talk | contribs) |
(No difference)
|
Latest revision as of 13:28, 27 April 2006
First check the uk-spgrid tools into the SLAC CVS then instead of updating back (downdating) to the original version of ProdTools
+ your new tag of uk-spgrid
use the new version of ProdTools
+ your tag of uk-spgrid
.
We currently need to make some slight alterations to the spbuild
utility to make is build the grid config files so we create a modified verion in site/uk-spgrid
called spbuid-grid
. If spbuild has changed you'll need to rebuild the file. I use diff and diff3 to do this.
First acertain whether spbuild has changed:
[lcgui0357] /afs/rl.ac.uk/bfactory/prod > diff ProdTools-2006-04-27/spbuild ProdTools/spbuild 412,414c412,414 < } elsif( $use_cycle eq 'SP8' ) { < #For SP8 the background triggers are now separated by on peak and off < #peak data. The info on these collection needed to go into another --- > } elsif( $use_cycle eq 'SP8' || $use_cycle eq 'SP9' ) { > #For SP8 and SP9 the background triggers are now separated by on peak and > #off peak data. The info on these collection needed to go into another 761c761 < if( $use_cycle eq 'SP8' ) { --- > if( $use_cycle eq 'SP8' || $use_cycle eq 'SP9' ) { 840c840 < if( $use_cycle eq 'SP8' ) { --- > if( $use_cycle eq 'SP8' || $use_cycle eq 'SP9' ) { 863c863 < if( $use_cycle eq 'SP8' ) { --- > if( $use_cycle eq 'SP8' || $use_cycle eq 'SP9' ) {
Now use diff3
to see if there are any conflicts with our changes:
[lcgui0357] /afs/rl.ac.uk/bfactory/prod > diff3 ProdTools-2006-04-27/site/uk-spgrid/spbuild-grid ProdTools-2006-04-27/spbuild ProdTools/spbuild ====1 1:21c unshift(@INC, $ENV{'PRODTOOLS'}); 2:20a 3:20a ====1 1:42c "GRID:s", 2:41c 3:41c "GRID", ====3 1:413,415c 2:412,414c } elsif( $use_cycle eq 'SP8' ) { #For SP8 the background triggers are now separated by on peak and off #peak data. The info on these collection needed to go into another 3:412,414c } elsif( $use_cycle eq 'SP8' || $use_cycle eq 'SP9' ) { #For SP8 and SP9 the background triggers are now separated by on peak and #off peak data. The info on these collection needed to go into another ====3 1:762c 2:761c if( $use_cycle eq 'SP8' ) { 3:761c if( $use_cycle eq 'SP8' || $use_cycle eq 'SP9' ) { ====1 1:786,802c if( defined($opts{'GRID'}) ) { require("batchUtils.pl"); buildGridFiles($run,$procspec,$srtrel,$bkg,$condalias,$USERDEC,$USERDECFILT,$JOBGRP,$opts{'GRID'}); # if( $opts{'GRID'} ) { # open JDLFILE, ">job.jdl"; # print JDLFILE "Executable =\"Job.bash\";\n"; # print JDLFILE "InputSandbox ={\"Job.bash\",\"config.sh\""; # print JDLFILE ",\"$USERDEC\"" if( $USERDEC ); # print JDLFILE ",\"$USERDECFILT\"" if( $USERDECFILT ); # print JDLFILE "};\n"; # print JDLFILE "StdOutput =\"Moose.txt\";\n"; # print JDLFILE "StdError =\"simu$run.log\";\n"; # print JDLFILE "OutputSandbox ={\"Moose.txt\",\"simu$run.log\"};\n"; # print JDLFILE "OutputSE =\"grid2.fe.infn.it\";\n"; # close JDLFILE; # # copy( "$PRODTOOLS/Job.bash", "Job.bash" ); 2:785,798c 3:785,798c if( $opts{'GRID'} ) { open JDLFILE, ">job.jdl"; print JDLFILE "Executable =\"Job.bash\";\n"; print JDLFILE "InputSandbox ={\"Job.bash\",\"config.sh\""; print JDLFILE ",\"$USERDEC\"" if( $USERDEC ); print JDLFILE ",\"$USERDECFILT\"" if( $USERDECFILT ); print JDLFILE "};\n"; print JDLFILE "StdOutput =\"Moose.txt\";\n"; print JDLFILE "StdError =\"simu$run.log\";\n"; print JDLFILE "OutputSandbox ={\"Moose.txt\",\"simu$run.log\"};\n"; print JDLFILE "OutputSE =\"grid2.fe.infn.it\";\n"; close JDLFILE; copy( "$PRODTOOLS/Job.bash", "Job.bash" ); ====3 1:844c 2:840c if( $use_cycle eq 'SP8' ) { 3:840c if( $use_cycle eq 'SP8' || $use_cycle eq 'SP9' ) { ====3 1:867c 2:863c if( $use_cycle eq 'SP8' ) { 3:863c if( $use_cycle eq 'SP8' || $use_cycle eq 'SP9' ) {
In general as in this case there should not be any conflicts between our changes and the offical ones so you should be able to use the -m
option of diff3
to regenerate spbuild-grid
diff3 -m ProdTools-2006-04-27/site/uk-spgrid/spbuild-grid ProdTools-2006-04-27/spbuild \ ProdTools/spbuild >! ProdTools/site/uk-spgrid/spbuild-grid
Finally check that the generated perl
looks OK:
[lcgui0357] /afs/rl.ac.uk/bfactory/prod > perl -c ProdTools/site/uk-spgrid/spbuild-grid ProdTools/site/uk-spgrid/spbuild-grid syntax OK
You should now be good to go.
Chris brew 14:28, 27 Apr 2006 (BST)