CreateOrModifyElementFromElements method of the MSISCSITARGET_StorageConfigurationService class
Creates or modifies a specified storage element by using specified CIM_StorageExtent instances. You can use the MSISCSITARGET_StoragePool.GetAvailableExtents method to get a list of valid extent instances.
This method is inherited from the CIM_StorageConfigurationService class.
Syntax
uint32 CreateOrModifyElementFromElements(
[in] string ElementName,
[in] uint16 ElementType,
[out] CIM_ConcreteJob Ref Job,
[in] CIM_ManagedElement Ref Goal,
[in, out] uint64 Size,
[in] CIM_StorageExtent Ref InElements[],
[in, out] CIM_LogicalElement Ref TheElement
);
Parameters
-
ElementName [in]
-
Specifies an end-user relevant name for the element that is being created. This value is propagated to the ElementName property of the created element.
If NULL, a system-supplied default name is used. If not NULL, when modifying an existing element, this value replaces the ElementName of the existing element.
-
ElementType [in]
-
Specifies the type of element to be created or modified.
The element returned in the TheElement parameter must be of the type that is specified here or a subtype of it.
Required.
The possible values are.
-
Unknown (0)
-
Reserved (1)
-
Storage Volume (2)
-
Storage Extent (3)
-
Storage Pool (4)
-
Logical Disk (5)
-
DMTF Reserved
- 6 0x7FFF
-
Vendor Specific
- 0x8000 0xFFFF
Job [out]
On return, contains a reference to the job, if a job is created and not completed.
Goal [in]
Specifies the characteristics, qualities of service, and goals for the element to maintain. If NULL, the default configuration from the source pool is used.
If not NULL, when an existing element is modified, specifies a new goal for the modified element.
Size [in, out]
On input, specifies the wanted size in bytes. If NULL, the size is the maximum size that can be created from the extent instances that are specified in the InElements parameter.
If not NULL, when an existing element is modified, specifies a new size.
On output, indicates the actual size of the resulting element.
If the requested size cannot be created, no action is performed.
InElements [in]
Specifies the storage element instances that are used to create or modify the resulting element.
If the size of the individual extent instances that are specified is less than the requested Size parameter, then the space is drawn from the extent instances in the order that is specified.
Required.
TheElement [in, out]
On input, optionally specifies an element to modify. If an existing element is specified, it must match the ElementType parameter. It must be an instance of the same class or a subclass of it.
If NULL, this method creates a new element.
On output, contains a reference to the resulting element, which can be a vendor-specific subclass of the type that is specified in the ElementType parameter.
Return value
This method returns one of the following values.
-
Job Completed with No Error (0)
-
Not Supported (1)
-
Unspecified Error (2)
-
Timeout (3)
-
Failed (4)
-
Invalid Parameter (5)
-
In Use (6)
-
DMTF Reserved (7 0x0FFF)
-
Method Parameters Checked - Job Started (0x1000)
-
Method Reserved (0x1001 0x7FFF)
-
Vendor Specific (0x8000 0xFFFF)
Requirements
Minimum supported client |
None supported |
Minimum supported server |
Windows Server 2012 R2 |
Namespace |
Root\CIMv2\Storage\iScsiTarget |
MOF |
|
DLL |
|