Instances

Overview

Virtual machine instances (instances or VMs for short), virtual private cloud (VPC, private networks), images, and disks are organized in projects. These project resources are accessible only by users who are granted IAM roles in the project or its parent silo.

The permissions to create, update, or delete project resources are limited to users with the “collaborator” or “admin” role in the project. Project admin can, in addition, modify project name, description, IAM roles, and delete the project.

VM instances can be provisioned with machine images made available by the project or silo administrators and collaborators. A VM may have one or multiple private network interfaces and, optionally, external IP addresses. You can use the default VPC and subnet that come with every project or other custom VPCs/subnets you or others set up in the project.

Creating Virtual Machines

The first step of VM provisioning is making a boot disk with the desired operating system image, plus any additional blank disks to be used by the VM. When provisioning a new instance on the Oxide Console, these new disk requests are performed automatically as part of the instance creation. If you use the API to create a VM, you have the option to provision it with new or existing disks.

When creating a VM instance, the following attributes must be specified:

  • Project name

  • Instance name

  • Boot disk name (the first entry in the disks array)

  • Number of virtual CPUs (maximum: 64)

  • Memory size (in bytes; minimum 1 GiB, maximum 256 GiB)

Optional parameters include:

  • New or existing disks to attach (up to 8, including the boot disk; maximum 1023 GiB per disk)

  • Network interfaces (options: default, specific VPC subnets, or none)

  • External IP addresses (options: ephemeral IP, floating IP(s))

  • Overriding hostname

  • User data for cloud-init (e.g., data and scripts for bootstrapping, maximum 32 KiB)

  • start: whether to start the VM on create (default: true)

The following attributes are configured to system default values when they are not specified in the provisioning request:

  • Network interfaces: default, i.e., private IP assigned from the VPC and subnet named default

  • External IP: none, i.e., no inbound external IP address assigned (note: the VM will still have outbound internet access via built-in NAT)

  • Hostname: set to the VM name

In addition to the cloud-init user data, additional VM metadata such as hostname and SSH public keys are written to a CIDATA volume with base64 encoding. The VFAT volume is mounted during boot time to pass the metadata to cloud-init and is unmounted afterwards.

Using Your Instance

When an instance is started (which happens by default at create time unless start: false is specified), its state will transition to starting and then running. A running instance is ready for access if the guest and networking setup meets all the prerequisites for remote access. You can also connect to the instance through its serial console.

Note
Modifying instance or disk sizes after creation is not supported yet. Changes that can be made after creation include adding or removing disks, network interfaces, and external IP addresses. See the Instance Actions guide to learn more.

Making Boot Disks

You can create boot disks from operating system images or machine snapshots created on the Oxide rack. External cloud images in RAW format can also be uploaded to the rack via disk or image import. The data source for import must be a file accessible from your workstation file system.

Each boot disk can only be attached to one VM at a time. To allow a boot disk to become a reusable image for other workloads, you can make disk snapshots and create images from them. Oxide Console and CLI both provide a one-step process for turning an external file into a rack image, essentially combining these three actions:

  1. import external file to disk

  2. make disk snapshot

  3. create image from snapshot

Upload Image

More details about the use of images, disks and snapshots can be found in the Images, Disks and Snapshots, and Windows Instances guides.

Last updated