~ubuntu-branches/ubuntu/utopic/gridengine/utopic

« back to all changes in this revision

Viewing changes to doc/htmlman/htmlman3/drmaa_init.html

  • Committer: Bazaar Package Importer
  • Author(s): Mark Hymers
  • Date: 2008-06-25 22:36:13 UTC
  • Revision ID: james.westby@ubuntu.com-20080625223613-tvd9xlhuoct9kyhm
Tags: upstream-6.2~beta2
ImportĀ upstreamĀ versionĀ 6.2~beta2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<HTML>
 
2
<BODY BGCOLOR=white>
 
3
<PRE>
 
4
<!-- Manpage converted by man2html 3.0.1 -->
 
5
NAME
 
6
     drmaa_init, drmaa_exit - Start/finish Grid Engine DRMAA ses-
 
7
     sion
 
8
 
 
9
SYNOPSIS
 
10
     #include "drmaa.h"
 
11
 
 
12
     int drmaa_init(
 
13
          const char *contact,
 
14
          char *error_diagnosis,
 
15
          size_t error_diag_len
 
16
     );
 
17
 
 
18
     int drmaa_exit(
 
19
          char *error_diagnosis,
 
20
          size_t error_diag_len
 
21
     );
 
22
 
 
23
DESCRIPTION
 
24
  drmaa_init()
 
25
     The drmaa_init() function initializes the Grid Engine  DRMAA
 
26
     API library for all threads of the process and creates a new
 
27
     DRMAA session. This routine must be called once  before  any
 
28
     other    DRMAA    call,    except    for   <B><A HREF="../htmlman3/drmaa_version.html">drmaa_version(3)</A></B>,
 
29
     <B><A HREF="../htmlman3/drmaa_get_DRM_system.html">drmaa_get_DRM_system(3)</A></B>,                                 and
 
30
     <B><A HREF="../htmlman3/drmaa_get_DRMAA_implementation.html">drmaa_get_DRMAA_implementation(3)</A></B>.   Except  for  the  above
 
31
     listed functions, no DRMAA functions may  be  called  before
 
32
     the  drmaa_init()  function  <I>completes</I>.   Any DRMAA function
 
33
     which is called before the drmaa_init()  function  completes
 
34
     will  return a DRMAA_ERRNO_NO_ACTIVE_SESSION error.  <I>Contact</I>
 
35
     is an implementation dependent string which may be  used  to
 
36
     specify  which  Grid Engine cell to use. If <I>contact</I> is NULL,
 
37
     the default Grid Engine cell will be used. In the 1.0 imple-
 
38
     mentation    <I>contact</I>   may   have   the   following   value:
 
39
     <I>session</I>=&lt;<I>session</I>_<I>id</I>&gt;.   To  determine  the  session_id,  the
 
40
     <B><A HREF="../htmlman3/drmaa_get_contact.html">drmaa_get_contact(3)</A></B>  function  should  be  called after the
 
41
     session  has  already  been  initialized.   By  passing  the
 
42
     <I>session</I>=&lt;<I>session</I>_<I>id</I>&gt;  string  to  the drmaa_init() function,
 
43
     instead of creating a new session,  DRMAA  will  attempt  to
 
44
     reconnect  to  the session indicated by the <I>session</I>_<I>id</I>.  The
 
45
     result of reconnecting to a previous  session  is  that  all
 
46
     jobs  previously  submitted  in  that session that are still
 
47
     running will be available in the DRMAA session.  Note,  how-
 
48
     ever,  that jobs which ended before the call to drmaa_init()
 
49
     may not be available or may have no associated exit informa-
 
50
     tion or resource usage data.
 
51
 
 
52
     In the 0.95 implementation, setting <I>contact</I> has no effect.
 
53
 
 
54
  drmaa_exit()
 
55
     The drmaa_exit() function closes the DRMAA session  for  all
 
56
     threads  and must be called before process termination.  The
 
57
     drmaa_exit() function may be called only once  by  a  single
 
58
     thread  in  the  process  and  may  only be called after the
 
59
     drmaa_init() function has completed.   Any  DRMAA  function,
 
60
     other   than   <B><A HREF="../htmlman3/drmaa_init.html">drmaa_init(3)</A></B>,  which  is  called  after  the
 
61
     drmaa_exit()    function    completes    will    return    a
 
62
     DRMAA_ERRNO_NO_ACTIVE_SESSION error.
 
63
 
 
64
     The drmaa_exit() function does necessary  clean  up  of  the
 
65
     DRMAA  session state, including unregistering from the <I>qmas-</I>
 
