VPC環境で利用できます。
概要
サーバインスタンス(VM)リストを照会します。
リクエスト
リクエストパラメータ
パラメータ名 | 必須の有無 | タイプ | 制限事項 | 説明 |
---|---|---|---|---|
regionCode | No | String | - リージョンコード サーバインスタンスリスト照会対象のリージョン(Region) regionCodeはgetRegionListアクションを通じて取得可能 デフォルト: getRegionList照会結果の最初のリージョンを選択 |
|
vpcNo | No | String | - VPC番号 VPC番号で絞り込んで検索可能 vpcNoはgetVpcListアクションを通じて取得可能 |
|
serverInstanceNoList | No | List<String> | - サーバインスタンス番号リスト サーバインスタンス番号で絞り込んで検索可能 serverInstanceNoはgetServerInstanceListアクションを通じて取得可能 例: --serverInstanceNoList 1234 2345 |
|
serverName | No | String | - サーバ名 サーバ名で絞り込んで検索可能 |
|
serverInstanceStatusCode | No | String | - サーバインスタンスの状態コード サーバインスタンスの状態コードで絞り込んで検索可能 オプション: INIT | CREAT | RUN | NSTOP |
|
baseBlockStorageDiskTypeCode | No | String | - 基本ブロックストレージディスクタイプコード サーバインスタンスの基本ブロックストレージタイプで絞り込んで検索可能 オプション: NET (NETWORK DISK) |
|
baseBlockStorageDiskDetailTypeCode | No | String | - 基本ブロックストレージディスクの詳細タイプコード サーバインスタンスの基本ブロックストレージの詳細タイプで絞り込んで検索可能 オプション: HDD | SSD |
|
ip | No | String | - IPアドレス サーバインスタンスの IPアドレスで絞り込んで検索可能 プライベート IPアドレスとグローバル IPアドレスのいずれも絞り込み対象 |
|
placementGroupNoList | No | List<String> | - 物理配置グループ番号リスト サーバインスタンスが属する物理配置グループ番号で絞り込んで検索可能 placementGroupNoはgetPlacementGroupListアクションを通じて取得可能 例: --placementGroupNoList 1234 2345 |
|
hypervisorTypeCodeList | No | List<String> | - ハイパーバイザタイプコードリスト ハイパーバイザタイプで絞り込んで検索可能 オプション: XEN | KVM 例: --hypervisorTypeCodeList KVM XEN |
|
pageNo | No | Integer | - ページングされた結果のページ番号 結果値を pageNo、pageSizeを利用してページング処理可能 |
|
pageSize | Conditional | Integer | - ページング時に表示する各ページサイズ 結果値を pageNo、pageSizeを利用してページング処理可能 pageNo入力時、必ず入力 |
|
sortedBy | No | String | - ソート対象 結果値をサーバ名、サーバインスタンス番号でソート可能 オプション: serverName | serverInstanceNo |
|
sortingOrder | No | String | - ソート順序 sortedBy利用時の昇順または降順のソートを設定 オプション: ASC(昇順) | DESC(降順) デフォルト: ASC |
|
responseFormatType | No | String | - レスポンス結果の形式タイプ オプション: xml | json デフォルト: xml |
レスポンス
レスポンスデータタイプ
- ServerInstanceListタイプ
ServerInstanceList extends CommonResponse |
---|
private Integer totalRows; |
private List<ServerInstance> serverInstanceList = new ArrayList<>(); |
ServerInstance |
---|
private String serverInstanceNo; |
private String serverName; |
private String serverDescription; |
private Integer cpuCount; |
private Long memorySize; |
private CommonCode platformType; |
private String loginKeyName; |
private String publicIpInstanceNo; |
private String publicIp; |
private CommonCode serverInstanceStatus; |
private CommonCode serverInstanceOperation; |
private String serverInstanceStatusName; |
private Date createDate; |
private Date uptime; |
private String serverImageProductCode; |
private String serverProductCode; |
private Boolean isProtectServerTermination; |
private String zoneCode; |
private String regionCode; |
private String vpcNo; |
private String subnetNo; |
private NetworkInterfaceNoList networkInterfaceNoList; |
private String initScriptNo; |
private CommonCode serverInstanceType; |
private CommonCode baseBlockStorageDiskType; |
private CommonCode baseBlockStorageDiskDetailType; |
private String placementGroupNo; |
private String placementGroupName; |
private String memberServerImageInstanceNo; |
private List<BlockDevicePartition> blockDevicePartitionList; |
private CommonCode hypervisorType; |
private String serverImageNo; |
private String serverSpecCode; |
private List<String> eventList; |
例
リクエスト例
ncloud vserver getServerInstanceList --regionCode KR --vpcNo ***04 --serverInstanceNoList ***4299 --serverName test-*** --serverInstanceStatusCode RUN --baseBlockStorageDiskTypeCode NET --baseBlockStorageDiskDetailTypeCode SSD --ip ***.***.111.215 --placementGroupNoList ***61
レスポンス例
<getServerInstanceListResponse>
<returnCode>0</returnCode>
<returnMessage>success</returnMessage>
<totalRows>1</totalRows>
<serverInstanceList>
<serverInstance>
<serverInstanceNo>***4299</serverInstanceNo>
<serverName>test-***</serverName>
<serverDescription></serverDescription>
<cpuCount>2</cpuCount>
<memorySize>4294967296</memorySize>
<platformType>
<code>LNX64</code>
<codeName>Linux 64 Bit</codeName>
</platformType>
<loginKeyName>test-***</loginKeyName>
<publicIpInstanceNo>***7551</publicIpInstanceNo>
<publicIp>***.***.111.215</publicIp>
<serverInstanceStatus>
<code>RUN</code>
<codeName>Server run state</codeName>
</serverInstanceStatus>
<serverInstanceOperation>
<code>NULL</code>
<codeName>Server NULL OP</codeName>
</serverInstanceOperation>
<serverInstanceStatusName>running</serverInstanceStatusName>
<createDate>2020-08-19T15:05:07+0900</createDate>
<uptime>2020-08-19T15:08:09+0900</uptime>
<serverImageProductCode>SW.VSVR.OS.LNX64.CNTOS.0703.B050</serverImageProductCode>
<serverProductCode>SVR.VSVR.STAND.C002.M004.NET.SSD.B050.G001</serverProductCode>
<isProtectServerTermination>false</isProtectServerTermination>
<zoneCode>KR-1</zoneCode>
<regionCode>KR</regionCode>
<vpcNo>***04</vpcNo>
<subnetNo>***43</subnetNo>
<networkInterfaceNoList>
<networkInterfaceNo>***87</networkInterfaceNo>
</networkInterfaceNoList>
<initScriptNo></initScriptNo>
<serverInstanceType>
<code>STAND</code>
<codeName>Standard</codeName>
</serverInstanceType>
<baseBlockStorageDiskType>
<code>NET</code>
<codeName>Network Storage</codeName>
</baseBlockStorageDiskType>
<baseBlockStorageDiskDetailType>
<code>SSD</code>
<codeName>SSD</codeName>
</baseBlockStorageDiskDetailType>
<placementGroupNo>***61</placementGroupNo>
<placementGroupName>test-***</placementGroupName>
<hypervisorType>
<code>KVM</code>
<codeName>KVM</codeName>
</hypervisorType>
<serverImageNo>61</serverImageNo>
<serverSpecCode>mi2-g3i</serverSpecCode>
<eventList>
<string>Scheduled Maintenance Event | 2025-03-19 PM 10:11 (UTC+09:00) migration</string>
</eventList>
</serverInstance>
</serverInstanceList>
</getServerInstanceListResponse>