cc [ flag... ] file... –lMPAPI [ library... ] #include <mpapi.h> #include <mpapi-sun.h>
The functions in this library allow a management application to administer the multipath devices and associated resources through standard interfaces, independent of a vendor-unique multipathing solution.
The shared object libMPAPI.so.1 provides the public interfaces defined below. See Intro(3) for additional information on shared object interfaces.
Client applications link with the Common Library (using –lMPAPI) to access the interfaces. The Common Library dynamically loads an individual vendor-provided plugin library that is available through MP_RegisterPlugin(3MPAPI) on the host system.
Using libMPAPI involves the following steps:
Optionally calling MP_GetLibraryProperties() to retrieve the properties of the Common Library.
Calling MP_GetPluginOidList() to retrieve the registered plugin libraries.
Optionally calling MP_GetPluginProperties() to retrieve the properties of the plugin library.
Retrieve discovery information and property information on multipath devices and associated resources by calling the following:
Register and deregister for property and visibility changes on multipath devices and associated resources by calling:
Perform administrative operations on multipath devices and associated resources by calling:
Errors are generally returned from the underlying VSL and can include any of the following values:
This status value is returned when the requested operation is successfully carried out.
This status value is returned when parameters passed to an API are detected to be invalid or inappropriate for a particular API parameter. If the parameter is an object ID, this status indicates that the object type subfield is defined in this specification, but is not appropriate for this API
This status value is returned when a client function passed into the API is not a previously registered or known function.
This status value is returned when the requested operation could not be carried out.
This status value is returned when the API could [not] allocate the memory required to complete the requested operation.
This status value is returned when an object ID includes a type subfield that is not defined in this specification.
This status value is returned when the object associated with the ID specified in the API could not be located, or has been deleted. Note that an invalid object type is covered by MP_STATUS_INVALID_OBJECT_TYPE so this status is limited to an invalid object owner identifier or sequence number.
This status value is returned when the implementation does not support the requested function.
This status value is returned when a client function passed into the API replaces a previously registered function.
This status value is returned when a device processing MP_SetTPGAccess returns a status indicating that the caller is attempting to establish an illegal combination of access states.
This status is returned when communication cannot be established with the path selected by the caller.
This status is returned when the plugin or driver is unable to complete the request, but might be able to complete it later.
The operation is not permitted in the current configuration, but might be permitted in other configurations.
64–bit shared object
See attributes(5) for descriptions of the following attributes:
Multipath Management API Version 1.0