66
     <B><A HREF="../htmlman8/ter.html">ter(8)</A></B>.  If the drmaa_exit() function  is  not  called,  the
 
67
     qmaster  will  store  events  for the DRMAA client until the
 
68
     connection times out, causing extra work for the qmaster and
 
69
     consuming system resources.
 
70
 
 
71
     Submitted jobs are not affected by  the  drmaa_exit()  func-
 
72
     tion.
 
73
 
 
74
ENVIRONMENTAL VARIABLES
 
75
     SGE_ROOT       Specifies the location  of  the  Grid  Engine
 
76
                    standard configuration files.
 
77
 
 
78
     SGE_CELL       If set, specifies  the  default  Grid  Engine
 
79
                    cell  to  be  used.  To address a Grid Engine
 
80
                    cell Grid Engine uses (in the order  of  pre-
 
81
                    cedence):
 
82
 
 
83
                         The name of the cell  specified  in  the
 
84
                         environment  variable SGE_CELL, if it is
 
85
                         set.
 
86
 
 
87
                         The  name  of  the  default  cell,  i.e.
 
88
                         default.
 
89
 
 
90
 
 
91
     SGE_DEBUG_LEVEL
 
92
                    If  set,  specifies  that  debug  information
 
93
                    should  be written to stderr. In addition the
 
94
                    level of detail in which debug information is
 
95
                    generated is defined.
 
96
 
 
97
     SGE_QMASTER_PORT
 
98
                    If set, specifies the tcp port on  which  the
 
99
                    sge_qmaster is expected to listen for commun-
 
100
                    ication requests.   Most  installations  will
 
101
                    use  a  services  map entry instead to define
 
102
                    that port.
 
103
 
 
104
RETURN VALUES
 
105
     Upon successful completion,  drmaa_init()  and  drmaa_exit()
 
106
     return DRMAA_ERRNO_SUCCESS.  Other values indicate an error.
 
107
     Up to <I>error</I>_<I>diag</I>_<I>len</I> characters of error  related  diagnosis
 
108
     information is then provided in the buffer <I>error</I>_<I>diagnosis</I>.
 
109
 
 
110
ERRORS
 
111
     The drmaa_init() and drmaa_exit() functions will fail if:
 
112
 
 
113
  DRMAA_ERRNO_INTERNAL_ERROR
 
114
     Unexpected  or  internal  DRMAA  error,  like  system   call
 
115
     failure, etc.
 
116
 
 
117
  DRMAA_ERRNO_DRM_COMMUNICATION_FAILURE
 
118
     Could not contact DRM system for this request.
 
119
 
 
120
  DRMAA_ERRNO_AUTH_FAILURE
 
121
     The specified request is not processed successfully  due  to
 
122
     authorization failure.
 
123
 
 
124
  DRMAA_ERRNO_INVALID_ARGUMENT
 
125
     The input value for an argument is invalid.
 
126
 
 
127
     The drmaa_init() will fail if:
 
128
 
 
129
  DRMAA_ERRNO_INVALID_CONTACT_STRING
 
130
     Initialization failed due to invalid contact string.
 
131
 
 
132
  DRMAA_ERRNO_DEFAULT_CONTACT_STRING_ERROR
 
133
     Could not use the default contact string to connect  to  DRM
 
134
     system.
 
135
 
 
136
  DRMAA_ERRNO_DRMS_INIT_FAILED
 
137
     Initialization failed due to failure to init DRM system.
 
138
 
 
139
  DRMAA_ERRNO_ALREADY_ACTIVE_SESSION
 
140
     Initialization failed due to existing DRMAA session.
 
141
 
 
142
  DRMAA_ERRNO_NO_MEMORY
 
143
     Failed allocating memory.
 
144
 
 
145
     The drmaa_exit() will fail if:
 
146
 
 
147
  DRMAA_ERRNO_NO_ACTIVE_SESSION
 
148
     Failed because there is no active session.
 
149
 
 
150
  DRMAA_ERRNO_DRMS_EXIT_ERROR
 
151
     DRM system disengagement failed.
 
152
 
 
153
SEE ALSO
 
154
     <B><A HREF="../htmlman3/drmaa_submit.html">drmaa_submit(3)</A></B>.
 
155
 
 
156
 
 
157
 
 
158
 
 
159
 
 
160
 
 
161
 
 
162
</PRE>
 
163
<HR>
 
164
<ADDRESS>
 
165
Man(1) output converted with
 
166
<a href="http://www.oac.uci.edu/indiv/ehood/man2html.html">man2html</a>
 
167
</ADDRESS>
 
168
</BODY>
 
169
</HTML>