oci_adm_knowledge_baseoci_adm_vulnerability_auditoci_ai_anomaly_detection_ai_private_endpointoci_ai_anomaly_detection_data_assetoci_ai_anomaly_detection_modeloci_ai_anomaly_detection_projectoci_analytics_instanceoci_apigateway_apioci_application_migration_migrationoci_application_migration_sourceoci_artifacts_container_imageoci_artifacts_container_image_signatureoci_artifacts_container_repositoryoci_artifacts_generic_artifactoci_artifacts_repositoryoci_autoscaling_auto_scaling_configurationoci_autoscaling_auto_scaling_policyoci_bastion_bastionoci_bastion_sessionoci_bds_bds_instanceoci_budget_alert_ruleoci_budget_budgetoci_certificates_authority_bundleoci_certificates_management_associationoci_certificates_management_ca_bundleoci_certificates_management_certificateoci_certificates_management_certificate_authorityoci_certificates_management_certificate_authority_versionoci_certificates_management_certificate_versionoci_cloud_guard_configurationoci_cloud_guard_detector_recipeoci_cloud_guard_managed_listoci_cloud_guard_responder_recipeoci_cloud_guard_targetoci_container_instances_containeroci_container_instances_container_instanceoci_containerengine_clusteroci_core_block_volume_replicaoci_core_boot_volumeoci_core_boot_volume_attachmentoci_core_boot_volume_backupoci_core_boot_volume_metric_read_opsoci_core_boot_volume_metric_read_ops_dailyoci_core_boot_volume_metric_read_ops_hourlyoci_core_boot_volume_metric_write_opsoci_core_boot_volume_metric_write_ops_dailyoci_core_boot_volume_metric_write_ops_hourlyoci_core_boot_volume_replicaoci_core_cluster_networkoci_core_dhcp_optionsoci_core_drgoci_core_imageoci_core_image_customoci_core_instanceoci_core_instance_configurationoci_core_instance_metric_cpu_utilizationoci_core_instance_metric_cpu_utilization_dailyoci_core_instance_metric_cpu_utilization_hourlyoci_core_internet_gatewayoci_core_load_balanceroci_core_local_peering_gatewayoci_core_nat_gatewayoci_core_network_load_balanceroci_core_network_security_groupoci_core_public_ipoci_core_public_ip_pooloci_core_route_tableoci_core_security_listoci_core_service_gatewayoci_core_subnetoci_core_vcnoci_core_vnic_attachmentoci_core_volumeoci_core_volume_attachmentoci_core_volume_backupoci_core_volume_backup_policyoci_core_volume_default_backup_policyoci_core_volume_groupoci_database_autonomous_databaseoci_database_autonomous_db_metric_cpu_utilizationoci_database_autonomous_db_metric_cpu_utilization_dailyoci_database_autonomous_db_metric_cpu_utilization_hourlyoci_database_autonomous_db_metric_storage_utilizationoci_database_autonomous_db_metric_storage_utilization_dailyoci_database_autonomous_db_metric_storage_utilization_hourlyoci_database_dboci_database_db_homeoci_database_db_systemoci_database_pluggable_databaseoci_database_software_imageoci_devops_projectoci_devops_repositoryoci_dns_rrsetoci_dns_tsig_keyoci_dns_zoneoci_events_ruleoci_file_storage_file_systemoci_file_storage_mount_targetoci_file_storage_snapshotoci_functions_applicationoci_functions_functionoci_identity_api_keyoci_identity_auth_tokenoci_identity_authentication_policyoci_identity_availability_domainoci_identity_compartmentoci_identity_customer_secret_keyoci_identity_dynamic_groupoci_identity_groupoci_identity_network_sourceoci_identity_policyoci_identity_tag_defaultoci_identity_tag_namespaceoci_identity_tenancyoci_identity_useroci_kms_keyoci_kms_key_versionoci_kms_vaultoci_logging_logoci_logging_log_groupoci_logging_searchoci_mysql_backupoci_mysql_channeloci_mysql_configurationoci_mysql_configuration_customoci_mysql_db_systemoci_mysql_db_system_metric_connectionsoci_mysql_db_system_metric_connections_dailyoci_mysql_db_system_metric_connections_hourlyoci_mysql_db_system_metric_cpu_utilizationoci_mysql_db_system_metric_cpu_utilization_dailyoci_mysql_db_system_metric_cpu_utilization_hourlyoci_mysql_db_system_metric_memory_utilizationoci_mysql_db_system_metric_memory_utilization_dailyoci_mysql_heat_wave_clusteroci_network_firewall_firewalloci_network_firewall_policyoci_nosql_tableoci_nosql_table_metric_read_throttle_countoci_nosql_table_metric_read_throttle_count_dailyoci_nosql_table_metric_read_throttle_count_hourlyoci_nosql_table_metric_storage_utilizationoci_nosql_table_metric_storage_utilization_dailyoci_nosql_table_metric_storage_utilization_hourlyoci_nosql_table_metric_write_throttle_countoci_nosql_table_metric_write_throttle_count_dailyoci_nosql_table_metric_write_throttle_count_hourlyoci_objectstorage_bucketoci_objectstorage_objectoci_ons_notification_topicoci_ons_subscriptionoci_queue_queueoci_regionoci_resource_searchoci_resourcemanager_stackoci_streaming_streamoci_vault_secret
Table: oci_core_instance
An core instance is a virtual server in the Oracle Cloud Infrastructure cloud.
Examples
Basic info
select display_name, id, time_created, lifecycle_state as state, shape, regionfrom oci_core_instance;
List instances along with the compartment details
select inst.display_name, inst.id, inst.shape, inst.region, comp.name as compartment_namefrom oci_core_instance inst inner join oci_identity_compartment comp on (inst.compartment_id = comp.id)order by comp.name, inst.region, inst.shape;
Count the number of instances by shape
select shape, count(shape) as countfrom oci_core_instancegroup by shape;
List instances with shape configuration details
select display_name, shape_config_max_vnic_attachments, shape_config_memory_in_gbs, shape_config_networking_bandwidth_in_gbps, shape_config_ocpus, shape_config_baseline_ocpu_utilization, shape_config_gpus, shape_config_local_disks, shape_config_local_disks_total_size_in_gbsfrom oci_core_instance;
Query examples
- blockstorage_block_volume_attached_instances
- blockstorage_block_volume_unattached_report
- blockstorage_boot_volume_attached_instances
- blockstorage_boot_volume_unattached_report
- compute_images_for_compute_instance
- compute_instance_1_year
- compute_instance_24_hrs
- compute_instance_30_days
- compute_instance_365_days
- compute_instance_90_days
- compute_instance_age_report
- compute_instance_by_compartment
- compute_instance_by_creation_month
- compute_instance_by_public_ip
- compute_instance_by_region
- compute_instance_by_tenancy
- compute_instance_by_type
- compute_instance_core
- compute_instance_count
- compute_instance_input
- compute_instance_launch_options
- compute_instance_monitoring
- compute_instance_monitoring_disabled_count
- compute_instance_overview
- compute_instance_public_instance_count
- compute_instance_shape
- compute_instance_state
- compute_instance_tag
- compute_instance_total_cores
- vcn_network_security_group_assoc
Control examples
- boot_and_block_volume_attached_stopped_instance
- compute_instance_long_running
- compute_instance_low_utilization
- compute_instance_monitoring_enabled
- autoscaling_auto_scaling_configurations_for_compute_instance
- compute_instance_by_monitoring
.inspect oci_core_instance
OCI Core Instance
Name | Type | Description |
---|---|---|
_ctx | jsonb | Steampipe context in JSON form, e.g. connection_name. |
agent_config | jsonb | Options for the Oracle Cloud Agent software running on the instance. |
availability_config | jsonb | Options for defining the availability of a VM instance after a maintenance event that impacts the underlying hardware. |
availability_domain | text | The availability domain the instance is running in. |
capacity_reservation_id | text | The OCID of the compute capacity reservation this instance is launched under. |
compartment_id | text | The OCID of the compartment in Tenant in which the resource is located. |
dedicated_vm_host_id | text | The OCID of dedicated VM host. |
defined_tags | jsonb | Defined tags for resource. Defined tags are set up in your tenancy by an administrator. Only users granted permission to work with the defined tags can apply them to resources. |
display_name | text | A user-friendly name. Does not have to be unique, and it's changeable. |
extended_metadata | jsonb | Additional metadata key/value pairs that user provided to instance. |
fault_domain | text | The name of the fault domain the instance is running in. A fault domain is a grouping of hardware and infrastructure within an availability domain. |
freeform_tags | jsonb | Free-form tags for resource. This tags can be applied by any user with permissions on the resource. |
id | text | The OCID of the instance. |
instance_options | jsonb | Optional mutable instance options. |
ipxe_script | text | When a bare metal or virtual machine instance boots, the iPXE firmware that runs on the instance is configured to run an iPXE script to continue the boot process. |
launch_mode | text | Specifies the configuration mode for launching virtual machine (VM) instances. |
launch_options | jsonb | LaunchOptions Options for tuning the compatibility and performance of VM shapes. |
lifecycle_state | text | The current state of the instance. |
metadata | jsonb | Custom metadata that you provided to instance. |
platform_config | jsonb | The platform configuration for the instance. |
region | text | The OCI region in which the resource is located. |
shape | text | The shape of the instance. The shape determines the number of CPUs and the amount of memory allocated to the instance. |
shape_config | jsonb | The shape configuration for an instance. The shape configuration determines the resources allocated to an instance. |
shape_config_baseline_ocpu_utilization | text | The baseline OCPU utilization for a subcore burstable VM instance. |
shape_config_gpus | bigint | The number of GPUs available to the instance. |
shape_config_local_disks | bigint | The number of local disks available to the instance. |
shape_config_local_disks_total_size_in_gbs | double precision | The aggregate size of all local disks, in gigabytes. |
shape_config_max_vnic_attachments | bigint | The maximum number of VNIC attachments for the instance. |
shape_config_memory_in_gbs | double precision | The total amount of memory available to the instance, in gigabytes. |
shape_config_networking_bandwidth_in_gbps | double precision | The networking bandwidth available to the instance, in gigabits per second. |
shape_config_ocpus | double precision | The total number of OCPUs available to the instance. |
source_details | jsonb | Contains the details of the source image for the instance. |
system_tags | jsonb | Tags added to instances by the service. |
tags | jsonb | A map of tags for the resource. |
tenant_id | text | The OCID of the Tenant in which the resource is located. |
tenant_name | text | The name of the Tenant in which the resource is located. |
time_created | timestamp with time zone | The date and time the instance was created |
time_maintenance_reboot_due | timestamp with time zone | The date and time the instance is expected to be stopped/started. After that time if instance hasn't been rebooted, Oracle will reboot the instance within 24 hours of the due time. |
title | text | Title of the resource. |