Changing the volume status

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 changes the status of a volume. The volume status can be changed to blocked before a volume is shredded or returned to the normal status after shredding is stopped.

Execution permission

Storage Administrator (Provisioning)

Request line

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

Request message

Object ID
Specify the value of ldevId that was obtained by the processing to get information about volumes.

Attribute

Type

Description

ldevId

int

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

Query parameters
None.
Body
The following is a coding example for changing the volume status to blocked:
{
  "parameters": {
    "status": "blk"
  }
}

Attribute

Type

Description

status

string

(Required) Volume status

The specifiable values are as follows:

blk: Change the status to blocked

nml: Change the status to normal

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 volume whose status was changed

Action template

GET base-URL/v1/objects/ldevs/object-ID/actions/change-status

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 Quorum disk.
  • The LDEV is used as a system disk.
  • The LDEV is used as a pool volume.
  • The LDEV is used as a Volume Migration volume.
  • The LDEV is used as a pair volume of a global-active device.
  • The LDEV is used as a pair volume of ShadowImage.
  • The LDEV is used as a pair volume of TrueCopy or Universal Replicator.
  • The LDEV is used as a pair volume of Thin Image or Copy-on-Write Snapshot.

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/100/actions/change-status

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/100/actions/change-status/invoke