Skip to main content

โญ Repository โ†’ ๐Ÿ“ Compliance Engine โ†’ ๐Ÿ“ CloudAware โ†’ ๐Ÿ“ Google โ†’ ๐Ÿ“ Cloud SQL

๐Ÿ›ก๏ธ Google Cloud SQL Instance Automated Backups are not configured๐ŸŸข

  • Contextual name: ๐Ÿ›ก๏ธ Instance Automated Backups are not configured๐ŸŸข
  • ID: /ce/ca/google/sql/instance-backup
  • Tags:
  • Policy Type: COMPLIANCE_POLICY
  • Policy Categories: RELIABILITY

Logicโ€‹

Similar Policiesโ€‹

Descriptionโ€‹

Open File

Descriptionโ€‹

It is recommended to have all SQL database instances set to enable automated backups.

Rationaleโ€‹

Backups provide a way to restore a Cloud SQL instance to recover lost data or recover from a problem with that instance. Automated backups need to be set for any instance that contains data that should be protected from loss or damage. This recommendation is applicable for SQL Server, PostgreSql, MySql generation 1 and MySql generation 2 instances.

Impactโ€‹

Automated Backups will increase required size of storage and costs associated with it.

Auditโ€‹

From Google Cloud Consoleโ€‹
  1. Go to the Cloud SQL Instances page in the Google Cloud Console by visiting https://console.cloud.google.com/sql/instances.
  2. Click the instance name to open its instance details page.
  3. Go to the Backups menu.
  4. Ensure that Automated backups is set to Enabled and Backup time is mentioned.
From Google Cloud CLIโ€‹
  1. List all Cloud SQL database instances using the following command:
gcloud sql instances list --format=json | jq '. | map(select(.instanceType != "READ_REPLICA_INSTANCE")) | .[].name'

... [see more](description.md)

Remediationโ€‹

Open File

Remediationโ€‹

From Google Cloud Consoleโ€‹

  1. Go to the Cloud SQL Instances page in the Google Cloud Console by visiting https://console.cloud.google.com/sql/instances.
  2. Select the instance where the backups need to be configured.
  3. Click Edit.
  4. In the Backups section, check Enable automated backups, and choose a backup window.
  5. Click Save.

From Google Cloud CLIโ€‹

  1. List all Cloud SQL database instances using the following command:

         gcloud sql instances list --format=json | jq '. | map(select(.instanceType != "READ_REPLICA_INSTANCE")) | .[].name'

NOTE: gcloud command has been added with the filter to exclude read-replicas instances, as GCP do not provide Automated Backups for read-replica instances. 2. Enable Automated backups for every Cloud SQL database instance using the below command:

        gcloud sql instances patch <INSTANCE_NAME> --backup-start-time <[HH:MM]>

The backup-start-time parameter is specified in 24-hour time, in the UTCยฑ00 time zone, and specifies the start of a 4-hour backup window. Backups can start any time during the backup window.

policy.yamlโ€‹

Open File

Linked Framework Sectionsโ€‹

SectionSub SectionsInternal RulesPoliciesFlagsCompliance
๐Ÿ’ผ CIS GCP v1.2.0 โ†’ ๐Ÿ’ผ 6.7 Ensure that Cloud SQL database instances are configured with automated backups - Level 1 (Automated)1no data
๐Ÿ’ผ CIS GCP v1.3.0 โ†’ ๐Ÿ’ผ 6.7 Ensure That Cloud SQL Database Instances Are Configured With Automated Backups - Level 1 (Automated)1no data
๐Ÿ’ผ CIS GCP v2.0.0 โ†’ ๐Ÿ’ผ 6.7 Ensure That Cloud SQL Database Instances Are Configured With Automated Backups - Level 1 (Automated)1no data
๐Ÿ’ผ CIS GCP v3.0.0 โ†’ ๐Ÿ’ผ 6.7 Ensure That Cloud SQL Database Instances Are Configured With Automated Backups - Level 1 (Automated)1no data
๐Ÿ’ผ Cloudaware Framework โ†’ ๐Ÿ’ผ System Configuration34no data
๐Ÿ’ผ FedRAMP High Security Controls โ†’ ๐Ÿ’ผ CP-9 System Backup (L)(M)(H)548no data
๐Ÿ’ผ FedRAMP High Security Controls โ†’ ๐Ÿ’ผ CP-10 System Recovery and Reconstitution (L)(M)(H)26no data
๐Ÿ’ผ FedRAMP Low Security Controls โ†’ ๐Ÿ’ผ CP-9 System Backup (L)(M)(H)7no data
๐Ÿ’ผ FedRAMP Low Security Controls โ†’ ๐Ÿ’ผ CP-10 System Recovery and Reconstitution (L)(M)(H)6no data
๐Ÿ’ผ FedRAMP Moderate Security Controls โ†’ ๐Ÿ’ผ CP-9 System Backup (L)(M)(H)28no data
๐Ÿ’ผ FedRAMP Moderate Security Controls โ†’ ๐Ÿ’ผ CP-10 System Recovery and Reconstitution (L)(M)(H)16no data
๐Ÿ’ผ ISO/IEC 27001:2013 โ†’ ๐Ÿ’ผ A.12.3.1 Information backup1no data
๐Ÿ’ผ ISO/IEC 27001:2022 โ†’ ๐Ÿ’ผ 8.13 Information backup12no data
๐Ÿ’ผ NIST CSF v1.1 โ†’ ๐Ÿ’ผ PR.IP-4: Backups of information are conducted, maintained, and tested47no data
๐Ÿ’ผ NIST CSF v2.0 โ†’ ๐Ÿ’ผ PR.DS-01: The confidentiality, integrity, and availability of data-at-rest are protected117no data
๐Ÿ’ผ NIST CSF v2.0 โ†’ ๐Ÿ’ผ PR.DS-10: The confidentiality, integrity, and availability of data-in-use are protected111no data
๐Ÿ’ผ NIST CSF v2.0 โ†’ ๐Ÿ’ผ PR.DS-11: Backups of data are created, protected, maintained, and tested9no data
๐Ÿ’ผ NIST CSF v2.0 โ†’ ๐Ÿ’ผ RC.RP-01: The recovery portion of the incident response plan is executed once initiated from the incident response process6no data
๐Ÿ’ผ NIST CSF v2.0 โ†’ ๐Ÿ’ผ RC.RP-02: Recovery actions are selected, scoped, prioritized, and performed6no data
๐Ÿ’ผ NIST CSF v2.0 โ†’ ๐Ÿ’ผ RC.RP-03: The integrity of backups and other restoration assets is verified before using them for restoration3no data
๐Ÿ’ผ NIST CSF v2.0 โ†’ ๐Ÿ’ผ RC.RP-05: The integrity of restored assets is verified, systems and services are restored, and normal operating status is confirmed6no data
๐Ÿ’ผ NIST SP 800-53 Revision 4 โ†’ ๐Ÿ’ผ CP-9 INFORMATION SYSTEM BACKUP71no data
๐Ÿ’ผ NIST SP 800-53 Revision 5 โ†’ ๐Ÿ’ผ CP-9 System Backup84no data
๐Ÿ’ผ NIST SP 800-53 Revision 5 โ†’ ๐Ÿ’ผ CP-10 System Recovery and Reconstitution66no data