Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
How to submit simple jobs onto the Grid | ||||||||
Changed: | ||||||||
< < | On this page, we intend to provide a brief introduction on simple job submission onto the Grid. One can also find a brief introductory material on the Grid homepage of RMKI![]() | |||||||
> > | On this page, we intend to provide a brief introduction on simple job submission onto the Grid. One can also find a brief introductory material on the Grid homepage of RMI![]() | |||||||
Log onto a User Interface ( _UI) machineAfter you have logged onto a UI machine, you are able to submit commands to the Grid. You should have your Grid user key filesusercert.pem and userkey.pem under ~/.globus directory. If you have a certificate in PKCS#12 (.p12) format, you can convert it to PEM encoded certificate and private key using the following to commands:
openssl pkcs12 -in cert.p12 -clcerts -nokeys -out usercert.pem openssl pkcs12 -in cert.p12 -nocerts -out userkey.pemIf they are located, for whatever reason, under an alternative location, it can be told to the Grid applications by setting the following environmental variables, like: export X509_USER_CER=/some_directory/globus/usercert.pem
export X509_USER_KEY=/some_directory/globus/userkey.pem (for bash), or
setenv X509_USER_CER /some_directory/globus/usercert.pem
setenv X509_USER_KEY /some_directory/globus/userkey.pem (for tcsh).
By default, a directory called .glite should be present in your home directory. If, for whatever reason you wish to relocate this directory, you should tell this to the Grid system using the following environmental variables:
export GLITE_USER_HOME=/some_directory/glite (for bash), or
setenv GLITE_USER_HOME /some_directory/glite (for tcsh).
By default, on every User Interface machine, the Grid Certificates of the trusted sites are located under the /etc/grid-security/certificates directory. If they are located, for whatever reason, under an alternative location, it can be told to the Grid applications by setting the following environmental variables:
export X509_CERT_DIR=/some_directory/certificates (for bash), or
setenv X509_CERT_DIR /some_directory/certificates (for tcsh).
To customize the Grid behavior, the environmental variable GLITE_WMSUI_CONFIG_VAR can be used to point to a configuration file, like:
export GLITE_WMSUI_CONFIG_VAR=/some_directory/glite_wms.conf (for bash), or
setenv GLITE_WMSUI_CONFIG_VAR /some_directory/glite_wms.conf (for tcsh).
The default version of the file glite_wms.conf may be obtained from /opt/glite/etc/glite_wms.conf on any UI machine. (However, the prefix /opt may be different on various platforms, if non-standard installation directory is used for GLite.)
Log onto the Grid (get authenticated on the Grid)If you are member of more then one VO, you can choose between them by using theglite-voms-proxy-init for logging in, instead of grid-proxy-init command. E.g.:
> voms-proxy-init -voms hungrid Or:
> voms-proxy-init -voms hungrid -valid 04:00
By default, voms-proxy-init generates a proxy valid for 12 hours. You can request a maximum validity of 24 hours. Be aware that if your proxy expires when your jobs are still running (or waiting), they will abort automatically. You should use MyProxy (see below) for long-term jobs, or when submitting a lot of jobs (more than 200).
To get information on your user proxy, you can use the command voms-proxy-info -all . You can destroy your user proxy by voms-proxy-destroy.
Get your jobs authenticated on the GridThis means getting a so called job proxy. Commands are:> myproxy-init -d -n Here, you will be prompted for your grid password.
Running myproxy-init is necessary when you are running long-term jobs. Having a job proxy ensures that your jobs still will be authenticated on the Grid, even though your user proxy (used to perform interactive Grid manupulations) may have had expired. You can get information on your job proxy by myproxy-info -d . You can destroy your job proxy by myproxy-destroy -d . The default (and maximum) lifetime of a job proxy is 168 hours.
Note: If you don't get a job proxy, you may not be able to retrieve your job outputs for long-term jobs!
Prepare and submit your jobThe program which you want to run on the Grid is called a job. These consist of some executable(s) and some input(s), which can be submitted to the Grid system. The result shall be some output(s) and error(s), which can be retrieved after your job has finished. The job specifications are described for the Grid system by the so called Job Description Language ( JDL). For each of your jobs, you should prepare a JDL file. An example for a typical simple JDL file content may be:[ JobType = "Normal" Executable = "testjob.sh"; StdOutput = "testjob.stdoutanderror"; StdError = "testjob.stdoutanderror"; InputSandbox = {"testjob.sh", "inputfile.dat"}; OutputSandbox = {"testjob.stdoutanderror", "outputfile.dat"}; Requirements = ( Member("AFS", other.GlueHostApplicationSoftwareRunTimeEnvironment) && other.GlueCEPolicyMaxWallClockTime>=2160 && other.GlueHostMainMemoryRAMSize>=512 && RegExp("kfki.hu", other.GlueCEUniqueID); ); ]The meaning of the above variables are:
> glite-wms-job-list-match -a testjob.jdlThis will return a list of Grid queues (computing elements), which are capable of executing your job. The job can be submitted by the command: > glite-wms-job-submit -a testjob.jdlThis will return a sURL address, which is a unique identifier of your job, which shall be denoted by jobID in the followings.
The status of the job can be viewed by:
> glite-wms-job-status jobIDThis will return the current status of your job. If your job has failed to be ran by the Grid system, the logging may be retrieved by: > glite-wms-job-logging-info jobIDThis will return the logging info on your job. A convenient way to find out failure reasons is: > glite-wms-job-logging-info -v 3 jobID | grep "reason" | uniqThis will return all the available most detailed logging info on your job, and shall print lines containing the string "reason" , furthermore shall suppress multiple printing of consecutive identical lines.
If your job has properly finished, you can retrieve the outputs by the command:
> glite-wms-job-output jobIDThis will retrieve the content of the OutputSandbox into the directory /tmp/jobOutput/yourusername_jobID . It is also possible to specify some other directory name by the --dir switch.
For further information, look at the man pages of the above commands, and maybe also to the man pages of other glite-wms- commands. For further references on simple job submission, see https://edms.cern.ch/file/722398//gLite-3-UserGuide.pdf![]() |