Yandex Cloud
  • Сервисы
  • Решения
  • Почему Yandex Cloud
  • Сообщество
  • Тарифы
  • Документация
  • Связаться с нами
Подключиться
Language / Region
© 2022 ООО «Яндекс.Облако»
Yandex Compute Cloud
  • Начало работы
    • Обзор
    • Создание виртуальной машины Linux
    • Создание виртуальной машины Windows
    • Создание группы виртуальных машин
  • Пошаговые инструкции
    • Все инструкции
    • Создание виртуальной машины
      • Создать ВМ Linux
      • Создать ВМ Windows
      • Создать ВМ из набора дисков
      • Создать ВМ с дисками из снимков
      • Создать ВМ из пользовательского образа
      • Создать ВМ c GPU
      • Сделать ВМ прерываемой
    • DSVM
      • Обзор
      • Создать ВМ из публичного образа DSVM
    • Группы размещения
      • Создать группу размещения
      • Удалить группу размещения
      • Создать ВМ в группе размещения
      • Добавить ВМ в группу размещения
      • Исключить ВМ из группы размещения
    • Образы с предустановленным ПО
      • Создать ВМ из публичного образа
      • Настроить ПО
      • Работа с ВМ на базе публичного образа
      • Получить список публичных образов
    • Получение информации о виртуальной машине
      • Получить информацию о ВМ
      • Получить вывод последовательного порта
    • Управление виртуальной машиной
      • Остановить и запустить ВМ
      • Сбросить пароль пользователя ВМ
      • Подключить диск к ВМ
      • Отключить диск от ВМ
      • Перенести ВМ в другую зону доступности
      • Перенести ВМ в другой каталог
      • Привязать к ВМ публичный IP-адрес
      • Отвязать от ВМ публичный IP-адрес
      • Сделать публичный IP-адрес ВМ статическим
      • Изменить ВМ
      • Изменить вычислительные ресурсы ВМ
      • Удалить ВМ
    • Работа на виртуальной машине
      • Подключиться к ВМ по SSH
      • Подключиться к ВМ по RDP
      • Подключиться к ВМ через PowerShell
      • Работа с Yandex Cloud изнутри ВМ
      • Установить NVIDIA-драйверы
      • Восстановить доступ к ВМ
    • Управление агентом для сброса паролей
      • Проверить работу агента
      • Установить агент
      • Удалить агент
    • Создание диска
      • Создать пустой диcк
      • Создать пустой диск с блоком большого размера
      • Создать нереплицируемый диск
    • Управление диском
      • Создать снимок диска
      • Изменить диск
      • Перенести диск в другой каталог
      • Удалить диcк
      • Удалить снимок диска
    • Группы размещения дисков
      • Создать группу размещения дисков
      • Удалить диск из группы размещения
    • Создание образа
      • Подготовить образ диска
      • Загрузить свой образ
      • Создать образ из диска
      • Создать образ из снимка диска
      • Создать образ из другого пользовательского образа
    • Управление образом
      • Получить список образов
      • Удалить образ
    • Файловые хранилища
      • Создать файловое хранилище
      • Подключить файловое хранилище к ВМ
      • Отключить файловое хранилище от ВМ
      • Изменить файловое хранилище
      • Удалить файловое хранилище
    • Управление серийной консолью
      • Начало работы
      • Подключиться к серийной консоли по SSH
      • Подключиться к серийной консоли с помощью CLI
      • Запустить командную оболочку в Windows SAC
      • Отключить доступ к серийной консоли
    • Создание группы виртуальных машин
      • Создать группу ВМ фиксированного размера
      • Создать группу ВМ фиксированного размера с сетевым балансировщиком
      • Создать группу ВМ фиксированного размера с L7-балансировщиком
      • Создать автоматически масштабируемую группу ВМ
      • Создать группу ВМ с Container Optimized Image
      • Создать группу ВМ по YAML-спецификации
    • Получение информации о группе виртуальных машин
      • Получить список групп ВМ
      • Получить информацию о группе ВМ
      • Получить список ВМ в группе
    • Управление группой виртуальных машин
      • Изменить группу ВМ
      • Изменить группу ВМ по YAML-спецификации
      • Настроить проверку состояния приложения на ВМ
      • Обновить группу
        • Постепенное обновление
        • Обновление без простоя
      • Приостановить процессы в группе ВМ
      • Возобновить процессы в группе ВМ
      • Остановить группу ВМ
      • Запустить группу ВМ
      • Удалить группу ВМ
    • Выделенные хосты
      • Создать группу выделенных хостов
      • Создать ВМ в группе выделенных хостов
      • Создать ВМ на выделенном хосте
  • Yandex Container Solution
  • Практические руководства
    • Настройка синхронизации времени NTP
    • Работа с группой ВМ с автоматическим масштабированием
    • Автомасштабирование группы ВМ для обработки сообщений из очереди
    • Обновление группы ВМ под нагрузкой
    • Развертывание Remote Desktop Gateway
    • Передача логов с ВМ в Yandex Cloud Logging
    • Сборка образа ВМ с набором инфраструктурных инструментов с помощью Packer
  • Концепции
    • Взаимосвязь ресурсов
    • Виртуальные машины
      • Обзор
      • Платформы
      • Уровни производительности vCPU
      • Прерываемые виртуальные машины
      • Сеть на виртуальной машине
      • Программно-ускоренная сеть
      • Динамическая миграция
      • Группы размещения
      • Статусы
      • Метаданные
      • Сброс паролей на ВМ Windows
    • Графические ускорители
    • Диски и файловые хранилища
      • Обзор
      • Диски
      • Снимки дисков
      • Группы размещения нереплицируемых дисков
      • Файловые хранилища
      • Операции чтения и записи
    • Образы
    • Группы виртуальных машин
      • Обзор
      • Доступ
      • YAML-спецификация
      • Шаблон виртуальной машины
      • Переменные в шаблоне виртуальной машины
      • Политики
        • Обзор
        • Политика распределения
        • Политика развертывания
        • Политика масштабирования
      • Типы масштабирования
      • Автоматическое восстановление
      • Обновление
        • Обзор
        • Распределение виртуальных машин по зонам
        • Алгоритм развертывания
        • Правила обновления виртуальных машин
        • Изменение дополнительных дисков в шаблоне виртуальной машины
      • Остановка группы и приостановка процессов
      • Статусы
    • Выделенный хост
    • Резервное копирование
    • Квоты и лимиты
  • Управление доступом
  • Правила тарификации
    • Действующие правила
    • Архив
      • До 1 января 2019 года
      • С 1 января до 1 марта 2019 года
      • С 1 марта до 1 мая 2019 года
  • Справочник API
    • Аутентификация в API
    • gRPC (англ.)
      • Overview
      • DiskPlacementGroupService
      • DiskService
      • DiskTypeService
      • FilesystemService
      • HostGroupService
      • HostTypeService
      • ImageService
      • InstanceService
      • PlacementGroupService
      • SnapshotService
      • ZoneService
      • InstanceGroupService
      • OperationService
    • REST (англ.)
      • Overview
      • DiskPlacementGroup
        • Overview
        • create
        • delete
        • get
        • list
        • listDisks
        • listOperations
        • update
      • Disk
        • Overview
        • create
        • delete
        • get
        • list
        • listOperations
        • move
        • update
      • DiskType
        • Overview
        • get
        • list
      • Filesystem
        • Overview
        • create
        • delete
        • get
        • list
        • listOperations
        • update
      • HostGroup
        • Overview
        • create
        • delete
        • get
        • list
        • listHosts
        • listInstances
        • listOperations
        • update
      • HostType
        • Overview
        • get
        • list
      • Image
        • Overview
        • create
        • delete
        • get
        • getLatestByFamily
        • list
        • listOperations
        • update
      • Instance
        • Overview
        • addOneToOneNat
        • attachDisk
        • attachFilesystem
        • create
        • delete
        • detachDisk
        • detachFilesystem
        • get
        • getSerialPortOutput
        • list
        • listOperations
        • move
        • removeOneToOneNat
        • restart
        • start
        • stop
        • update
        • updateMetadata
        • updateNetworkInterface
      • PlacementGroup
        • Overview
        • create
        • delete
        • get
        • list
        • listInstances
        • listOperations
        • update
      • Snapshot
        • Overview
        • create
        • delete
        • get
        • list
        • listOperations
        • update
      • Zone
        • Overview
        • get
        • list
      • Operation
        • Overview
        • get
      • InstanceGroup
        • Overview
        • list
        • get
        • listLogRecords
        • updateFromYaml
        • updateAccessBindings
        • pauseProcesses
        • stop
        • start
        • delete
        • listInstances
        • createFromYaml
        • update
        • setAccessBindings
        • listOperations
        • create
        • listAccessBindings
        • resumeProcesses
  • Вопросы и ответы
    • Общие вопросы
    • Виртуальные машины
    • Подключение
    • Диски, снимки, образы
    • Аварийное восстановление
    • Мониторинг
    • Лицензирование
    • Все вопросы на одной странице
  1. Справочник API
  2. REST (англ.)
  3. Instance
  4. Overview

