Cloud SQL
Cloud SQL Right Sizing
This recommendation identifies low memory/cpu utilization of Cloud SQL that can be stoped or deleted.
Recommendation Logic
Trigger when:
- CPU utilization < X% (default 30%).
- Memory usage < Y% (default 30%).
- Spare Capacity < X% (default 30%).
- Instance running but no connections, user_connections = 0.
Estimated Savings
Current instance cost – recommended instance cost.
- The Cloud SQL Admin API must be enabled on the GCP project.
- Open the Google Cloud Console [API Library] (https://console.cloud.google.com/apis/library).
- Select your target project from the top drop-down menu.
- Search for "Cloud SQL Admin API" in the search bar.
- Click on the Cloud SQL Admin API result.
- Click the blue ENABLE button.
- Predefined role :roles/cloudsql.viewer.
- If you are using a custom IAM role instead of predefined roles, the individual permissions to add are:
- cloudsql.instances.list
- cloudsql.tiers.list
- Days To Check, default=30 days.
- CPU Utilization Threshold (%), default=30.
- CPU Spare Capacity (%), default=30.
- Memory Utilization Threshold (%), default=30.
- Memory Spare Capacity (%), default=5.
Umbrella.
No.
Cloud SQL Idle
Identifying Cloud SQL instances that are idle based on low CPU utilization.
Trigger Logic
CPU utilization = 0 during the days to check period.
Completion Logic
The instance wont arrive in the invoice.
Estimated Savings
Current instance cost.
- The Cloud SQL Admin API must be enabled on the GCP project.
- Open the Google Cloud Console [API Library] (https://console.cloud.google.com/apis/library).
- Select your target project from the top drop-down menu.
- Search for "Cloud SQL Admin API" in the search bar.
- Click on the Cloud SQL Admin API result.
- Click the blue ENABLE button.
- Predefined role :roles/cloudsql.viewer.
- If you are using a custom IAM role instead of predefined roles, the individual permissions to add are:
- cloudsql.instances.list
- cloudsql.tiers.list
- Days To Check, default=30 days.
- Min Active Days:The minimum cumulative number of active days for the resource within the Activity Period, not consecutive (Example: Only recommend on servers running at least 15 days in the period). (Default= 10)
Umbrella.
No.
Updated 17 days ago
Did this page help you?
