You manage a production Cloud SQL for MySQL instance named `prod-mysql`. To comply with disaster recovery policies, you need to enable point-in-time recovery (PITR) for the instance. On Cloud SQL for MySQL, PITR requires binary logging to be enabled. Which `gcloud` command should you run to enable binary logging on this instance while preserving all existing configurations?
- gcloud sql instances patch prod-mysql --enable-bin-logCevap
- Bgcloud sql instances patch prod-mysql --enable-point-in-time-recovery
- Cgcloud sql backup-runs create --instance=prod-mysql --enable-bin-log
- Dgcloud storage buckets update gs://prod-mysql --enable-versioning
Cevap
Execute `gcloud sql instances patch prod-mysql --enable-bin-log` to enable binary logging on the Cloud SQL for MySQL instance.
For Cloud SQL for MySQL instances, point-in-time recovery relies on binary logging. The `gcloud sql instances patch prod-mysql --enable-bin-log` command correctly updates the instance parameters to enable binary logging without modifying other settings.
Adım Adım Çözüm
Anahtar Kavram
Cloud SQL Instance Configuration and Backup Management