IVdsServiceUninstallDisk::GetDiskIdFromLunInfo method (vds.h)

[Beginning with Windows 8 and Windows Server 2012, the Virtual Disk Service COM interface is superseded by the Windows Storage Management API.]

Retrieves the VDS object ID for the disk that corresponds to a specified LUN.

Syntax

HRESULT GetDiskIdFromLunInfo(
  [in]  VDS_LUN_INFORMATION *pLunInfo,
  [out] VDS_OBJECT_ID       *pDiskId
);

Parameters

[in] pLunInfo

The address of a VDS_LUN_INFORMATION structure that has been initialized by a VDS hardware provider.

[out] pDiskId

The address of a VDS object ID variable passed in by the caller. This variable receives the GUID for the disk that corresponds to the LUN.

Return value

This method can return standard HRESULT values, such as E_INVALIDARG or E_OUTOFMEMORY, and VDS-specific return values. It can also return converted system error codes using the HRESULT_FROM_WIN32 macro. Errors can originate from VDS itself or from the underlying VDS provider that is being used. Possible return values include the following.

Return code/value Description
S_OK
The disk's GUID was returned successfully.
VDS_E_NO_DISK_PATHNAME
0x8004270FL
The disk's path could not be retrieved. Some operations on the disk may fail.
VDS_E_OBJECT_NOT_FOUND
0x80042405L
The disk was not found.

Remarks

VDS implements this method. This method is called by VDS applications that need to uninstall a disk whose LUN is accessed through a VDS hardware provider on another computer. This method enables the application to uninstall a disk on a computer that does not have access to a VDS hardware provider and is thus unable to make an implicit link from disk to LUN.

Requirements

Requirement Value
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2003 R2 [desktop apps only]
Target Platform Windows
Header vds.h
Library Uuid.lib

See also

IVdsServiceUninstallDisk

VDS_LUN_INFORMATION