1
0
forked from docs/doc-exports
doc-exports/docs/ecs/api-ref/en-us_topic_0020212653.html
Artem Goncharov 3196b64bfc
move doc sources to other location (#3)
move doc sources to other location

Reviewed-by: OpenTelekomCloud Bot <None>
2022-04-27 16:24:25 +00:00

8.9 KiB

Modifying the Specifications of an ECS

Function

ECS specifications can be modified, for example, upgrading the vCPUs and memory, to meet service requirements. This API is used to modify ECS specifications.

An ECS flavor cannot be changed to certain flavors. For details, see Querying the Target Flavors to Which an ECS Flavor Can Be Changed.

Constraints

  • You can modify the ECS specifications only when the ECS is stopped.

URI

POST /v1/{project_id}/cloudservers/{server_id}/resize

Table 1 describes the parameters in the URI.
Table 1 Parameter description

Parameter

Mandatory

Description

project_id

Yes

Specifies the project ID.

server_id

Yes

Specifies the ECS ID.

Request

Table 2 describes the request parameters.
Table 2 Request parameters

Parameter

Mandatory

Type

Description

resize

Yes

Object

Specifies the operation to modify ECS specifications. For details, see Table 3.

Table 3 resize field description

Parameter

Mandatory

Type

Description

flavorRef

Yes

String

Specifies the flavor ID of the ECS after the modification.

Response

See Responses (Task).

Example Request

POST https://{endpoint}/v1/{project_id}/cloudservers/{server_id}/resize
{
"resize": {
        "flavorRef": "c3.15xlarge.2"
    }
}

Example Response

None

Error Codes

See Error Codes.