Formatting a volume

REST API Reference Guide for Virtual Storage Platform 5000, Virtual Storage Platform E Series, and Virtual Storage Platform G/F Series

Version
93-07-0x
90-09-0x
88-08-10
Audience
anonymous
Part Number
MK-98RD9014-17
The following request formats an LDEV (basic volume) or DP volume.

Execution permission

Storage Administrator (Provisioning)

Request line

POST base-URL/v1/objects/ldevs/object-ID/actions/format/invoke

Request message

Object ID
Specify the ldevId value obtained by getting information about volumes.

Attribute

Type

Description

ldevId

int

(Required) Specify the LDEV number with a decimal (base 10) number.

Query parameters
None.
Body
{
  "parameters": {
    "operationType": "FMT"
  }
}

Attribute

Type

Description

operationType

string

(Required) Format type.

The specifiable types are as follows:

FMT: Normal formatting

QFMT: Quick formatting

For a DP volume for which the capacity saving function (dedupe and compression) is enabled, you must specify FMT.

Response message

Body

A job object is returned. For details on attributes other than affectedResources, see the section explaining job objects.

Attribute

Description

affectedResources

URL of the formatted volume

Action template

GET base-URL/v1/objects/ldevs/object-ID/actions/format

Status codes

The following table describes the meaning of the status code of the request for this operation. For details on other status codes, see the description on HTTP status codes.

Status code

Message

Description

412

Precondition Failed

The specified action cannot run because the volume meets one of the following conditions:

  • The LDEV is used as a virtual volume of Thin Image.
  • The LDEV is used as a Quorum disk.
  • The LDEV is used as a system disk.
  • The LDEV is used as a pool volume.

Coding example

To get an action template:

curl -v -H "Accept:application/json" -H "Content-Type:application/json" -H "Authorization:Session d7b673af189048468c5af9bcf3bbbb6f" -X GET https://192.0.2.100/ConfigurationManager/v1/objects/ldevs/1/actions/format

To run the request after getting an action template:

curl -v -H "Accept:application/json" -H "Content-Type:application/json" -H "Authorization:Session d7b673af189048468c5af9bcf3bbbb6f" -X POST --data-binary @./InputParameters.json https://192.0.2.100/ConfigurationManager/v1/objects/ldevs/1/actions/format/invoke

When forcibly formatting the DP volume for which the capacity saving function (dedupe and compression) is enabled:

Note:

The formatting of deduplicated data might take some time. Be sure to take this into account when planning when to format such data. In addition, use the status of the target resource rather than the status of the job to check whether the data has been formatted.

When format the DP volume for which the capacity saving function (compression or deduplication) is enabled, in the request body, specify FMT for the operationType attribute, and true for the isDataReductionForceFormat attribute.

The following coding example forcibly formats the DP volume for which the capacity saving function (compression or deduplication) is enabled:

{
  "parameters": {
    "operationType": "FMT",
    "isDataReductionForceFormat": true
  }
}

Attribute

Type

Description

isDataReductionForceFormat

boolean

(Optional) Specify whether to forcibly format the DP volume for which the capacity saving function (compression or deduplication) is enabled.

  • true: Format forcibly
  • false: Do not format forcibly

When the attribute is omitted, false is assumed.