Table: oci_mysql_backup
MySQL Database Service supports the following backup types:
FULL: a backup of all data contained in the DB System. INCREMENTAL: a backup of only the data which has been added or changed since the last FULL backup.
Backups are run in either of the following ways:
Manual: a backup initiated by an action in the console, or request made through the API. Manual backups can be retained for a minimum of 1 day and a maximum of 365 days. Currently, there is a limit of 100 manual backups per tenancy. Automatic: scheduled backups which run, without any required interaction, at a time of the user's choosing. Automatic backups are retained for between 1 and 35 days. The default retention value is 7 days. Once defined, it is not possible to edit the retention period of an automatic backup.
Examples
Basic info
select display_name, id, description, lifecycle_state as state, backup_type, mysql_versionfrom oci_mysql_backup;
List manual backups
select display_name, id, creation_typefrom oci_mysql_backupwhere creation_type = 'MANUAL';
List backups with retention days less than 90 days
select display_name, id, retention_in_daysfrom oci_mysql_backupwhere retention_in_days < 90;
Count of backups per DB system
select db_system_id, count(*) as backup_countfrom oci_mysql_backupgroup by db_system_id;
Query examples
- mysql_automatic_backup_count
- mysql_backup_1_year
- mysql_backup_24_hrs
- mysql_backup_30_days
- mysql_backup_365_days
- mysql_backup_90_days
- mysql_backup_age_report
- mysql_backup_by_backup_type
- mysql_backup_by_compartment
- mysql_backup_by_creation_month
- mysql_backup_by_creation_type
- mysql_backup_by_region
- mysql_backup_by_tenancy
- mysql_backup_count
- mysql_backup_storage_by_backup_type
- mysql_backup_storage_by_compartment
- mysql_backup_storage_by_creation_month
- mysql_backup_storage_by_creation_type
- mysql_backup_storage_by_region
- mysql_backup_storage_by_tenancy
- mysql_backup_storage_total
- mysql_backups_for_mysql_db_system
- mysql_db_system_backup
- mysql_db_system_backup_disabled_count
- mysql_full_backup_count
.inspect oci_mysql_backup
OCI MySQL Backup
Name | Type | Description |
---|---|---|
_ctx | jsonb | Steampipe context in JSON form, e.g. connection_name. |
backup_size_in_gbs | bigint | The size of the backup in GiBs. |
backup_type | text | The type of backup. |
compartment_id | text | The OCID of the compartment in Tenant in which the resource is located. |
creation_type | text | If the backup was created automatically, or by a manual request. |
data_storage_size_in_gbs | bigint | Initial size of the data volume in GiBs. |
db_system_id | text | The OCID of the DB System the Backup is associated with. |
db_system_snapshot | jsonb | Snapshot of the DbSystem details at the time of the backup. |
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. |
description | text | A user-supplied description of the backup. |
display_name | text | A user-supplied display name for the backup. |
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 backup. |
lifecycle_details | text | Additional information about the current lifecycleState. |
lifecycle_state | text | The current state of the Backup. |
mysql_version | text | The version of the DB System used for backup. |
region | text | The OCI region in which the resource is located. |
retention_in_days | bigint | Number of days to retain this backup. |
shape_name | text | The shape of the DB System instance used for backup. |
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 time the backup record was created. |
time_updated | timestamp with time zone | The time at which the backup was updated. |
title | text | Title of the resource. |