次の方法で共有


CreateGroupReplicaFromElements method of the MSISCSITARGET_ReplicationService class

Creates or starts a job to create new storage objects, which are replicas of the specified source storage objects. This method combines the functionality of the CreateGroup and CreateGroupReplica, in one call.

This method is inherited from the CIM_ReplicationService class.

Syntax

uint32 CreateGroupReplicaFromElements(
  [in, optional]      string                     RelationshipName,
  [in]                uint16                     SyncType,
  [in, optional]      uint16                     Mode,
  [in]                CIM_LogicalElement     REF SourceElements[],
  [in, out, optional] string                     SourceGroupName,
  [in, optional]      CIM_ServiceAccessPoint REF SourceAccessPoint,
  [in, out]           CIM_ReplicationGroup   REF TargetGroup,
  [in, optional]      CIM_ServiceAccessPoint REF TargetAccessPoint,
  [in, optional]      uint16                     Consistency,
  [in, optional]      string                     ReplicationSettingData,
  [out]               CIM_ConcreteJob        REF Job,
  [out]               CIM_Synchronized       REF Synchronization,
  [in, optional]      CIM_SettingData        REF TargetSettingGoal,
  [in, optional]      CIM_ResourcePool       REF TargetPool,
  [in, optional]      uint16                     WaitForCopyState
);

Parameters

RelationshipName [in, optional]

Specifies a user relevant name for the relationship between the source and target groups or between a source element and a target group. If NULL, the implementation assigns a name. If the individual target elements require an ElementName, the implementation constructs an appropriate ElementName using the RelationshipName. For example, by using the RelationshipName as a prefix followed by "_n" sequence number, where n is a number beginning with 1.

SyncType [in]

Specifies the type of copy that will be made. Required.

The possible values are.

DMTF Reserved

*value* = 5

Mirror (6)

Snapshot (7)

Clone (8)

DMTF Reserved

9 0x7FFF

Vendor Specific

0x8000 = *value*

Mode [in, optional]

Specifies whether the target elements will be updated synchronously or asynchronously. If NULL, implementation decides the mode.

The possible values are.

Synchronous (2)

Asynchronous (3)

DMTF Reserved

4 0x7FFF

Vendor Specific

0x8000 = *value*

SourceElements [in]

Specifies a list of source storage objects which may be MSISCSITARGET_StorageVolume or other storage objects. All of the source elements shall be of the same type.

SourceGroupName [in, out, optional]

On input, specifies the name of the group to be created. If the name is not specified, the implementation may assign a group name and return it in this parameter.

SourceAccessPoint [in, optional]

Specifies source access point information. May be NULL, if the service does not need access information to access the source element.

TargetGroup [in, out]

On input, optionally specifies a target group to use. On return contains references to the created target group, the replica group. If a job is created, the target group may not be available immediately.

TargetAccessPoint [in, optional]

Specifies target access point information. May be NULL, if the service does not need access information to access the target elements.

Consistency [in, optional]

Specifies consistency for the replica. Overrides the default group consistency.

The possible values are.

No Consistency (2)

Sequential Consistency (3)

DMTF Reserved

4 0x7FFF

Vendor Specific

0x8000 = *value*

ReplicationSettingData [in, optional]

If provided, specifies the replication setting data for the given SyncType in the form of an embedded CIM_ReplicationSettingData instance. If not provided, the management server uses the default replication setting data. Optional.

Job [out]

On return contains a reference to the job, may be NULL if the job is completed.

Synchronization [out]

On return, contains a reference to the created group association between the source and the target elements. If a job is created, this parameter may be NULL until the association is instantiated.

TargetSettingGoal [in, optional]

Specifies configuration-related and operational parameters for the target storage objects, the replicas. If a TargetElement parameter is supplied, this parameter must be NULL.

TargetPool [in, optional]

Specifies the underlying storage for the target elements if specified, otherwise the allocation is implementation specific. If a TargetElement parameter is supplied, this parameter must be NULL.

WaitForCopyState [in, optional]

Specifies the CopyState that must be reached before this method returns. Only a subset of valid values apply.

For example.

  • Initialized: Associations have been established, but there is no data flow.
  • Inactive: Initialization is complete, but the data flow remains idle until it is activated.
  • Synchronized: Replicas are an exact copy of the source.
  • UnSynchronized: Copy operation is in progress.

Return value

This method returns one of the following values.

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 (0x8000 = value )

Requirements

Minimum supported client
None supported
Minimum supported server
Windows Server 2012 R2
Namespace
Root\CIMv2\Storage\iScsiTarget
MOF
SmIscsiTarget.mof
DLL
SmIScsiTargetProv.dll

See also

MSISCSITARGET_ReplicationService

MSISCSITARGET_StorageVolume