gpfs_get_snapname_from_fssnaphandle() subroutine
Obtains a snapshot name using its file system snapshot handle.
Library
GPFS Library (libgpfs.a for AIX®, libgpfs.so for Linux®)
Synopsis
#include <gpfs.h>
const char *gpfs_get_snapname_from_fssnaphandle(gpfs_fssnap_handle_t *fssnapHandle);
Description
The gpfs_get_snapname_from_fssnaphandle() subroutine obtains a pointer to the name of a GPFS snapshot given its file system snapshot handle. If the fssnapHandle identifies an active file system, as opposed to a snapshot of a file system, gpfs_get_snapname_from_fssnaphandle() returns a pointer to a zero-length snapshot name and a successful return code.
- libgpfs.a for AIX
- libgpfs.so for Linux
Parameters
- fssnapHandle
- File system snapshot handle.
Exit status
If the gpfs_get_snapname_from_fssnaphandle() subroutine is successful, it returns a pointer to the name of the snapshot.
If the gpfs_get_snapname_from_fssnaphandle() subroutine is unsuccessful, it returns NULL and sets the global error variable errno to indicate the nature of the error.
Exceptions
None.
Error status
Error codes include but are not limited to the following:
- ENOSYS
- The gpfs_get_snapname_from_fssnaphandle() subroutine is not available.
- EPERM
- The caller does not have superuser privileges.
- GPFS_E_INVAL_FSSNAPHANDLE
- The file system snapshot handle is not valid.
- GPFS_E_INVAL_SNAPNAME
- The snapshot has been deleted.
Location
/usr/lpp/mmfs/lib/libgpfs.a for AIX
/usr/lpp/mmfs/lib/libgpfs.so for Linux