Allocating or Releasing an fGPU

You can allocate a flexible GPU (fGPU) to your account, and release it at any time.

Allocating an fGPU enables you to attach it to a virtual machine (VM). For more information, see Attaching or Detaching an fGPU.

Allocating or Releasing an fGPU Using Cockpit v2

Allocating an fGPU

  1. In the Flexible GPUs dashboard, click IconAddFull Allocate Flexible GPU.
    The ALLOCATE FLEXIBLE GPU dialog box appears.

  2. In the Flexible GPU model list, select the model of fGPU you want to allocate.

  3. In the Subregion list, select the Subregion for the fGPU.

  4. Check or uncheck the Release fGPU on VM deletion box:

    • If the box is checked, the fGPU is automatically released from your account when the VM it is linked to is terminated.

    • If the box is unchecked, the fGPU is unlinked and stays allocated to your account when the VM it is linked to is terminated.

  5. Click Allocate.
    The fGPU is allocated to your account.

Releasing an fGPU

  1. Click inside the Flexible GPUs dashboard to make checkboxes appear.

  2. Check the box of the fGPU you want to release from your account.
    The fGPU is selected and an action menu appears.

  3. Click IconTerminate Release.
    A confirmation dialog box appears.

  4. Click Release.
    The fGPU is released from your account.

Allocating or Releasing an fGPU Using OSC CLI

Allocating an fGPU

The CreateFlexibleGpu command allocates a flexible GPU (fGPU) to your account.
You can then attach this fGPU to a virtual machine (VM).

For more information, see About Flexible GPUs.

Request sample
$ osc-cli api CreateFlexibleGpu --profile "default" \
    --ModelName "nvidia-p100" \
    --Generation "v5" \
    --SubregionName "eu-west-2a" \
    --DeleteOnVmDeletion True

This command contains the following attributes that you need to specify:

  • DeleteOnVmDeletion: (optional) If true, the fGPU is deleted when the VM is terminated.

  • DryRun: (optional) If true, checks whether you have the required permissions to perform the action.

  • Generation: (optional) The processor generation that the fGPU must be compatible with. If not specified, the oldest possible processor generation is selected (as provided by ReadFlexibleGpuCatalog for the specified model of fGPU).

  • ModelName: The model of fGPU you want to allocate. For more information, see About Flexible GPUs.

  • SubregionName: The Subregion in which you want to create the fGPU.

The CreateFlexibleGpu command returns the following elements:

  • FlexibleGpu: Information about the flexible GPU (fGPU).

  • ResponseContext: Information about the context of the response.

Result sample
{
  "ResponseContext": {
    "RequestId": "0475ca1e-d0c5-441d-712a-da55a4175157"
  },
  "FlexibleGpu": {
    "SubregionName": "eu-west-2a",
    "DeleteOnVmDeletion": true,
    "Generation": "v5",
    "ModelName": "nvidia-p100",
    "State": "allocated",
    "FlexibleGpuId": "fgpu-12345678"
  }
}

Releasing an fGPU

The DeleteFlexibleGpu command releases a flexible GPU (fGPU) from your account.
The fGPU becomes free to be used by someone else.

Request sample
$ osc-cli api DeleteFlexibleGpu --profile "default" \
    --FlexibleGpuId "fgpu-12345678"

This command contains the following attributes that you need to specify:

  • DryRun: (optional) If true, checks whether you have the required permissions to perform the action.

  • FlexibleGpuId: The ID of the fGPU you want to delete.

The DeleteFlexibleGpu command returns the following elements:

  • ResponseContext: Information about the context of the response.

Result sample
{
  "ResponseContext": {
    "RequestId": "0475ca1e-d0c5-441d-712a-da55a4175157"
  }
}

Related Pages

Corresponding API Methods