drmaa_submit(3)
π drmaa_submit(3) β Grid Engine DRMAA π
okay bestie, welcome to the DRMAA job-submission page from the Grid Engine DRMAA manual (that's the manual name, iykyk, section 3 ofc) π
this one's all about yeeting jobs at the cluster. sit down, hydrate, let's go β¨
πΈ NAME πΈ
drmaa_run_job, drmaa_run_bulk_jobs, drmaa_get_next_job_id, drmaa_get_num_job_ids, drmaa_release_job_ids β Job submission π
β¨ SYNOPSIS β¨
#include "drmaa.h"
int drmaa_run_job(
char *job_id,
size_t job_id_len,
drmaa_job_template_t *jt,
char *error_diagnosis,
size_t error_diag_len
);
int drmaa_run_bulk_jobs(
drmaa_job_ids_t **jobids,
drmaa_job_template_t *jt,
int start,
int end,
int incr,
char *error_diagnosis,
size_t error_diag_len
);
int drmaa_get_next_job_id(
drmaa_job_ids_t *values,
char *value,
int value_len
);
int drmaa_get_num_job_ids(
drmaa_job_ids_t *values,
int *size
);
void drmaa_release_job_ids(
drmaa_job_ids_t *values
);
π¦ DESCRIPTION π¦
drmaa_run_job() submits an Grid Engine job with all the attributes defined in the DRMAA job template jt. When it works (and we love when it works π), up to job_id_len bytes of the job identifier get dropped into the buffer, job_id. Also, pls note the effect of the SGE_DRMAA_ALLOW_JOB_ERROR_STATE environment variable, which we get into below π
π drmaa_run_bulk_jobs()
drmaa_run_bulk_jobs() submits a Grid Engine array job, pretty much exactly like if you'd used the qsub(1) option `-t start-end:incr' alongside all the extra attributes defined in the DRMAA job template, jt. The same constraints regarding value ranges are also in effect for the parameters start, end, and incr as for qsub(5) -t. On success, a DRMAA job id string vector containing job identifiers for each array job task gets returned into jobids. The job identifiers inside that job id string vector can be extracted using drmaa_get_next_job_id(3). The number of identifiers in the job id string vector can be determined using drmaa_get_num_job_ids(3). Heads up though: this function is only available in the 1.0 implementation π And the caller is responsible for releasing the job id string vector returned into jobids using drmaa_release_job_ids(3) β so like, clean up after yourself, bestie π§Ή
π«Ά drmaa_get_next_job_id()
Every single time drmaa_get_next_job_id() is called, it returns into the buffer, value, up to value_len bytes of the next entry stored in the DRMAA job id string vector, values. And once the job ids list has been exhausted? It hits you with DRMAA_ERRNO_NO_MORE_ELEMENTS. that's it, that's the whole list, no more crumbs π
π drmaa_get_num_job_ids()
drmaa_get_num_job_ids() returns into size the number of entries in the DRMAA job ids string vector. This function is only available in the 1.0 implementation, periodt β¨
π drmaa_release_job_ids()
The drmaa_release_attr_job_id() function releases all resources associated with the DRMAA job id string vector, values. Bestie, this operation has no effect on the actual Grid Engine array job tasks β it's just cleanup of the local vector, the jobs themselves are untouched, ok? π
π ENVIRONMENTAL VARIABLES π
SGE_ROOTβ Specifies the location of the Grid Engine standard configuration files.SGE_CELLβ 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):- The name of the cell specified in the environment variable
SGE_CELL, if it is set. - The name of the default cell, i.e.
default.
- The name of the cell specified in the environment variable
SGE_DEBUG_LEVELβ If set, specifies that debug information should be written tostderr. In addition the level of detail in which debug information is generated is defined.SGE_QMASTER_PORTβ If set, specifies the tcp port on whichsge_qmaster(8)is expected to listen for communication requests. Most installations will use a services map entry instead to define that port.SGE_DRMAA_ALLOW_JOB_ERROR_STATEβ 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 doingdrmaa_wait().
π 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 error_diag_len characters of error related diagnosis information is then provided in the buffer error_diagnosis.
π ERRORS π
The drmaa_run_job(), drmaa_run_bulk_jobs(), and drmaa_get_next_job_id() functions can fail with:
DRMAA_ERRNO_INTERNAL_ERRORβ Unexpected or internal DRMAA error, like system call failure, etc.DRMAA_ERRNO_DRM_COMMUNICATION_FAILUREβ Could not contact DRM system for this request.DRMAA_ERRNO_AUTH_FAILUREβ The specified request is not processed successfully due to authorization failure.DRMAA_ERRNO_INVALID_ARGUMENTβ The input value for an argument is invalid.DRMAA_ERRNO_NO_ACTIVE_SESSIONβ Failed because there is no active session.DRMAA_ERRNO_NO_MEMORYβ Failed allocating memory.
The drmaa_run_job() and drmaa_run_bulk_jobs() functions can fail with:
DRMAA_ERRNO_TRY_LATERβ The DRM system indicated that it is too busy to accept the job. A retry may succeed, however.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.
The drmaa_get_next_job_id() function can fail with:
DRMAA_ERRNO_INVALID_ATTRIBUTE_VALUEβ When there are no more entries in the vector.
π SEE ALSO π
drmaa_attributes(3), drmaa_jobtemplate(3).
and that's the whole page, bestie π«Ά go forth and submit responsibly, no cap. mwah π
SGE 8.1.3pre Β· 2008-07-08 Β· drmaa_submit(3) β yeah it's giving vintage but she's still iconic, periodt ππΈ
π¦ where this page comes from
- debian bookworm: gridengine-drmaa-dev 8.1.9+dfsg-10+b1 Β· SISSL
- debian trixie: gridengine-drmaa-dev 8.1.9+dfsg-13.1 Β· SISSL
- ubuntu jammy: gridengine-drmaa-dev 8.1.9+dfsg-10build1 Β· SISSL
- ubuntu noble: gridengine-drmaa-dev 8.1.9+dfsg-11build3 Β· SISSL
- ubuntu questing: gridengine-drmaa-dev 8.1.9+dfsg-13.1
- ubuntu resolute: gridengine-drmaa-dev 8.1.9+dfsg-13.2 Β· SISSL
- ubuntu stonking: gridengine-drmaa-dev 8.1.9+dfsg-13.2ubuntu1 Β· SISSL
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms