shapes
Creates, updates, deletes, gets or lists a shapes resource.
Overview​
| Name | shapes |
| Type | Resource |
| Id | oci.compute.shapes |
Fields​
The following fields are returned by SELECT queries:
- list
A compute instance shape that can be used in [LaunchInstance](#/en/iaas/latest/Instance/LaunchInstance).<br />For more information, see [Overview of the Compute Service](/iaas/Content/Compute/Concepts/computeoverview.htm) and<br />[Compute Shapes](/iaas/Content/Compute/References/computeshapes.htm).<br />
| Name | Datatype | Description |
|---|---|---|
availabilityDomain | string | The shape's availability domain. |
baselineOcpuUtilizations | array | For a subcore burstable VM, the supported baseline OCPU utilization for instances that use this shape. |
billingType | string | How instances that use this shape are charged. (ALWAYS_FREE, LIMITED_FREE, PAID) |
gpuDescription | string | A short description of the graphics processing unit (GPU) available for this shape. If the shape does not have any GPUs, this field is null. |
gpus | integer | The number of GPUs available for this shape. |
isBilledForStoppedInstance | boolean | Whether billing continues when the instances that use this shape are in the stopped state. |
isFlexible | boolean | Whether the shape supports creating flexible instances. A [flexible shape](/iaas/Content/Compute/References/computeshapes.htm#flexible) is a shape that lets you customize the number of OCPUs and the amount of memory when launching or resizing your instance. |
isLiveMigrationSupported | boolean | Whether live migration is supported for this shape. |
isSubcore | boolean | Whether the shape supports creating subcore or burstable instances. A [burstable instance](/iaas/Content/Compute/References/burstable-instances.htm) is a virtual machine (VM) instance that provides a baseline level of CPU performance with the ability to burst to a higher level to support occasional spikes in usage. |
localDiskDescription | string | A short description of the local disks available for this shape. If the shape does not have any local disks, this field is null. |
localDisks | integer | The number of local disks available for this shape. |
localDisksTotalSizeInGBs | number (float) | The aggregate size of the local disks available for this shape, in gigabytes. If the shape does not have any local disks, this field is null. |
maxVnicAttachmentOptions | object | For a flexible shape, the number of VNIC attachments that are available for instances that use this shape. If this field is null, then this shape has a fixed maximum number of VNIC attachments equal to maxVnicAttachments. |
maxVnicAttachments | integer | The maximum number of VNIC attachments available for this shape. |
memoryInGBs | number (float) | The default amount of memory available for this shape, in gigabytes. |
memoryOptions | object | For a flexible shape, the amount of memory available for instances that use this shape. If this field is null, then this shape has a fixed amount of memory equivalent to memoryInGBs. |
minTotalBaselineOcpusRequired | number (int32) | For a subcore burstable VM, the minimum total baseline OCPUs required. The total baseline OCPUs is equal to baselineOcpuUtilization chosen multiplied by the number of OCPUs chosen. |
networkPorts | integer | The number of physical network interface card (NIC) ports available for this shape. |
networkingBandwidthInGbps | number (float) | The networking bandwidth available for this shape, in gigabits per second. |
networkingBandwidthOptions | object | For a flexible shape, the amount of networking bandwidth available for instances that use this shape. If this field is null, then this shape has a fixed amount of bandwidth equivalent to networkingBandwidthInGbps. |
ocpuOptions | object | For a flexible shape, the number of OCPUs available for instances that use this shape. If this field is null, then this shape has a fixed number of OCPUs equal to ocpus. |
ocpus | number (float) | The default number of OCPUs available for this shape. |
platformConfigOptions | object | The list of supported platform configuration options for this shape. |
platformNames | array | The list of platform names that can be used for this shapes |
processorDescription | string | A short description of the shape's processor (CPU). |
quotaNames | array | The list of of compartment quotas for the shape. |
rdmaBandwidthInGbps | integer | The networking bandwidth available for the remote direct memory access (RDMA) network for this shape, in gigabits per second. |
rdmaPorts | integer | The number of networking ports available for the remote direct memory access (RDMA) network between nodes in a high performance computing (HPC) cluster network. If the shape does not support cluster networks, this value is 0. |
recommendedAlternatives | array | The list of shapes and shape details (if applicable) that Oracle recommends that you use as an alternative to the current shape. |
resizeCompatibleShapes | array | The list of compatible shapes that this shape can be changed to. For more information, see [Changing the Shape of an Instance](/iaas/Content/Compute/Tasks/resizinginstances.htm). |
shape | string | The name of the shape. You can enumerate all available shapes by calling [ListShapes](#/en/iaas/latest/Shape/ListShapes). |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list | select | compartmentId, region | availabilityDomain, limit, page, imageId, shape | Lists the shapes that can be used to launch an instance within the specified compartment. You can<br />filter the list by compatibility with a specific image.<br /> |
remove_image_shape_compatibility_entry | exec | imageId, shapeName, region | Removes a shape from the compatible shapes list for the image. | |
add_image_shape_compatibility_entry | exec | imageId, shapeName, region | Adds a shape to the compatible shapes list for the image. |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
compartmentId | string | The [OCID](/iaas/Content/General/Concepts/identifiers.htm) of the compartment. |
imageId | string | The [OCID](/iaas/Content/General/Concepts/identifiers.htm) of the image. |
region | string | OCI region identifier (e.g. us-ashburn-1, ap-sydney-1); resolves from OCI_REGION when not supplied in the query. (default: us-ashburn-1, x-stackQL-envVar: OCI_REGION) |
shapeName | string | Shape name. |
availabilityDomain | string | The name of the availability domain. Example: Uocm:PHX-AD-1 |
imageId | string | The [OCID](/iaas/Content/General/Concepts/identifiers.htm) of an image. |
limit | integer | For list pagination. The maximum number of results per page, or items to return in a paginated "List" call. For important details about how pagination works, see [List Pagination](/iaas/Content/API/Concepts/usingapi.htm#nine). Example: 50 |
page | string | For list pagination. The value of the opc-next-page response header from the previous "List" call. For important details about how pagination works, see [List Pagination](/iaas/Content/API/Concepts/usingapi.htm#nine). |
shape | string | Shape name. |
SELECT examples​
- list
Lists the shapes that can be used to launch an instance within the specified compartment. You can<br />filter the list by compatibility with a specific image.<br />
SELECT
availabilityDomain,
baselineOcpuUtilizations,
billingType,
gpuDescription,
gpus,
isBilledForStoppedInstance,
isFlexible,
isLiveMigrationSupported,
isSubcore,
localDiskDescription,
localDisks,
localDisksTotalSizeInGBs,
maxVnicAttachmentOptions,
maxVnicAttachments,
memoryInGBs,
memoryOptions,
minTotalBaselineOcpusRequired,
networkPorts,
networkingBandwidthInGbps,
networkingBandwidthOptions,
ocpuOptions,
ocpus,
platformConfigOptions,
platformNames,
processorDescription,
quotaNames,
rdmaBandwidthInGbps,
rdmaPorts,
recommendedAlternatives,
resizeCompatibleShapes,
shape
FROM oci.compute.shapes
WHERE compartmentId = '{{ compartmentId }}' -- required
AND region = '{{ region }}' -- required
AND availabilityDomain = '{{ availabilityDomain }}'
AND limit = '{{ limit }}'
AND page = '{{ page }}'
AND imageId = '{{ imageId }}'
AND shape = '{{ shape }}'
;
Lifecycle Methods​
- remove_image_shape_compatibility_entry
- add_image_shape_compatibility_entry
Removes a shape from the compatible shapes list for the image.
EXEC oci.compute.shapes.remove_image_shape_compatibility_entry
@imageId='{{ imageId }}' --required,
@shapeName='{{ shapeName }}' --required,
@region='{{ region }}' --required
;
Adds a shape to the compatible shapes list for the image.
EXEC oci.compute.shapes.add_image_shape_compatibility_entry
@imageId='{{ imageId }}' --required,
@shapeName='{{ shapeName }}' --required,
@region='{{ region }}' --required
@@json=
'{
"memoryConstraints": "{{ memoryConstraints }}",
"ocpuConstraints": "{{ ocpuConstraints }}"
}'
;