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.

getCloudMysqlInstanceList

Prev Next

VPC 환경에서 이용 가능합니다.

Cloud DB for MySQL 인스턴스 목록을 조회합니다.

구문

getCloudMysqlInstanceList 구문은 다음과 같습니다.

./ncloud vmysql getCloudMysqlInstanceList \
    [--zoneCode <zone-code>] \
    [--vpcNo <vpc-no>] \
    [--subnetNo <subnet-no>] \
    [--cloudMysqlServiceName <service-name>] \
    [--cloudMysqlInstanceNoList <instance-no-list>] \
    [--cloudMysqlServerName <server-name>] \
    [--cloudMysqlServerInstanceNoList <server-instance-no-list>] \
    [--generationCode <G2|G3>] \
    [--pageNo <page-no>] \
    [--pageSize <page-size>] \
    [--regionCode <KR|SGN|JPN>] \
    [--output <json|xml>]

옵션

getCloudMysqlInstanceList 실행 시 지정할 수 있는 옵션을 설명합니다.

필수 옵션

getCloudMysqlInstanceList의 필수 옵션입니다.

옵션 타입 필수 여부 설명
--pageSize Integer Conditional 페이지당 항목 수
  • 1~N
  • pageNo 입력 시 필수 입력

선택 옵션

getCloudMysqlInstanceList의 선택 옵션입니다. 지정하지 않은 옵션에는 기본값이 적용됩니다.

옵션 타입 필수 여부 설명
--zoneCode String Optional 존 코드
--vpcNo String Optional VPC 번호
--subnetNo String Optional Subnet 번호
--cloudMysqlServiceName String Optional Cloud DB for MySQL 서비스 이름
--cloudMysqlInstanceNoList List Optional Cloud DB for MySQL 인스턴스 번호 목록
  • 공백으로 구분하여 여러 개 입력 가능 (예시: --cloudMysqlInstanceNoList 1234 2345)
--cloudMysqlServerName String Optional Cloud DB for MySQL 서버 이름
--cloudMysqlServerInstanceNoList List Optional Cloud DB for MySQL 서버 인스턴스 번호 목록
  • 공백으로 구분하여 여러 개 입력 가능 (예시: --cloudMysqlServerInstanceNoList 1234 2345)
--generationCode String Optional 서버 세대 코드
  • G2 | G3
--pageNo Integer Optional 페이지 번호
  • 0~N

공통 옵션

vmysql 명령에서 공통으로 사용하는 옵션에 대한 정보는 Cloud DB for MySQL (VPC) 옵션을 참조해 주십시오.

예시

Cloud DB for MySQL 인스턴스 목록 조회 요청이 성공하면 각 인스턴스의 구성 정보와 상태가 반환됩니다.

명령

명령 예시는 다음과 같습니다.

./ncloud vmysql getCloudMysqlInstanceList \
    --zoneCode KR-1 \
    --vpcNo 98765432 \
    --subnetNo 23456789 \
    --cloudMysqlServiceName test-mysql \
    --cloudMysqlInstanceNoList 12345678 \
    --cloudMysqlServerName testmysql-001-97mj \
    --cloudMysqlServerInstanceNoList 34567890 \
    --generationCode G2 \
    --pageNo 0 \
    --pageSize 10 \
    --regionCode KR \
    --output json

출력

출력 예시는 다음과 같습니다.

{
  "getCloudMysqlInstanceListResponse": {
    "totalRows": 1,
    "cloudMysqlInstanceList": [
      {
        "cloudMysqlInstanceNo": "17234567",
        "cloudMysqlServiceName": "test-mysql",
        "cloudMysqlInstanceStatusName": "running",
        "cloudMysqlInstanceStatus": {
          "code": "CREAT",
          "codeName": "CLOUD DATABASE(VPC) Created 상태"
        },
        "cloudMysqlInstanceOperation": {
          "code": "NULL",
          "codeName": "CLOUD DATABASE(VPC) Null OP"
        },
        "isHa": true,
        "isMultiZone": true,
        "generationCode": "G2",
        "cloudMysqlServerInstanceList": [
          {
            "cloudMysqlServerInstanceNo": "34567890",
            "cloudMysqlServerName": "testmysql-001-97mj",
            "cloudMysqlServerRole": {
              "code": "M",
              "codeName": "Master"
            },
            "cloudMysqlServerInstanceStatusName": "running",
            "cloudMysqlServerInstanceStatus": {
              "code": "RUN",
              "codeName": "CLOUD DATABASE(VPC) 서버 Running 상태"
            },
            "cloudMysqlServerInstanceOperation": {
              "code": "NOOP",
              "codeName": "CLOUD DATABASE(VPC) 서버 Null OP"
            },
            "regionCode": "KR",
            "zoneCode": "KR-1",
            "vpcNo": "98765432",
            "subnetNo": "23456789",
            "privateIp": "10.0.0.6",
            "dataStorageSize": 10737418240,
            "cpuCount": 2,
            "memorySize": 4294967296
          },
          {
            "cloudMysqlServerInstanceNo": "34567891",
            "cloudMysqlServerName": "testmysql-002-97mk",
            "cloudMysqlServerRole": {
              "code": "H",
              "codeName": "Standby Master"
            },
            "cloudMysqlServerInstanceStatusName": "running",
            "cloudMysqlServerInstanceStatus": {
              "code": "RUN",
              "codeName": "CLOUD DATABASE(VPC) 서버 Running 상태"
            },
            "cloudMysqlServerInstanceOperation": {
              "code": "NOOP",
              "codeName": "CLOUD DATABASE(VPC) 서버 Null OP"
            },
            "regionCode": "KR",
            "zoneCode": "KR-2",
            "vpcNo": "98765432",
            "subnetNo": "23456790",
            "privateIp": "10.0.1.6",
            "dataStorageSize": 10737418240,
            "cpuCount": 2,
            "memorySize": 4294967296
          }
        ]
      }
    ],
    "requestId": "b2c3d4e5-f6a7-8901-bcde-f23456789012",
    "returnCode": "0",
    "returnMessage": "success"
  }
}