IVssHardwareSnapshotProvider::GetTargetLuns method (vsprov.h)
The GetTargetLuns method prompts the hardware provider to initialize the VDS_LUN_INFORMATION structures for the newly created shadow copy LUNs. The GetTargetLuns method is called after the IVssProviderCreateSnapshotSet::PostCommitSnapshots method. Identifying information for each newly created LUN is returned to VSS through VDS_LUN_INFORMATION structures.
Syntax
HRESULT GetTargetLuns(
[in] LONG lLunCount,
[in] VSS_PWSZ *rgDeviceNames,
[in] VDS_LUN_INFORMATION *rgSourceLuns,
[in, out] VDS_LUN_INFORMATION *rgDestinationLuns
);
Parameters
[in] lLunCount
Count of LUNs that contribute to the original volume.
[in] rgDeviceNames
Pointer to an array of lLunCount pointers to strings. Each string contains the name of an original LUN to be shadow copied.
[in] rgSourceLuns
Pointer to an array of lLunCountVDS_LUN_INFORMATION structures, one for each LUN that contributes to the original volume.
[in, out] rgDestinationLuns
Pointer to an array of lLunCountVDS_LUN_INFORMATION structures, one for each new shadow copy LUN created during shadow copy processing. There should be a one-to-one correspondence between the elements of the rgSourceLuns and rgDestinationLuns arrays.
Return value
This method can return one of these values.
Return code/value | Description |
---|---|
|
The operation was successfully completed. |
|
Out of memory or other system resources. |
|
One of the parameter values is not valid. |
|
An unexpected provider error occurred. The provider must report an event in the application event log providing the user with information on how to resolve the problem. |
Remarks
In the rgDestinationLuns parameter, VSS supplies an empty VDS_LUN_INFORMATION structure for each newly created shadow copy LUN. The shadow copy LUNs are not surfaced or visible to the system. The provider should initialize the members of the VDS_LUN_INFORMATION structure with the appropriate SCSI Inquiry Data and Vital Product Data page 80 (device serial number) and page 83 (device identity) information. The structure should contain correct member values such that the shadow copy LUNs can be located by Windows from the original computer or any other computer connected to the SAN.
The members of the VDS_LUN_INFORMATION structure correspond to the page 80 information, with the following exceptions:
- The m_version member must be set to VER_VDS_LUN_INFORMATION.
- The m_BusType member is ignored in comparisons during import. This value depends on the PnP storage stack on the corresponding disk device. Usually this is VDSBusTypeScsi.
- The m_diskSignature member is ignored in comparisons during import. The provider must set this member to GUID_NULL.
The VDS_LUN_INFORMATION structures returned here must be the same as the structures provided in the IVssHardwareSnapshotProvider::FillInLunInfo method during import so that VSS can use this information to identify the newly arriving shadow copy LUNs at import. These same structures will be passed to the provider in the IVssHardwareSnapshotProvider::LocateLuns method.
Requirements
Requirement | Value |
---|---|
Minimum supported client | None supported |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Target Platform | Windows |
Header | vsprov.h |