pbs_modify_resv(3B)

NAME
pbs_modify_resv - modify a PBS reservation

SYNOPSIS
#include <pbs_error.h>
#include <pbs_ifl.h>

char *pbs_modify_resv(int server_connect, char *resv_id, struct attropl *attrib, char *extend)

DESCRIPTION
Issue a batch request to modify a reservation.

A Modify Reservation batch request is generated and sent to the server. The parameter server_connect is the socket on which we connect to the server. The parameter resv_id is the reservation ID.

The parameter attrib is a list of attributes to be changed. Each attribute is an attropl structure which is defined in pbs_ifl.h as:

    struct attrl {
        char   *name;
        char   *resource;
        char   *value;
        struct attrl *next;
        enum batch_op op;
    };

The attrib list is terminated by the first entry where next is a null pointer.

The name member points to a string which is the name of the attribute. The value member points to a string which is the value of the attribute. The attribute names are defined in pbs_ifl.h.

If an attribute is not named in the attrib array, the default action is taken. It is either assigned the default value or is not passed with the reservation. The action depends on the attribute. If attrib itself is a null pointer, then the default action is taken for each attribute.

An attribute of type ATTR_l (the letter ell) has a resource name indicated by resource in the attrl structure. All other attribute types should have a pointer to a null string for resource.

The op member is forced to a value of SET by pbs_modify_resv().

The parameter, extend, is reserved for implementation-defined extensions.

The return value is a character string which is the reservation identifier assigned to the job by the server. The space for the reservation identifier string is allocated by pbs_modify_resv() and should be released via a call to free() by the user when no longer needed.

SEE ALSO
pbs_rsub(1B) and pbs_connect(3B)

DIAGNOSTICS
When the batch request generated by pbs_modify_resv() function has been completed successfully by a batch server, the routine will return a pointer to a character string which is the reservation identifier of the modified reservation. Otherwise, a null pointer is returned and the error code is set in pbs_error.