'\" t .\"___INFO__MARK_BEGIN__ .\" .\" Copyright: 2004 by Sun Microsystems, Inc. .\" .\"___INFO__MARK_END__ .\" .\" Some handy macro definitions [from Tom Christensen's man(1) manual page]. .\" .de M \" man page reference \\fI\\$1\\fR\\|(\\$2)\\$3 .. .TH drmaa_submit 3 "2008-07-08" "SGE 8.1.3pre" "Grid Engine DRMAA" .\" .\" .\" .SH NAME drmaa_run_job, drmaa_run_bulk_jobs, drmaa_get_next_job_id, drmaa_get_num_job_ids, drmaa_release_job_ids \- Job submission .PP .\" .\" .\" .SH SYNOPSIS .B #include """drmaa.h""" .PP .\" .\" .\" .nf \fBint drmaa_run_job(\fP .RS .BI "char *" job_id , .BI size_t\ job_id_len , .BI "drmaa_job_template_t *" jt , .BI "char *" error_diagnosis , .BI size_t\ error_diag_len .RE .fi \fB);\fP .PP .\" .\" .\" .nf \fBint drmaa_run_bulk_jobs(\fP .RS .BI "drmaa_job_ids_t **" jobids , .BI "drmaa_job_template_t *" jt , .BI int\ start , .BI int\ end , .BI int\ incr , .BI "char *" error_diagnosis , .BI size_t\ error_diag_len .RE .fi \fB);\fP .PP .\" .\" .nf \fBint drmaa_get_next_job_id(\fP .RS .BI "drmaa_job_ids_t *" values , .BI "char *" value , .BI int\ value_len .RE .fi \fB);\fP .PP .\" .\" .nf \fBint drmaa_get_num_job_ids(\fP .RS .BI "drmaa_job_ids_t *" values , .BI "int *" size .RE .fi \fB);\fP .PP .\" .\" .nf \fBvoid drmaa_release_job_ids(\fB .RS .BI "drmaa_job_ids_t *" values .RE .fi \fB);\fP .\" .\" .\" .SH DESCRIPTION drmaa_run_job() submits an Grid Engine job with attributes defined in the DRMAA job template \fIjt\fP. On success up to \fIjob_id_len\fP bytes of the job identifier are returned into the buffer, \fIjob_id\fP. Note the effect of the \fBSGE_DRMAA_ALLOW_JOB_ERROR_STATE\fP environment variable, as below. .\" .SS "drmaa_run_bulk_jobs()" The drmaa_run_bulk_jobs() submits a Grid Engine array job very much as if the .M qsub 1 option `\-t \fIstart\fP\-\fIend\fP:\fIincr\fP' had been used along with the additional attributes defined in the DRMAA job template, \fIjt\fP. The same constraints regarding value ranges are also in effect for the parameters \fIstart\fP, \fIend\fP, and \fIincr\fP as for .M qsub 5 \-t. On success a DRMAA job id string vector containing job identifiers for each array job task is returned into \fIjobids\fP. The job identifiers in the job id string vector can be extracted using .M drmaa_get_next_job_id 3 . The number of identifiers in the job id string vector can be determined using .M drmaa_get_num_job_ids 3 . Note that this function is only available in the 1.0 implementation. The caller is responsible for releasing the job id string vector returned into \fIjobids\fP using .M drmaa_release_job_ids 3 . .PP .\" .SS "drmaa_get_next_job_id()" Each time drmaa_get_next_job_id() is called it returns into the buffer, \fIvalue\fP, up to \fIvalue_len\fP bytes of the next entry stored in the DRMAA job id string vector, \fIvalues\fP. Once the job ids list has been exhausted, DRMAA_ERRNO_NO_MORE_ELEMENTS is returned. .PP .\" .SS "drmaa_get_num_job_ids()" The drmaa_get_num_job_ids() returns into \fIsize\fP the number of entries in the DRMAA job ids string vector. This function is only available in the 1.0 implementation. .PP .\" .SS "drmaa_release_job_ids()" The drmaa_release_attr_job_id() function releases all resources associated with the DRMAA job id string vector, \fIvalues\fP. This operation has no effect on the actual Grid Engine array job tasks. .PP .\" .\" .\" .SH "ENVIRONMENTAL VARIABLES" .\" .IP "\fBSGE_ROOT\fP" 1.5i Specifies the location of the Grid Engine standard configuration files. .\" .IP "\fBSGE_CELL\fP" 1.5i If set, specifies the default Grid Engine cell to be used. To address a Grid Engine cell Grid Engine uses (in the order of precedence): .sp 1 .RS .RS The name of the cell specified in the environment variable SGE_CELL, if it is set. .sp 1 The name of the default cell, i.e. \fBdefault\fP. .sp 1 .RE .RE .\" .IP "\fBSGE_DEBUG_LEVEL\fP" 1.5i If set, specifies that debug information should be written to stderr. In addition the level of detail in which debug information is generated is defined. .\" .IP "\fBSGE_QMASTER_PORT\fP" 1.5i If set, specifies the tcp port on which .M sge_qmaster 8 is expected to listen for communication requests. Most installations will use a services map entry instead to define that port. .\" .IP "\fBSGE_DRMAA_ALLOW_JOB_ERROR_STATE\fP" 1.5i If set, in case of job errors the job will enter the error state. By default DRMAA jobs are not allowed to enter the job error state since an error state does not exist in DRMAA, so jobs with, say, a wrong input path specification, must fail when doing drmaa_wait(). .\" .\" .SH "RETURN VALUES" Upon successful completion, drmaa_run_job(), drmaa_run_bulk_jobs(), and drmaa_get_next_job_id() return DRMAA_ERRNO_SUCCESS. Other values indicate an error. Up to \fIerror_diag_len\fP characters of error related diagnosis information is then provided in the buffer \fIerror_diagnosis\fP. .PP .\" .\" .\" .SH "ERRORS" The drmaa_run_job(), drmaa_run_bulk_jobs(), and drmaa_get_next_job_id() functions can fail with: .\" .TP .B DRMAA_ERRNO_INTERNAL_ERROR Unexpected or internal DRMAA error, like system call failure, etc. .\" .TP .B DRMAA_ERRNO_DRM_COMMUNICATION_FAILURE Could not contact DRM system for this request. .\" .TP .B DRMAA_ERRNO_AUTH_FAILURE The specified request is not processed successfully due to authorization failure. .\" .TP .B DRMAA_ERRNO_INVALID_ARGUMENT The input value for an argument is invalid. .\" .TP .B DRMAA_ERRNO_NO_ACTIVE_SESSION Failed because there is no active session. .\" .TP .B DRMAA_ERRNO_NO_MEMORY Failed allocating memory. .\" .PP The drmaa_run_job() and drmaa_run_bulk_jobs() functions can fail with: .TP .B DRMAA_ERRNO_TRY_LATER The DRM system indicated that it is too busy to accept the job. A retry may succeed, however. .\" .TP .B DRMAA_ERRNO_DENIED_BY_DRM The DRM system rejected the job. The job will never be accepted due to DRM configuration or job template settings. .\" .PP The drmaa_get_next_job_id() function can fail with: .TP .B DRMAA_ERRNO_INVALID_ATTRIBUTE_VALUE When there are no more entries in the vector. .\" .\" .\" .SH "SEE ALSO" .M drmaa_attributes 3 , .M drmaa_jobtemplate 3 .