Instructions for making a tarball to be used on the farm to run simulation on HPEG files: I start from this webpage: http://www-cdf.fnal.gov/internal/mcProduction/howtoRequestMcv4_5_3.html This is Frank's prescription for how to generate MC events with Pythia and run them through simulation, all on the farm. What I've done is to take this, remove the Pythia stuff, change the input in DHInput from the output of Pythia to a file Miro gets from the DB, and change the output in DHOutput to write to the database... Here's how: First, start in your scratch on fcdflnx2 or fcdflnx3 (I use fcdflnx3). Following the instructions from the webpage above, type source ~cdfsoft/cdf2.cshrc setup cdfsoft2 4.5.3 newrel -t 4.5.3 myRelease cd myRelease cvs co -r mcv4_5_3 mcProduction cd .. myRelease/mcProduction/scripts/compileExeTarball 4.5.3 >& exe4.5.3.log & This takes a bit... This creates two things, a directory CDF4.5.3 and a tarball of the directory in your scratch area (i.e. in the directory above myRelease). We're going to ignore the tarball, edit stuff in the directory and make a new tarball by hand... So, in the directory CDF4.5.3 type: mv runMC4.5.3 runMC This is because we want to create a wrapper script called runMC4.5.3 which is what Miro will run from the farm. This script will do two things. If given only one input, it will run a monte carlo job generating events from Pythia through simulation. This will be done through a .tcl file which we don't concern ourselves with here. If given two inputs, it will simulate the second input (the HEPG file Miro gives it) with the first input (which is the appropriate .tcl file which we will write shortly. Here is the script I wrote: fcdflnx3:~/scratch/CDF4.5.3> more runMC4.5.3 #!/bin/tcsh -f if ( $2 == "" ) then source source_me ./runMC $1 >& $1.log else setenv INPUT_FILE $2 setenv SECNUM `echo $INPUT_FILE | awk -F . '{print $2}' | awk -F g '{print $1}' | hextodec.exe` @ GRNDM3 =( {154710} + (${SECNUM} * {28293}) ) @ GRNDM4 =( {78951} + (${SECNUM} * {6482}) ) setenv GRNDM1 $GRNDM3 setenv GRNDM2 $GRNDM4 source source_me ./runMC $1 >& $2.log endif BTW, this is a good time to tell you that the directory I created with all the modified files I have mentioned and will mention here is fcdflnx3:~cwolfe/scratch/CDF4.5.3 The second part of the script takes the input file, parses out the section number of the file name (which takes the form mc014fb4.0001gene), sets two random number seeds from the section number which will be needed for the simulation, and then executes runMC. The program hextodec.exe, which can be found in the directory above, is a simple program which converts hex numbers to decimal. The code for this program can be found in fcdflnx3:~cwolfe/scratch/. So, that's easy enough. The next thing we need to is create the .tcl file. Again, this was taken from what Frank has, and modified slightly. I don't want to list the entire .tcl file here, so I urge you to just copy the one I made which is fcdflnx3:~cwolfe/scratch/CDF4.5.3/farm.tcl. To actually do this yourself, create a .tcl file from Frank's instructions in the web page above. e.g.: myRelease/mcProduction/tcl>../scripts/makeTcl.csh 85889 5000 template_WW.tcl 20 will make some .tcl files and place them in myRelease/mcProduction/tcl/85889/. Take one of them (any one really) and compare with my .tcl file noted above. Delete everything you don't see in the .tcl above -- I've tried to indicate which sections I've deleted in farm.tcl. (These files are just quite large, so I don't want to print them out here.) Other changes to make which are important are: set fRandomSeedGRNDM1 $env(GRNDM1) set fRandomSeedGRNDM2 $env(GRNDM2) #instead, specify the datasetID set dataset_id mtestc # This sets up the Random Number seed: talk RandomGenManager RandomNumberMenu RandomSeedGRNDM1 set $fRandomSeedGRNDM1 RandomSeedGRNDM2 set $fRandomSeedGRNDM2 exit exit # Input the file... module input DHInput # for the database, DHInput should look something like this: talk DHInput input file $env(INPUT_FILE) exit module output DHOutput talk DHOutput output create stream $dataset_id output setstream stream pathname=. output setstream stream dfc=production_file_catalog_write anysize list output path stream $outputPath This file should be copied in the base directory of the tarball, i.e. CDF4.5.3/farm.tcl. So, the files you should have added in CDF4.5.3/ are runMC4.5.3 (which should be made executable -- chmod 755 runMC4.5.3), farm.tcl, and hextodec.exe (which should also be executable). That's it. Now make the tarball, and we're done: tar -cvzf runMC4.5.3.tar.gz CDF4.5.3 If you have any questions, email me, Collin, at cwolfe@hep.uchicago.edu.