CreateReplica method of the CIM_StorageConfigurationService class
Start a job to create a new storage object which is a replica of the specified source storage object. (SourceElement). Note that using the input paramter, CopyType, this function can be used to instantiate the replica, and to create an ongoing association between the source and replica. If 0 is returned, the function completed successfully and no ConcreteJob instance is created. If 4096/0x1000 is returned, a ConcreteJob is started, a reference to which is returned in the Job output parameter.
Syntax
uint32 CreateReplica(
[in] string ElementName,
[out] CIM_ConcreteJob REF Job,
[in] CIM_LogicalElement REF SourceElement,
[out] CIM_LogicalElement REF TargetElement,
[in] CIM_StorageSetting REF TargetSettingGoal,
[in] CIM_StoragePool REF TargetPool,
[in] uint16 CopyType
);
Parameters
-
ElementName [in]
-
A end user relevant name for the element being created. If NULL, then a system supplied default name can be used. The value will be stored in the 'ElementName' property for the created element.
-
Job [out]
-
Reference to the job (may be null if job completed).
-
SourceElement [in]
-
The source storage object which may be a StorageVolume or storage object.
-
TargetElement [out]
-
Reference to the created target storage element (i.e., the replica).
-
TargetSettingGoal [in]
-
The definition for the StorageSetting to be maintained by the target storage object (the replica).
-
TargetPool [in]
-
The underlying storage for the target element (the replica) will be drawn from TargetPool if specified, otherwise the allocation is implementation specific.
-
CopyType [in]
-
CopyType describes the type of copy that will be made. Values are:
Async: Create and maintain an asynchronous copy of the source.
Sync: Create and maintain a synchronized copy of the source.
UnSyncAssoc: Create an unsynchronized copy and maintain an association to the source.
UnSyncUnAssoc: Create unassociated copy of the source element.
-
Async (2)
-
Sync (3)
-
UnSyncAssoc (4)
-
UnSyncUnAssoc (5)
-
DMTF Reserved
- 6 32767
-
Vendor Specific
- 32768 65535
Return value
-
Job Completed with No Error (0)
-
Not Supported (1)
-
Unknown (2)
-
Timeout (3)
-
Failed (4)
-
Invalid Parameter (5)
-
In Use (6)
-
DMTF Reserved (7 4095)
-
Method Parameters Checked - Job Started (4096)
-
Method Reserved (4097 32767)
-
Vendor Specific (32768 65535)
Requirements
Minimum supported client |
None supported |
Minimum supported server |
Windows Server 2012 R2 |
Namespace |
Root\CIMv2\Storage\iScsiTarget |
Header |
|
MOF |
|
DLL |
|