Instance

Статья создана
Yandex Cloud
  • JSON Representation
  • Methods

A set of methods for managing Instance resources.

JSON Representation

{
  "id": "string",
  "folderId": "string",
  "createdAt": "string",
  "name": "string",
  "description": "string",
  "labels": "object",
  "zoneId": "string",
  "platformId": "string",
  "resources": {
    "memory": "string",
    "cores": "string",
    "coreFraction": "string",
    "gpus": "string"
  },
  "status": "string",
  "metadata": "object",
  "bootDisk": {
    "mode": "string",
    "deviceName": "string",
    "autoDelete": true,
    "diskId": "string"
  },
  "secondaryDisks": [
    {
      "mode": "string",
      "deviceName": "string",
      "autoDelete": true,
      "diskId": "string"
    }
  ],
  "localDisks": [
    {
      "size": "string",
      "deviceName": "string"
    }
  ],
  "filesystems": [
    {
      "mode": "string",
      "deviceName": "string",
      "filesystemId": "string"
    }
  ],
  "networkInterfaces": [
    {
      "index": "string",
      "macAddress": "string",
      "subnetId": "string",
      "primaryV4Address": {
        "address": "string",
        "oneToOneNat": {
          "address": "string",
          "ipVersion": "string",
          "dnsRecords": [
            {
              "fqdn": "string",
              "dnsZoneId": "string",
              "ttl": "string",
              "ptr": true
            }
          ]
        },
        "dnsRecords": [
          {
            "fqdn": "string",
            "dnsZoneId": "string",
            "ttl": "string",
            "ptr": true
          }
        ]
      },
      "primaryV6Address": {
        "address": "string",
        "oneToOneNat": {
          "address": "string",
          "ipVersion": "string",
          "dnsRecords": [
            {
              "fqdn": "string",
              "dnsZoneId": "string",
              "ttl": "string",
              "ptr": true
            }
          ]
        },
        "dnsRecords": [
          {
            "fqdn": "string",
            "dnsZoneId": "string",
            "ttl": "string",
            "ptr": true
          }
        ]
      },
      "securityGroupIds": [
        "string"
      ]
    }
  ],
  "fqdn": "string",
  "schedulingPolicy": {
    "preemptible": true
  },
  "serviceAccountId": "string",
  "networkSettings": {
    "type": "string"
  },
  "placementPolicy": {
    "placementGroupId": "string",
    "hostAffinityRules": [
      {
        "key": "string",
        "op": "string",
        "values": [
          "string"
        ]
      }
    ]
  }
}
Field Description
id string

