To submit a job to the LSF thourgh the condor G with birdbath APIs, your ClassAdStructAttr should contains required attributes. I retrieved the list of keywords from my previous example: Submitting a job to LSF job queue [2]. After submitting condor job with example[2], run condor_q -l, than you can get a list of valid keywords. Please note that even though you use wrong keyword, condor WON'T throw any exception, and your job WON'T go through. (now I'm pulling my hair.) Therefore, make something runs correctly even though it's not with birdbath APIs, and start from the valid keywords generated from that example.
* Attributes In, Out, and Err are used for specifying Standard Input, output, and error redirections. Therefore if your executables uses standard input/output and redirects them to files, those should be specified with these attributes.
* In this case, pw.x generates multiple files besides stdout output files. Attribute
TransferOutput specifies files that should be transfered after the process is done.
* Attribute GlobusRSL is equivalant to the keyword globusrsl in the script file for the command line submission by condor_submit.
* Many many thanks to Marlon for helping me out!!
Actual ClassAdStructAttr[] is following:
------------------------------------------------------------------------------------------------------------------------------
ClassAdStructAttr[] extraAttributes =
{
new ClassAdStructAttr("GridResource", ClassAdAttrType.value3, gridResourceVal),
new ClassAdStructAttr("TransferExecutable",ClassAdAttrType.value4,"FALSE"),
new ClassAdStructAttr("Out", ClassAdAttrType.value3, tmpDir+"/"+"pwscf-"+clusterId+".out"),
new ClassAdStructAttr("UserLog",ClassAdAttrType.value3, tmpDir+"/"+"pwscf-"+clusterId+".log"),
new ClassAdStructAttr("Err",ClassAdAttrType.value3, tmpDir+"/"+"pwscf-"+clusterId+".err"),
new ClassAdStructAttr("In",ClassAdAttrType.value3, workDir+"/"+"Pwscf_Input"),
new ClassAdStructAttr("ShouldTransferFiles", ClassAdAttrType.value2,"\"YES\""),
new ClassAdStructAttr("WhenToTransferOutput", ClassAdAttrType.value2,"\"ON_EXIT\""),
new ClassAdStructAttr("StreamOut", ClassAdAttrType.value4, "TRUE"),
new ClassAdStructAttr("StreamErr",ClassAdAttrType.value4,"TRUE"),
new ClassAdStructAttr("TransferOutput",ClassAdAttrType.value2,
"\"pwscf.pot, pwscf.rho, pwscf.wfc, pwscf.md, pwscf.oldrho, pwscf.save, pwscf.update\""),
new ClassAdStructAttr("TransferOutputRemaps",ClassAdAttrType.value2,
"\"pwscf.pot="+tmpDir+"/"+"pwscf-"+clusterId+
".pot; pwscf.rho="+tmpDir+"/"+"pwscf-"+clusterId+
".rho;pwscf.wfc="+tmpDir+"/"+"pwscf-"+clusterId+
".wfc; pwscf.md="+tmpDir+"/"+"pwscf-"+clusterId+
".md; pwscf.oldrho="+tmpDir+"/"+"pwscf-"+clusterId+
".oldrho; pwscf.save="+tmpDir+"/"+"pwscf-"+clusterId+
".save; pwscf.update="+tmpDir+"/"+"pwscf-"+clusterId+".update\""),
new ClassAdStructAttr("GlobusRSL", ClassAdAttrType.value2,
"\"(queue=development)(environment=(PATH /usr/bin))(jobtype=single)(count=1)\""),
new ClassAdStructAttr("x509userproxy",ClassAdAttrType.value3,proxyLocation),
};
------------------------------------------------------------------------------------------------------------------------------
Friday, January 4, 2008
Pwscf output files?
In my local machine, pw.x generates output files besides the standard output:
pwscf.pot, pwscf.rho, pwscf.wfc
unless I reuse the tmp directory.
However, in lonestar, it genrates,
pwscf.md pwscf.oldrho pwscf.pot pwscf.rho pwscf.save pwscf.update pwscf.wfc
For sure, I transfer all of the possible files from the remote machine.
pwscf.pot, pwscf.rho, pwscf.wfc
unless I reuse the tmp directory.
However, in lonestar, it genrates,
pwscf.md pwscf.oldrho pwscf.pot pwscf.rho pwscf.save pwscf.update pwscf.wfc
For sure, I transfer all of the possible files from the remote machine.
Submitting a job to LSF job queue [2]: through CondorG with condor_submit
Now, I tried to submit the same job, pw.x with the remote input files through the CondorG command line which is condor_submit. In this example, I use inputfiles stored in my local machine. Therefore, my script file should specify input files like following lines.
---------------------------------------------------------------------------------------------------------------------------------
executable = /home/teragrid/tg459282/vlab/pw.x
transfer_executable = false
should_transfer_files = yes
when_to_transfer_output = ON_EXIT
transfer_input_files = /home/leesangm/catalina/VLAB_Codes/__CC5f_7/008-O-ca--bm3.vdb,/home/leesangm/catalina/VLAB_Codes/__CC5f_7/__cc5_7,/home/leesangm/catalina/VLAB_Codes/__CC5f_7/Mg.vbc3
universe = grid
grid_resource = gt2 tg-login.tacc.teragrid.org/jobmanager-lsf
output = tmpfile.out.$(Cluster)
error = condorG.err.$(Cluster)
log = condorG.log.$(Cluster)
input = /home/leesangm/catalina/VLAB_Codes/__CC5f_7/Pwscf_Input
globusrsl = (queue=development)\
(environment=(PATH /usr/bin))\
(jobtype=single)\
(count=1)
queue
---------------------------------------------------------------------------------------------------------------------------------
This script file is almost the same with normal condor submit script except for the globusrsl keyword. This is a simple case for the serial job. For the parallel jobs, this should be modified.
Then submit condor job,
condor_submit script_file_name
---------------------------------------------------------------------------------------------------------------------------------
executable = /home/teragrid/tg459282/vlab/pw.x
transfer_executable = false
should_transfer_files = yes
when_to_transfer_output = ON_EXIT
transfer_input_files = /home/leesangm/catalina/VLAB_Codes/__CC5f_7/008-O-ca--bm3.vdb,/home/leesangm/catalina/VLAB_Codes/__CC5f_7/__cc5_7,/home/leesangm/catalina/VLAB_Codes/__CC5f_7/Mg.vbc3
universe = grid
grid_resource = gt2 tg-login.tacc.teragrid.org/jobmanager-lsf
output = tmpfile.out.$(Cluster)
error = condorG.err.$(Cluster)
log = condorG.log.$(Cluster)
input = /home/leesangm/catalina/VLAB_Codes/__CC5f_7/Pwscf_Input
globusrsl = (queue=development)\
(environment=(PATH /usr/bin))\
(jobtype=single)\
(count=1)
queue
---------------------------------------------------------------------------------------------------------------------------------
This script file is almost the same with normal condor submit script except for the globusrsl keyword. This is a simple case for the serial job. For the parallel jobs, this should be modified.
Then submit condor job,
condor_submit script_file_name
Submitting a job to LSF job queue [1] : On the Cluster
* Usefule LSF commands :
bsub: submission jobs
bjobs: display information about the jobs
bkills: send signal to kill
For more commands,
http://its.unc.edu/dci/dci_components/lsf/lsf_commands.htm
* Useful options of bsub command
-q : name of the queue
-n: desired number of processors
-W: Walltime limit in batch jobs -W[hours]:[minutes]
-i : input file
-o : output file
-e: error file
Example lsf submit of pw.x in lonestar
bsub -q development -n 1 -W 15 -i "Pwscf_Input" -o "myout.out" ../pw.x
bsub: submission jobs
bjobs: display information about the jobs
bkills: send signal to kill
For more commands,
http://its.unc.edu/dci/dci_components/lsf/lsf_commands.htm
* Useful options of bsub command
-q : name of the queue
-n: desired number of processors
-W: Walltime limit in batch jobs -W[hours]:[minutes]
-i : input file
-o : output file
-e: error file
Example lsf submit of pw.x in lonestar
bsub -q development -n 1 -W 15 -i "Pwscf_Input" -o "myout.out" ../pw.x
Thursday, January 3, 2008
Building a Client of the Task Executor
To generate client of the vlab Task Executor service, first we have to create stub code and compile them.
If the service is running on localhost, WSDL file is located at,
http://localhost:8080/task-executor/services/TaskExecutor?wsdl
With this WSDL file, we can generate java classes with WSDL2Java included in the axis package.
java org.apache.axis.wsdl.WSDL2Java http://localhost:8080/task-executor/services/TaskExecutor?wsdl
Then compile/jar the java code.
Required jar files to run WSDL2Java are following:
If the service is running on localhost, WSDL file is located at,
http://localhost:8080/task-executor/services/TaskExecutor?wsdl
With this WSDL file, we can generate java classes with WSDL2Java included in the axis package.
java org.apache.axis.wsdl.WSDL2Java http://localhost:8080/task-executor/services/TaskExecutor?wsdl
Then compile/jar the java code.
Required jar files to run WSDL2Java are following:
- axis-1.4.jar
- activation-1.1.jar
- commons-discovery-0.2.jar
- saaj.jar
- jaxrpc.jar
- mail-1.4.jar
- wsdl4j-1.5.1.jar
Friday, December 14, 2007
Globus environment
Step. 0 source $GLOBUS_LOCATION/etc/globus-user-env.sh
Step. 00 export X509_CERT_DIR=/home/leesangm/.globus/certificates
Step. 000 Check if this works,
globusrun -o -r grid-co.ncsa.teragrid.org/jobmanager '&(executable=/bin/ls)'
condor_rm -forcex -all : force the immediate local removal of jobs in the X state
Step. 00 export X509_CERT_DIR=/home/leesangm/.globus/certificates
Step. 000 Check if this works,
globusrun -o -r grid-co.ncsa.teragrid.org/jobmanager '&(executable=/bin/ls)'
condor_rm -forcex -all : force the immediate local removal of jobs in the X state
Wednesday, December 5, 2007
Condor/Birdbath documentations
Birdbath section in the condor manual:
http://www.cs.wisc.edu/condor/manual/v6.8/4_4Application_Program.html
Marlon's Blog
Condor Installation: http://communitygrids.blogspot.com/2007/07/beating-condor-like-rented-buzzard.html
Submitting Globus job through condor: http://communitygrids.blogspot.com/2006/09/submitting-globus-job-through-condor.html
http://www.cs.wisc.edu/condor/manual/v6.8/4_4Application_Program.html
Marlon's Blog
Condor Installation: http://communitygrids.blogspot.com/2007/07/beating-condor-like-rented-buzzard.html
Submitting Globus job through condor: http://communitygrids.blogspot.com/2006/09/submitting-globus-job-through-condor.html
Subscribe to:
Posts (Atom)