Table: oci_core_instance_metric_cpu_utilization_daily - Query OCI Core Instance Metrics using SQL
OCI Core Instances are virtual servers in the Oracle Cloud Infrastructure that offer flexible and scalable computing capabilities. They are part of the Compute service and can run both Windows and Linux operating systems. Instances are the building blocks of applications deployed in the cloud.
Table Usage Guide
The oci_core_instance_metric_cpu_utilization_daily
table provides insights into the daily CPU utilization metrics of OCI Core Instances. As a system administrator or a DevOps engineer, you can explore CPU usage details through this table, including maximum, minimum, and average utilization. Utilize it to monitor CPU performance, identify instances with high CPU usage, and plan capacity effectively.
Examples
Basic info
Analyze the daily CPU utilization metrics of your OCI Core instances to understand usage patterns and performance trends. This can assist in optimizing resource allocation and identifying potential bottlenecks or underutilized instances.
select id, timestamp, minimum, maximum, average, sample_countfrom oci_core_instance_metric_cpu_utilization_dailyorder by id, timestamp;
select id, timestamp, minimum, maximum, average, sample_countfrom oci_core_instance_metric_cpu_utilization_dailyorder by id, timestamp;
CPU Over 80% average
Analyze the settings to understand instances where CPU utilization exceeds 80% on average. This is useful to identify potential performance issues and manage resource allocation effectively.
select id, timestamp, round(minimum :: numeric, 2) as min_cpu, round(maximum :: numeric, 2) as max_cpu, round(average :: numeric, 2) as avg_cpu, sample_countfrom oci_core_instance_metric_cpu_utilization_dailywhere average > 8order by id, timestamp;
select id, timestamp, round(minimum, 2) as min_cpu, round(maximum, 2) as max_cpu, round(average, 2) as avg_cpu, sample_countfrom oci_core_instance_metric_cpu_utilization_dailywhere average > 8order by id, timestamp;
Schema for oci_core_instance_metric_cpu_utilization_daily
Name | Type | Operators | Description |
---|---|---|---|
_ctx | jsonb | Steampipe context in JSON form. | |
average | double precision | The average of the metric values that correspond to the data point. | |
compartment_id | text | The ID of the compartment. | |
id | text | The OCID of the instance. | |
maximum | double precision | The maximum metric value for the data point. | |
metric_name | text | The name of the metric. | |
minimum | double precision | The minimum metric value for the data point. | |
namespace | text | The metric namespace. | |
region | text | The OCI region in which the resource is located. | |
sample_count | double precision | The number of metric values that contributed to the aggregate value of this data point. | |
sp_connection_name | text | =, !=, ~~, ~~*, !~~, !~~* | Steampipe connection name. |
sp_ctx | jsonb | Steampipe context in JSON form. | |
sum | double precision | The sum of the metric values for the data point. | |
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. | |
timestamp | timestamp with time zone | The time stamp used for the data point. | |
unit | text | The standard unit for the data point. |
Export
This table is available as a standalone Exporter CLI. Steampipe exporters are stand-alone binaries that allow you to extract data using Steampipe plugins without a database.
You can download the tarball for your platform from the Releases page, but it is simplest to install them with the steampipe_export_installer.sh
script:
/bin/sh -c "$(curl -fsSL https://steampipe.io/install/export.sh)" -- oci
You can pass the configuration to the command with the --config
argument:
steampipe_export_oci --config '<your_config>' oci_core_instance_metric_cpu_utilization_daily