ID of the instance.

folderId string

ID of the folder that the instance belongs to.

createdAt string (date-time)

String in RFC3339 text format.

name string

Name of the instance. 1-63 characters long.

description string

Description of the instance. 0-256 characters long.

labels object

Resource labels as key:value pairs. Maximum of 64 per resource.

zoneId string

ID of the availability zone where the instance resides.

platformId string

ID of the hardware platform configuration for the instance.

resources object

Computing resources of the instance such as the amount of memory and number of cores.

resources.
memory
string (int64)

The amount of memory available to the instance, specified in bytes.

resources.
cores
string (int64)

The number of cores available to the instance.

resources.
coreFraction
string (int64)

Baseline level of CPU performance with the ability to burst performance above that baseline level. This field sets baseline performance for each core.

resources.
gpus
string (int64)

The number of GPUs available to the instance.

status string

Status of the instance.

  • PROVISIONING: Instance is waiting for resources to be allocated.
  • RUNNING: Instance is running normally.
  • STOPPING: Instance is being stopped.
  • STOPPED: Instance stopped.
  • STARTING: Instance is being started.
  • RESTARTING: Instance is being restarted.
  • UPDATING: Instance is being updated.
  • ERROR: Instance encountered a problem and cannot operate.
  • CRASHED: Instance crashed and will be restarted automatically.
  • DELETING: Instance is being deleted.
