pbs_connect (3) - Linux Manuals
pbs_connect: connect to a pbs batch server
NAME
pbs_connect - connect to a pbs batch server
SYNOPSIS
#include <pbs_error.h>#include <pbs_ifl.h>
int pbs_connect(char *server) extern char *pbs_server;
DESCRIPTION
A virtual stream (TCP/IP) connection is established with the server specified byThis function must be called before any of the other pbs_ functions. They will transmit their batch requests over the connection established by this function. Multiple requests may be issued over the connection before it is closed.
The connection should be closed by a call to pbs_disconnect() when all requests have been sent to the server.
The parameter, is of the form see section 2.7.9. If is not specified, the standard PBS port number will be used.
If the parameter,
is either the null string or a null pointer,
a connection will be opened to the default server.
The default server is defined
by (a) the setting of the environment
variable
PBS_DEFAULT
which contains a destination, or (b) the destination in the batch administrator
established file
The variable
declared in pbs_ifl.h,
is set on return to point to the server
name to which pbs_connect() connected or attempted to connect.
DIAGNOSTICS
When the connection to batch server has been successfully created, the routine will return a connection identifier which is positive. Otherwise, a negative value is returned. The error number is set in pbs_errno.