We need to change our Google cloud SQL instance from db-g1-small to db-n1-standard-1. Can I change it with zero downtime?
Edit 1
I think I found the answer. It seems that it will take a few seconds of downtime.
You can change an instance's tier at any time, with just a few seconds of downtime.
https://cloud.google.com/sql/pricing
Edit 2
I tried it on our dev env. The downtime was about 10 sec.
while true; date; do curl https://api.xxx.com/v1/items; echo ""; sleep 1s; done
2016/8/29 16:24:50 JST
{"OK"}
2016/8/29 16:24:51 JST
Error
2016/8/29 16:25:01 JST
{"OK"}
You can only change the machine type of a stopped VM. A VM is considered stopped only when the VM is in the TERMINATED state. You cannot change the machine type of a running VM. Caution: If you do not have reservations for the new machine types, changing the machine type can result in resource availability errors.
The high availability configuration allows data redundancy in multiple zones inside the region you choose while deploying your DB instance. If you decide to enable high availability, Cloud SQL will set up two DB instances in two different locations with the same region.
Other methods for horizontal scaling include master-slave configurations and sharding. Cloud SQL does not support these configurations natively, though they may be implemented externally using industry tools such as ProxySQL.
The note about changing tier in a few seconds is under the First Generation section of that page.
For a Second Generation instance, it may take several minutes.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With