metadata object

The metadata key:value pairs assigned to this instance. This includes custom metadata and predefined keys.

For example, you may use the metadata in order to provide your public SSH key to the instance. For more information, see Metadata.

bootDisk object

Boot disk that is attached to the instance.

bootDisk.
mode
string

Access mode to the Disk resource.

  • READ_ONLY: Read-only access.
  • READ_WRITE: Read/Write access.
bootDisk.
deviceName
string

Serial number that is reflected into the /dev/disk/by-id/ tree of a Linux operating system running within the instance.

This value can be used to reference the device for mounting, resizing, and so on, from within the instance.

bootDisk.
autoDelete
boolean (boolean)

Specifies whether the disk will be auto-deleted when the instance is deleted.

bootDisk.
diskId
string

ID of the disk that is attached to the instance.

secondaryDisks[] object

Array of secondary disks that are attached to the instance.

secondaryDisks[].
mode
string

Access mode to the Disk resource.

  • READ_ONLY: Read-only access.
  • READ_WRITE: Read/Write access.
secondaryDisks[].
deviceName
string

Serial number that is reflected into the /dev/disk/by-id/ tree of a Linux operating system running within the instance.

This value can be used to reference the device for mounting, resizing, and so on, from within the instance.

secondaryDisks[].
autoDelete
boolean (boolean)

Specifies whether the disk will be auto-deleted when the instance is deleted.

secondaryDisks[].
diskId
string

ID of the disk that is attached to the instance.

localDisks[] object

Array of local disks that are attached to the instance.

localDisks[].
size
string (int64)

Size of the disk, specified in bytes.

localDisks[].
deviceName
string

Serial number that is reflected into the /dev/disk/by-id/ tree of a Linux operating system running within the instance.

This value can be used to reference the device for mounting, resizing, and so on, from within the instance.

filesystems[] object

Array of filesystems that are attached to the instance.

filesystems[].
mode
string

Access mode to the filesystem.

  • READ_ONLY: Read-only access.
  • READ_WRITE: Read/Write access.
filesystems[].
deviceName
string

Name of the device representing the filesystem on the instance.

The name should be used for referencing the filesystem from within the instance when it's being mounted, resized etc.

filesystems[].
filesystemId
string

ID of the filesystem that is attached to the instance.

networkInterfaces[] object

Array of network interfaces that are attached to the instance.

networkInterfaces[].
index
string

