Rodolffo
Rodolffo

Reputation: 105

Google Cloud SQL Maintenance Window

The reason I'm hesitating between RDS and Cloud SQL is that I couldn't find that if I set a Cloud SQL instance to high availability with read replicas how will the scheduled maintenances happen. After reading SO and documentation for quite a few hours now I believe that even in case of a HA instance you can experience outages due to scheduled maintenance, so you cannot set any settings / policies to have virtually 100% uptime unlike in AWS RDS where you can set different maintenance windows for replicas.

Am I right? If not, how to achieve the same as in AWS? If I am, what's the rationale behind this behaviour? How are you even supposed to move your service to GCP if you can't guarantee it being always accessible? What's even the point of HA if it also has downtimes?

Upvotes: 4

Views: 4190

Answers (3)

wanderingPanda
wanderingPanda

Reputation: 33

GCP has pretty good documentation on the steps of maintenance. HA is only for unplanned outrage

https://cloud.google.com/sql/docs/mysql/maintenance#pre-maintenance

Upvotes: 0

Parth Mehta
Parth Mehta

Reputation: 1917


Edit

I haven't personally experienced this myself but based on Stefan G's pointer, there has been open issue with Google Cloud SQL which despite having HA which caused downtime during maintenance window:


High availability equates to multi-az sql instance. So when you set this option you get a primary instance running in a zone and secondary in another zone. So when maintenance window kicks in the cloud sql should automatically fail over to the other availability zone and your app / users shouldn't be affected. However there are some reported incidents where Cloud SQL caused a downtime (see edit notes below).

Read-replicas on the other hand helps you offload traffic from your master instance it does not give you redundancy.

No hosted SQL offers 100% uptime guarantee. RDS Aurora offers 99.99%. Cloud SQL on the other hand offers 99.95% uptime guarantee, which equates to downtime of no more than Daily: 43.2s. Weekly: 5m 2.4s. Monthly: 21m 54.9s.

We use Cloud SQL and it's reliable enough and upgrades during maintenance window are seamless.

Hope this helps.

Upvotes: 1

Maxim
Maxim

Reputation: 4431

Read replicas neither provide High Availability nor offer it, and I'm afraid they do not support the maintenance window either. This is explained in the Cloud SQL FAQs among other information.

There are Feature Requests opened on the Public Issue Tracker regarding this here and here - you may show your interest by clicking on the star button.

When scheduled maintenance occurs, the operations are first performed on the read replica(s) and then on the master instance. Cloud SQL attempts to keep one of them running at all time, but this is not guaranteed, is subject to change and you shouldn't rely on it.

If availability is that critical for you, you are better off using Cloud Spanner instead, which offers a 99.999% availability SLA.

Upvotes: 3

Related Questions