• Native OpenStack API

noa
  1. Help Center
  2. Native OpenStack API
  3. API Reference
  4. OpenStack Cinder API v3
  5. EVS Disk Actions
  6. Expanding the Capacity of an EVS Disk

Expanding the Capacity of an EVS Disk

Function

This API is used to expand the capacity of an EVS disk.

  • If the status of the to-be-expanded disk is available, there are no restrictions.
  • If the status of the to-be-expanded disk is in-use, the restrictions are as follows:
    • The shared disk cannot be expanded, that is, the value of parameter multiattach must be false.
    • The status of the server to which the disk attached must be ACTIVE, PAUSED, SUSPENDED, or SHUTOFF.

URI

  • URI format

    POST /v3/{project_id}/volumes/{volume_id}/action

  • Parameter description

    Parameter

    Mandatory

    Description

    project_id

    Yes

    Specifies the project ID.

    volume_id

    Yes

    Specifies the ID of the EVS disk.

Request

  • Parameter description

    Parameter

    Type

    Mandatory

    Description

    os-extend

    map<string, string>

    Yes

    Specifies the disk expansion marker. For details, see Parameter in the os-extend field.

  • Parameter in the os-extend field

    Parameter

    Type

    Mandatory

    Description

    new_size

    int

    Yes

    Specifies the disk capacity after expansion. The disk capacity after expansion must be greater than that before expansion.

  • Example request
    {
        "os-extend": {
            "new_size": 100
        }
    }

Response

  • Parameter description

    Parameter

    Type

    Description

    error

    string

    Specifies the error message returned when an error occurs. For details, see Parameters in the error field.

  • Parameters in the error field

    Parameter

    Type

    Description

    message

    string

    Specifies the error message returned when an error occurs.

    code

    string

    Specifies the error code returned when an error occurs.

    For details about the error code, see Error Codes.

  • Example response

    None

    or

    {
        "error": {
            "message": "XXXX", 
            "code": "XXX"
        }
    }

    In the preceding example, error indicates a general error, for example, badRequest or itemNotFound. An example is provided as follows:

    {
        "badRequest": {
            "message": "XXXX", 
            "code": "XXX"
        }
    }

Returned Values

  • Normal

    202

Error Codes

For details, see Error Codes.