Compute Engine (GCE)
SmartSRE provides resource optimization and cleanup for Google Compute Engine.
What SmartSRE Scans
| Category | Checks |
|---|---|
| Utilization | CPU/memory usage, idle instances |
| Storage | Detached disks, old snapshots |
| Cost | Right-sizing opportunities, preemptible candidates |
| Operations | Instance scheduling, labels |
Findings
| Issue Type | Severity | Description |
|---|---|---|
detached_disk | Medium | Disk not attached to any instance |
old_snapshot | Low | Snapshot > 365 days old |
idle_instance | Medium | Instance with < 5% CPU for 7+ days |
over_provisioned | Low | Instance could use smaller machine type |
Available Fixes
| Operation | Description | Impact |
|---|---|---|
stop_instance | Stop idle instance | High |
delete_detached_disk | Delete unattached disk | High |
delete_old_snapshot | Delete old snapshot | Medium |
resize_instance | Change machine type | Medium |
Required Permissions
For Scanning
roles/compute.viewer
roles/monitoring.viewer
For Remediation
roles/compute.instanceAdmin.v1
Best Practices
- Schedule dev instances — Stop at night/weekends
- Clean up detached disks — Snapshot before deletion
- Use labels — Enable filtering by environment
- Review snapshots quarterly — Remove outdated backups