1pbs_statserver(3B) PBS pbs_statserver(3B)
2
3
4
6 pbs_statserver - obtain status of a pbs batch server
7
9 #include <pbs_error.h>
10 #include <pbs_ifl.h>
11
12 struct batch_status *pbs_statserver(int/ connect, struct/ attrl/ *attrib,
13 char/ *extend)
14
15 void pbs_statfree(struct batch_status *psj)
16
18 Issue a batch request to obtain the status of a batch server.
19
20 A Status Server batch request is generated and sent to the server over
21 the connection specified by connect which is the return value of
22 pbs_connect().
23
24 The parameter, attrib, is a pointer to an attrl structure which is
25 defined in pbs_ifl.h as:
26
27 struct attrl {
28 struct attrl *next;
29 char *name;
30 char *resource;
31 char *value;
32 };
33
34 The attrib list is terminated by the first entry where next is a null
35 pointer. If attrib is given, then only the attributes in the list are
36 returned by the server. Otherwise, all the attributes of the server
37 are returned. When an attrib list is specified, the name member is a
38 pointer to a attribute name as listed in pbs_alter(3) and pbs_sub‐
39 mit(3). The resource member is only used if the name member is ATTR_l,
40 otherwise it should be a pointer to a null string. The value member
41 should aways be a pointer to a null string.
42
43 The parameter, extend, is reserved for implementation defined exten‐
44 sions.
45
46 The return value is a pointer to a list of batch_status structures,
47 which is defined in pbs_ifl.h as:
48
49 struct batch_status {
50 struct batch_status *next;
51 char *name;
52 struct attrl *attribs;
53 char *text;
54 }
55
56 It is up the user to free the space when no longer needed, by calling
57 pbs_statfree().
58
60 qstat(1B) and pbs_connect(3B)
61
63 When the batch request generated by pbs_statserver() function has been
64 completed successfully by a batch server, the routine will return a
65 pointer to a batch_status structure. Otherwise, a null pointer is
66 returned and the error code is set in pbs_errno.
67
68
69
70
71Local pbs_statserver(3B)