The index of the network interface, generated by the server, 0,1,2... etc. Currently only one network interface is supported per instance.

networkInterfaces[].
macAddress
string

MAC address that is assigned to the network interface.

networkInterfaces[].
subnetId
string

ID of the subnet.

networkInterfaces[].
primaryV4Address
object

Primary IPv4 address that is assigned to the instance for this network interface.

networkInterfaces[].
primaryV4Address.
address
string

An IPv4 internal network address that is assigned to the instance for this network interface.

networkInterfaces[].
primaryV4Address.
oneToOneNat
object

One-to-one NAT configuration. If missing, NAT has not been set up.

networkInterfaces[].
primaryV4Address.
oneToOneNat.
address
string

An external IP address associated with this instance.

networkInterfaces[].
primaryV4Address.
oneToOneNat.
ipVersion
string

IP version for the external IP address.

  • IPV4: IPv4 address, for example 192.0.2.235.
  • IPV6: IPv6 address. Not available yet.
networkInterfaces[].
primaryV4Address.
oneToOneNat.
dnsRecords[]
object

External DNS configuration

networkInterfaces[].
primaryV4Address.
oneToOneNat.
dnsRecords[].
fqdn
string

Name of the A/AAAA record as specified when creating the instance. Note that if `fqdn' has no trailing '.', it is specified relative to the zone (@see dns_zone_id).

networkInterfaces[].
primaryV4Address.
oneToOneNat.
dnsRecords[].
dnsZoneId
string

DNS zone id for the record (optional, if not set, some private zone is used).

networkInterfaces[].
primaryV4Address.
oneToOneNat.
dnsRecords[].
ttl
string (int64)

DNS record ttl (optional, if not set, a reasonable default is used.)

networkInterfaces[].
primaryV4Address.
oneToOneNat.
dnsRecords[].
ptr
boolean (boolean)

When true, indicates there is a corresponding auto-created PTR DNS record.

networkInterfaces[].
primaryV4Address.
dnsRecords[]
object

Internal DNS configuration

networkInterfaces[].
primaryV4Address.
dnsRecords[].
fqdn
string

Name of the A/AAAA record as specified when creating the instance. Note that if `fqdn' has no trailing '.', it is specified relative to the zone (@see dns_zone_id).

networkInterfaces[].
primaryV4Address.
dnsRecords[].
dnsZoneId
string

DNS zone id for the record (optional, if not set, some private zone is used).

networkInterfaces[].
primaryV4Address.
dnsRecords[].
ttl
string (int64)

DNS record ttl (optional, if not set, a reasonable default is used.)

networkInterfaces[].
primaryV4Address.
dnsRecords[].
ptr
boolean (boolean)

When true, indicates there is a corresponding auto-created PTR DNS record.

networkInterfaces[].
primaryV6Address
object

Primary IPv6 address that is assigned to the instance for this network interface. IPv6 not available yet.

networkInterfaces[].
primaryV6Address.
address
string

An IPv4 internal network address that is assigned to the instance for this network interface.

networkInterfaces[].
primaryV6Address.
oneToOneNat
object

One-to-one NAT configuration. If missing, NAT has not been set up.

networkInterfaces[].
primaryV6Address.
oneToOneNat.
address
string

An external IP address associated with this instance.

networkInterfaces[].
primaryV6Address.
oneToOneNat.
ipVersion
string

IP version for the external IP address.

  • IPV4: IPv4 address, for example 192.0.2.235.
  • IPV6: IPv6 address. Not available yet.
networkInterfaces[].
primaryV6Address.
oneToOneNat.
dnsRecords[]
object

External DNS configuration

networkInterfaces[].
primaryV6Address.
oneToOneNat.
dnsRecords[].
fqdn
string

