Documentation Index

Fetch the complete documentation index at: https://cli.ncloud-docs.com/llms.txt

Use this file to discover all available pages before exploring further.

changeServerInstanceSpec

Prev Next

VPC環境で利用できます。

停止状態のサーバインスタンス(VM)のスペックを変更します。

構文

changeServerInstanceSpec構文は次の通りです。

./ncloud vserver changeServerInstanceSpec \
    --serverInstanceNo <server-instance-no> \
    --serverSpecCode <server-spec-code> | --serverProductCode <server-product-code> \
    [--regionCode <KR|SGN|JPN>] \
    [--output <json|xml>]

オプション

changeServerInstanceSpecの実行時に指定できるオプションについて説明します。

必須オプション

changeServerInstanceSpecの必須オプションです。

オプション タイプ 必須の有無 説明
--serverInstanceNo String Required サーバインスタンス番号
--serverSpecCode String Conditional サーバスペックコード (KVM、RHV、XEN)
  • 同じ商品タイプ(productType)やディスクの詳細タイプ(diskDetailType[HDD, SSD])内でのみ変更可能
  • serverProductCodeと同時に使用不可
  • getServerSpecListを参照
--serverProductCode String Conditional サーバ商品コード (RHV、XEN)
  • 同じ商品タイプ(productType)やディスクの詳細タイプ(diskDetailType[HDD, SSD])内でのみ変更可能
  • serverSpecCodeと同時に使用不可
  • getServerProductListを参照

共通オプション

vserverコマンドで共通して使用するオプションについては、Server (VPC)のオプションをご参照ください。

サーバスペックの変更リクエストが成功すると、サーバの最新情報が返されます。

コマンド

コマンドの例は次の通りです。

./ncloud vserver changeServerInstanceSpec \
    --serverInstanceNo 34567890 \
    --serverProductCode SVR.VSVR.HICPU.C004.M008.NET.SSD.B050.G002 \
    --regionCode KR \
    --output json

出力

出力の例は次の通りです。

{
  "changeServerInstanceSpecResponse": {
    "totalRows": 1,
    "serverInstanceList": [
      {
        "serverInstanceNo": "34567890",
        "serverName": "test-server-renamed-01",
        "cpuCount": 2,
        "memorySize": 4294967296,
        "platformType": {
          "code": "LNX64",
          "codeName": "Linux 64 Bit"
        },
        "loginKeyName": "test-server-instance-key-01",
        "serverInstanceStatus": {
          "code": "NSTOP",
          "codeName": "サーバ NORMAL STOPPED状態"
        },
        "serverInstanceOperation": {
          "code": "CHNG",
          "codeName": "サーバ SPEC CHANGE OP"
        },
        "serverInstanceStatusName": "changingSpec",
        "createDate": "2026-05-14T17:29:35+0900",
        "uptime": "2026-05-14T17:40:21+0900",
        "serverImageProductCode": "SW.VSVR.OS.LNX64.ROCKY.0810.B050",
        "serverProductCode": "SVR.VSVR.HICPU.C002.M004.NET.SSD.B050.G002",
        "isProtectServerTermination": false,
        "zoneCode": "KR-1",
        "regionCode": "KR",
        "vpcNo": "12345678",
        "subnetNo": "23456789",
        "networkInterfaceNoList": [
          "56789012"
        ],
        "serverInstanceType": {
          "code": "HICPU",
          "codeName": "High-CPU"
        },
        "baseBlockStorageDiskType": {
          "code": "NET",
          "codeName": "ネットワークストレージ"
        },
        "baseBlockStorageDiskDetailType": {
          "code": "SSD",
          "codeName": "SSD"
        },
        "hypervisorType": {
          "code": "XEN",
          "codeName": "XEN"
        },
        "serverImageNo": "45678901",
        "serverSpecCode": "c2-g2-s50",
        "eventList": [],
        "isPreInstallGpuDriver": false
      }
    ],
    "requestId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "returnCode": "0",
    "returnMessage": "success"
  }
}