1drmaa_jobcontrol(3)            Grid Engine DRMAA           drmaa_jobcontrol(3)
2
3
4

NAME

6       drmaa_job_ps, drmaa_control, - Monitor and control jobs
7

SYNOPSIS

9       #include "drmaa.h"
10
11       int drmaa_job_ps(
12              const char *job_id,
13              int *remote_ps,
14              char *error_diagnosis,
15              size_t error_diag_len
16       );
17
18       int drmaa_control(
19              const char *jobid,
20              int action,
21              char *error_diagnosis,
22              size_t error_diag_len
23       );
24

DESCRIPTION

26       The  drmaa_job_ps()  function returns the status of the Grid Engine job
27       job_id into the integer pointed to by remote_ps. Possible return values
28       are
29
30              DRMAA_PS_UNDETERMINED        job status cannot be determined
31              DRMAA_PS_QUEUED_ACTIVE       job is queued and active
32              DRMAA_PS_SYSTEM_ON_HOLD      job is queued and in system hold
33              DRMAA_PS_USER_ON_HOLD        job is queued and in user hold
34              DRMAA_PS_USER_SYSTEM_ON_HOLD job is queued and in user and system hold
35              DRMAA_PS_RUNNING             job is running
36              DRMAA_PS_SYSTEM_SUSPENDED    job is system suspended
37              DRMAA_PS_USER_SUSPENDED      job is user suspended
38              DRMAA_PS_DONE                job finished normally
39              DRMAA_PS_FAILED              job finished, but failed
40
41       Jobs'  user  hold  and  user  suspend  states  can  be  controlled  via
42       drmaa_control(3).  For affecting system hold and system suspend  states
43       the appropriate Grid Engine interfaces must be used.
44
45   drmaa_control()
46       The  drmaa_control() function applies control operations on Grid Engine
47       jobs.   jobid  may   contain   either   an   Grid   Engine   jobid   or
48       `DRMAA_JOB_IDS_SESSION_ALL'  to  refer to all jobs submitted during the
49       DRMAA session opened using drmaa_init(3).  Legal values for action  and
50       their meanings are:
51
52              DRMAA_CONTROL_SUSPEND        suspend the job
53              DRMAA_CONTROL_RESUME         resume the job,
54              DRMAA_CONTROL_HOLD           put the job on-hold
55              DRMAA_CONTROL_RELEASE        release the hold on the job
56              DRMAA_CONTROL_TERMINATE      kill the job
57
58       The  DRMAA  suspend/resume  operations are equivalent to the use of `-s
59       <jobid>' and `-us <jobid>' options with Grid Engine qmod(1).  The DRMAA
60       hold/release  operations  are  equivalent  to  the  use  of Grid Engine
61       qhold(1) and qrls(1).  The DRMAA terminate operation is  equivalent  to
62       the use of Grid Engine qdel(1).  Only user hold and user suspend can be
63       controlled via drmaa_control(3).  For affecting system hold and  system
64       suspend states the appropriate Grid Engine interfaces must be used.
65

ENVIRONMENTAL VARIABLES

67       SGE_ROOT       Specifies  the location of the Grid Engine standard con‐
68                      figuration files.
69
70       SGE_CELL       If set, specifies the default Grid  Engine  cell  to  be
71                      used. To address a Grid Engine cell Grid Engine uses (in
72                      the order of precedence):
73
74                             The name of the cell specified in the environment
75                             variable SGE_CELL, if it is set.
76
77                             The name of the default cell, i.e. default.
78
79
80       SGE_DEBUG_LEVEL
81                      If set, specifies that debug information should be writ‐
82                      ten to stderr. In addition the level of detail in  which
83                      debug information is generated is defined.
84
85       SGE_QMASTER_PORT
86                      If  set,  specifies the tcp port on which sge_qmaster(8)
87                      is expected to listen for communication requests.   Most
88                      installations  will  use a services map entry instead to
89                      define that port.
90

RETURN VALUES

92       Upon successful completion, drmaa_job_ps(), and drmaa_control()  return
93       DRMAA_ERRNO_SUCCESS.   Other   values   indicate   an   error.   Up  to
94       error_diag_len characters of error  related  diagnosis  information  is
95       then provided in the buffer, error_diagnosis.
96

ERRORS

98       The drmaa_job_ps(), and drmaa_control() will fail if:
99
100   DRMAA_ERRNO_INTERNAL_ERROR
101       Unexpected or internal DRMAA error, like system call failure, etc.
102
103   DRMAA_ERRNO_DRM_COMMUNICATION_FAILURE
104       Could not contact DRM system for this request.
105
106   DRMAA_ERRNO_AUTH_FAILURE
107       The  specified request was not processed successfully due to authoriza‐
108       tion failure.
109
110   DRMAA_ERRNO_INVALID_ARGUMENT
111       The input value for an argument is invalid.
112
113   DRMAA_ERRNO_NO_ACTIVE_SESSION
114       Failed because there is no active session.
115
116   DRMAA_ERRNO_NO_MEMORY
117       Failed allocating memory.
118
119   DRMAA_ERRNO_INVALID_JOB
120       The specified job does not exist.
121
122       The drmaa_control() will fail if:
123
124   DRMAA_ERRNO_RESUME_INCONSISTENT_STATE
125       The job is not suspended. The resume request will not be processed.
126
127   DRMAA_ERRNO_SUSPEND_INCONSISTENT_STATE
128       The job is not running and thus cannot be suspended.
129
130   DRMAA_ERRNO_HOLD_INCONSISTENT_STATE
131       The job cannot be moved to a hold state.
132
133   DRMAA_ERRNO_RELEASE_INCONSISTENT_STATE
134       The job is not in a hold state.
135

SEE ALSO

137       drmaa_submit(3)and drmaa_wait(3).
138
139
140
141GE 6.1                   $Date: 2004/11/12 15:40:05 $      drmaa_jobcontrol(3)
Impressum