Name of the A/AAAA record as specified when creating the instance. Note that if `fqdn' has no trailing '.', it is specified relative to the zone (@see dns_zone_id).

networkInterfaces[].
primaryV6Address.
oneToOneNat.
dnsRecords[].
dnsZoneId
string

DNS zone id for the record (optional, if not set, some private zone is used).

networkInterfaces[].
primaryV6Address.
oneToOneNat.
dnsRecords[].
ttl
string (int64)

DNS record ttl (optional, if not set, a reasonable default is used.)

networkInterfaces[].
primaryV6Address.
oneToOneNat.
dnsRecords[].
ptr
boolean (boolean)

When true, indicates there is a corresponding auto-created PTR DNS record.

networkInterfaces[].
primaryV6Address.
dnsRecords[]
object

Internal DNS configuration

networkInterfaces[].
primaryV6Address.
dnsRecords[].
fqdn
string

Name of the A/AAAA record as specified when creating the instance. Note that if `fqdn' has no trailing '.', it is specified relative to the zone (@see dns_zone_id).

networkInterfaces[].
primaryV6Address.
dnsRecords[].
dnsZoneId
string

DNS zone id for the record (optional, if not set, some private zone is used).

networkInterfaces[].
primaryV6Address.
dnsRecords[].
ttl
string (int64)

DNS record ttl (optional, if not set, a reasonable default is used.)

networkInterfaces[].
primaryV6Address.
dnsRecords[].
ptr
boolean (boolean)

When true, indicates there is a corresponding auto-created PTR DNS record.

networkInterfaces[].
securityGroupIds[]
string

ID's of security groups attached to the interface

fqdn string

A domain name of the instance. FQDN is defined by the server in the format <hostname>.<region_id>.internal when the instance is created. If the hostname were not specified when the instance was created, FQDN would be <id>.auto.internal.

schedulingPolicy object

Scheduling policy configuration.

schedulingPolicy.
preemptible
boolean (boolean)

True for short-lived compute instances. For more information, see Preemptible VMs.

serviceAccountId string

ID of the service account to use for authentication inside the instance. To get the service account ID, use a list request.

networkSettings object

Network Settings

networkSettings.
type
string

Network Type

  • STANDARD: Standard network.
  • SOFTWARE_ACCELERATED: Software accelerated network.
  • HARDWARE_ACCELERATED: Hardware accelerated network (not available yet, reserved for future use).
placementPolicy object

Placement policy configuration.

placementPolicy.
placementGroupId
string

Placement group ID.

placementPolicy.
hostAffinityRules[]
object

Affinitity definition

placementPolicy.
hostAffinityRules[].
key
string

Affinity label or one of reserved values - 'yc.hostId', 'yc.hostGroupId'

placementPolicy.
hostAffinityRules[].
op
string

Include or exclude action

placementPolicy.
hostAffinityRules[].
values[]
string

Affinity value or host ID or host group ID

Methods

Method Description
addOneToOneNat Enables One-to-one NAT on the network interface.
attachDisk Attaches the disk to the instance.
attachFilesystem Attaches the filesystem to the instance.
create Creates an instance in the specified folder. Method starts an asynchronous operation that can be cancelled while it is in progress.
delete Deletes the specified instance.
detachDisk Detaches the disk from the instance.
detachFilesystem Detaches the filesystem from the instance.
get Returns the specified Instance resource.
getSerialPortOutput Returns the serial port output of the specified Instance resource.
list Retrieves the list of Instance resources in the specified folder.
listOperations Lists operations for the specified instance.
move Moves the specified instance to another folder of the same cloud.
removeOneToOneNat Removes One-to-one NAT from the network interface.
restart Restarts the running instance.
start Starts the stopped instance.
stop Stops the running instance.
update Updates the specified instance.
updateMetadata Updates the metadata of the specified instance.
updateNetworkInterface Updates the specified instance network interface.

Была ли статья полезна?

Language / Region
© 2022 ООО «Яндекс.Облако»
В этой статье:
  • JSON Representation
  • Methods