サブスクリプション ECS インスタンスのインスタンスタイプを変更します。インスタンスタイプのスペックアップまたはスペックダウンが可能です。新しいインスタンスタイプはインスタンスのライフサイクル全体にわたって有効になります。
操作説明
この操作を呼び出す前に、ECS の課金メソッド、料金、およびスペックダウンの返金ルールを十分に理解していることを確認してください。
この操作は非同期です。構成の変更は約 5〜10 秒後に有効になります。サブスクリプション ECS インスタンスのインスタンスタイプをスペックアップまたはスペックダウンする前に、 DescribeResourcesModification を呼び出して、現在のインスタンスから変更可能な ECS インスタンスタイプをクエリできます。
注意事項
-
ソースとターゲットのインスタンスタイプの NVMe プロパティが異なり( DescribeInstanceTypes が返す
NvmeSupportフィールド)、オペレーティングシステムが Windows( DescribeInstances が返すOSTypeフィールド)の場合、スペックアップ/スペックダウンを実行する前に予防措置を完了してください。 -
期限切れのインスタンスはインスタンスタイプを変更できません。更新を完了してから再試行してください。
-
インスタンスタイプのスペックダウン:
インスタンスは停止済み (
Stopped) 状態である必要があります。元のインスタンスタイプと新しいインスタンスタイプの価格差は、元の支払い方法に返金されます。使用済みのバウチャーは返金されません。支払者が返金を受け取ります。
新しいインスタンスタイプは、スペックアップ/スペックダウン後にインスタンスを起動した後にのみ有効になります。
-
インスタンスタイプのスペックアップ:
インスタンスは停止済み (
Stopped) または実行中 (Running) 状態である必要があります。新しいインスタンスタイプは、インスタンスを起動またはインスタンスを再起動した後にのみ有効になります。
今すぐお試しください
テスト
RAM 認証
|
アクション |
アクセスレベル |
リソースタイプ |
条件キー |
依存アクション |
|
ecs:ModifyPrepayInstanceSpec |
update |
*Instance
|
なし | なし |
リクエストパラメーター
|
パラメーター |
型 |
必須 / 任意 |
説明 |
例 |
| InstanceId |
string |
必須 |
インスタンス ID |
i-bp67acfmxazb4ph**** |
| RegionId |
string |
必須 |
インスタンスのリージョン ID。 DescribeRegions を呼び出して、最新のリージョンリストをクエリできます。 |
cn-hangzhou |
| InstanceType |
string |
必須 |
スペックアップ/スペックダウンのターゲットインスタンスタイプ。詳細については、インスタンスファミリーを参照するか、 DescribeInstanceTypes を呼び出してください。 |
ecs.g5.xlarge |
| OperatorType |
string |
任意 |
操作のタイプ。有効な値: 説明
このパラメーターはオプションです。システムは操作がスペックアップかスペックダウンかを自動的に判断できます。このパラメーターをアップロードする場合は、以下のルールに従ってください。
説明
インスタンスタイプのスペックアップまたはスペックダウンに関する注意事項については、上記の操作の説明セクションを参照してください。 |
upgrade |
| ClientToken |
string |
任意 |
リクエストのべき等性を確保するために使用されるクライアントトークン。クライアントを使用してトークンを生成できますが、異なるリクエスト間でトークンが一意であることを確認してください。ClientToken の値には ASCII 文字のみを含めることができ、64 文字を超えることはできません。詳細については、べき等性を確保する方法を参照してください。 |
123e4567-e89b-12d3-a456-426655440000 |
| AutoPay |
boolean |
任意 |
インスタンスタイプのスペックアップ時に自動的に支払いを完了するかどうかを指定します。有効な値:
デフォルト値: true。 説明
|
true |
| MigrateAcrossZone |
boolean |
任意 |
クラスターインスタンス間のインスタンスタイプ変更をサポートするかどうかを指定します。有効な値:
デフォルト値: false。
VPC タイプのインスタンス: 廃止されたインスタンスタイプの場合、非 I/O 最適化インスタンスを I/O 最適化インスタンスに変更すると、サーバーのディスクデバイス名とソフトウェア権限付与コードが変更されます。Linux インスタンスの場合、ベーシックディスク (cloud) は xvda または xvdb として識別されます。Ultra ディスク (cloud_efficiency) と標準 SSD (cloud_ssd) は vda または vdb として識別されます。 |
false |
| SystemDisk.Category |
string |
任意 |
新しいシステムディスクのカテゴリ。有効な値:
説明
このパラメーターは、廃止されたインスタンスタイプから標準インスタンスファミリーへのクォータの引き上げを実行し、非 I/O 最適化インスタンスを I/O 最適化インスタンスに変更する場合にのみ有効です。 |
cloud_efficiency |
| RebootTime |
string |
任意 |
インスタンスの再起動時間。ISO 8601 標準の yyyy-MM-ddTHH:mmZ 形式で時間を指定します。時間は協定世界時 (UTC) である必要があります。 |
2018-01-01T12:05Z |
| EndTime |
string |
任意 |
一時インスタンスタイプ変更の終了時間。ISO 8601 標準の yyyy-MM-ddTHH:mmZ 形式で時間を指定します。時間は協定世界時 (UTC) である必要があります。 |
2018-01-01T12:05Z |
| RebootWhenFinished |
boolean |
任意 |
インスタンスタイプの変更完了後にインスタンスを即座に再起動するかどうかを指定します。有効な値:
デフォルト値: false。 説明
インスタンスが停止済み状態の場合、 |
false |
| ModifyMode |
string |
任意 |
説明
このパラメーターは一般公開されていません。 |
null |
| Disk |
array<object> |
任意 |
説明
このパラメーターは一般公開されていません。 |
|
|
object |
任意 |
説明
このパラメーターは一般公開されていません。 |
||
| DiskId |
string |
任意 |
説明
このパラメーターは一般公開されていません。 |
null |
| Category |
string |
任意 |
説明
このパラメーターは一般公開されていません。 |
null |
| PerformanceLevel |
string |
任意 |
説明
このパラメーターは一般公開されていません。 |
null |
レスポンスフィールド
|
フィールド |
型 |
説明 |
例 |
|
object |
|||
| OrderId |
string |
注文 ID。 |
1234567890 |
| RequestId |
string |
リクエスト ID |
473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E |
例
成功レスポンス
JSONJSON
{
"OrderId": "1234567890",
"RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E"
}
エラーコード
|
HTTP ステータスコード |
エラーコード |
エラーメッセージ |
説明 |
|---|---|---|---|
| 400 | InvalidInstanceType.ValueUnauthorized | The specified InstanceType is not authorized. | |
| 400 | InvalidInstanceType.ValueNotSupported | The specified InstanceType does not exist or beyond the permitted range. | |
| 400 | InvalidBillingMethod.ValueNotSupported | The operation is not permitted due to an invalid billing method of the instance. | |
| 400 | InvalidInstance.PurchaseNotFound | The specified instance has no purchase history. | |
| 400 | InvalidInstance.UnpaidOrder | The specified instance has unpaid order. | |
| 400 | InvalidInstanceType.NotSupported | The specified InstanceType is not Supported. | |
| 400 | OrderCreationFailed | Order creation failed, please check your params and try it again later. | |
| 400 | Throttling | You have made too many requests within a short time; your request is denied due to request throttling. | |
| 400 | Account.Arrearage | Your account has an outstanding payment. | |
| 400 | InvalidInstanceId.NotFound | The specified InstanceId does not exist. | |
| 400 | InvalidRebootTime.MalFormed | The specified rebootTime is not valid. | |
| 400 | InvalidRebootTime.ValueNotSupported | The specified RebootTime is not valid. | |
| 400 | IdempotenceParamNotMatch | Request uses a client token in a previous request but is not identical to that request. | |
| 400 | InvalidInstanceChargeType.ValueNotSupported | %s | |
| 400 | InvalidStatus.NotStopped | Instance status must be stopped. | |
| 400 | InvalidAction | %s | |
| 400 | InstanceDowngrade.QuotaExceed | Quota of instance downgrade is exceed. | |
| 400 | InvalidParameter | %s | |
| 400 | OperationDenied | The current user does not support this operation. | |
| 400 | LastOrderProcessing | The previous order is still processing, please try again later. | |
| 400 | InvalidOperation.VpcHasEnabledAdvancedNetworkFeature | The specified vpc has enabled advanced network feature. | |
| 400 | InvalidAction.WithActiveElasticUpgrade | The instance has active Elastic Upgrade. | |
| 400 | InstanceTypeNotSupported.TooManyDisksAttached | %s | |
| 400 | QuotaExceed.DiskCapacity | The used capacity of disk type has exceeded the quota in the zone, %s. | |
| 400 | MissingParameter.DiskCategory | The specified parameter Disk.Category can not be null when Disk.DiskId is specified. | |
| 400 | InvalidParameter.DiskCategory | The specified parameter Disk.Category is not valid. | |
| 400 | InvalidPerformanceLevel.Malformed | The specified parameter Disk.n.PerformanceLevel is not valid. | |
| 400 | InvalidSystemDiskCategory.NotMatchInstanceType | The system disk category does not match the instance type. | |
| 400 | QuotaExceed.RufundVcpu | The maximum number of refunded vcpu is exceeded: %s . | |
| 400 | NoPermission.Price | The operation requires price permission. Please either apply for permission from your main account, or set the parameter AutoPay as true. | |
| 400 | NoPermission.Refund | The operation requires refund permission. Please apply for permission from your main account. | |
| 400 | InvalidInstanceStatus | The current status of the instance does not support this operation. | |
| 400 | InvalidOperation.InstanceRenewWithDowngradeInPlan | The operation is denied due to the specified instance has renew with downgrade record in plan. | |
| 400 | InvalidOperation.OnlineModificationUnsupported | Online modification of instance type is not supported for the specified instance due to its CPU topology. | |
| 400 | InvalidInstanceType.NotSupportCpuOptionsNestedVirtualization | The specified instance type does not support CpuOptions.NestedVirtualization: %s. | |
| 401 | InvalidInstanceType.ValueUnauthorized | The specified InstanceType is not authorized. | |
| 500 | InternalError | The request processing has failed due to some unknown error, exception or failure. | |
| 500 | ImageOrderFailed | Create marketplace image order failed. | |
| 403 | OperationDenied.NoStock | The specified instance is out of usage. | |
| 403 | InvalidInstanceType.ValueNotSupported | The specified InstanceType does not exist or beyond the permitted range. | |
| 403 | InvalidUser.PassRoleForbidden | The RAM user does not have privilege to pass a role. | |
| 403 | ImageNotSupportInstanceType | The specified image does not support the specified InstanceType. | |
| 403 | InstanceType.Offline | %s | |
| 403 | IncorrectInstanceStatus | The current status of the resource does not support this operation. | |
| 403 | Throttling | You have made too many requests within a short time; your request is denied due to request throttling. | |
| 403 | InvalidParameter.InstanceId | %s | |
| 403 | OperationDenied | %s | |
| 403 | InvalidInstanceStatus | The current status of the instance does not support this operation. | |
| 403 | InvalidOperation.StarterPackage | StarterPackage not support modification. | |
| 403 | InvalidInstance.PreInstanceExpired | Instance business status is not Expired. | |
| 403 | InvalidInstance.EipNotSupport | The special instance with eip not support operate, please unassociate eip first. | |
| 403 | OperationDenied.ImageNotValid | The specified image is not authorized. | |
| 403 | OperationDenied.LocalDiskUnsupported | The configuration change is not allowed when the specified instance has local disks mounted. | |
| 403 | InvalidOperation.EniCountExceeded | %s | |
| 403 | InvalidOperation.Ipv4CountExceeded | %s | |
| 403 | InvalidOperation.Ipv6CountExceeded | %s | |
| 403 | InvalidOperation.Ipv6NotSupport | %s | |
| 403 | InvalidOperation.Ipv4NotSupport | %s | |
| 403 | InvalidInstance.NotFoundSystemDisk | The specified instance has no system disk. | |
| 403 | InvalidInstanceType.NotSupportDiskCategory | The instanceType of the specified instance does not support this disk category. | |
| 403 | QuotaExceed.ElasticQuota | No additional quota is available for the specified ECS instance type. | |
| 403 | InvalidResourceType.NotSupported | %s | |
| 403 | InvalidOperation.MaxEniQueueNumberExceeded | %s | |
| 403 | InvalidOperation.ExceedInstanceTypeQueueNumber | %s | |
| 403 | InvalidParameter.InvalidEniQueueNumber | %s | |
| 403 | HibernationConfigured.InstanceOperationForbidden | The operation is not permitted due to limit of the hibernation configured instance. | |
| 403 | InvalidOperation.MaxModifyOnlineNumberExceeded | The specified instance has reached the maximum number of modify online attempts and needs to be rebooted. | |
| 403 | InvalidOperation.RebootingRequired | The specified instance needs to be rebooted. | |
| 403 | InvalidOperation.OSTypeNotSupported | The specified OS type is not supported. | |
| 403 | OperationDenied.UnpaidOrder | The specified instance has unpaid order. | |
| 403 | InvalidDisk.DetachedSystemDisk | The specified resource is/has a detached system disk %s , not support current operation. | |
| 403 | InvalidDataDiskCategory.ValueNotSupported | The specified Category of Data Disk is not valid. | |
| 403 | InvalidDiskCategory.NotSupported | The upgrade operation of instance does not support this category of disk. | |
| 404 | InvalidRegionId.NotFound | The specified RegionId does not exist. | |
| 404 | BillingMethodNotFound | The account has not chosen any billing method. | |
| 404 | InvalidInstanceId.NotFound | The specified InstanceId does not exist. | |
| 503 | LimitedOperation.ServiceUnavailable | The service is currently unavailable. Please try again later. |
完全なリストについては、「エラーコード」をご参照ください。
変更履歴
完全なリストについては、「変更履歴」をご参照ください。