dsmQuerySessInfo

The dsmQuerySessInfo function call starts a query request to IBM® Storage Protect for information related to the operation of the specified session in dsmHandle. A structure of type ApiSessInfo is passed in the call, with all available session related information entered. This call is started after a successful dsmInitEx call.

The information that is returned in the ApiSessInfo structure includes the following:

  • Server information: port number, date and time, and type
  • Client defaults: application type, delete permissions, delimiters, and transaction limits
  • Session information: login ID, and owner
  • Policy data: domain, active policy set, and retention grace period

See API type definitions source files for information about the content of the structure that is passed and each field within it.

Syntax

dsInt16_t dsmQuerySessInfo  (dsUint32_t         dsmHandle,
   ApiSessInfo   *SessInfoP);

Parameters

dsUint32_t dsmHandle (I)
The handle that associates this call with a previous dsmInitEx call.
ApiSessInfo *SessInfoP (I/O)
This parameter passes the address of the structure that the API enters. The application client is responsible for allocating storage for the structure and for completing the field entries that indicate the version of the structure that is used. On successful return, the fields in the structure are completed with the appropriate information. The adsmServerName is the name that is given in the define server command on the IBM Storage Protect server. If the archiveRetentionProtection field is true, the server is enabled for retention protection.

Return codes

The return code numbers are provided in parentheses ( ).

Table 1. Return codes for dsmQuerySessInfo
Return code Explanation
DSM_RC_NO_SESS_BLK (2006) No server session block information.
DSM_RC_NO_POLICY_BLK (2007) No server policy information available.
DSM_RC_WRONG_VERSION_PARM (2065) Application client's API version is different from the IBM Storage Protect library version.