SQL Server Can't delete google cloud sql replication master instance

svgewumm  于 2023-06-04  发布在  Go
关注(0)|答案(3)|浏览(151)

I decided to play around with Google Could SQL and I setup a test sql instance, loaded it with some data and then setup replication on it in the google dev console. I did my testing and found out it all works great, the master/slave setup works as it should and my little POC was a success. So now I want to delete the POC sql instances but that's not going so well.

I deleted the replica instance fine (aka the 'slave') but for some reason the master instance still thinks there is a slave and therefore will not let me delete it. For example I run the following command in the gclound shell:

gcloud sql instances delete MY-INSTANCE-NAME

I get the following message:

ERROR: (gcloud.sql.instances.delete) The requested operation is not valid for a replication master instance.

This screenshot also shows that in the google dev console it clearly thinks there are no replicas attached to this instance (because I deleted them) but when I run:

gcloud sql instances describe MY-INSTANCE-NAME

It shows that there is a replica name still attached to the instance.

Any ideas on how to delete this for good? Kinda lame to keep on paying for this when it was just a POC that I want to delete (glad I didn't pick a high memory machine!)

nimxete2

nimxete21#

Issue was on Google's side and they fixed it. Here were the sequence of events that led to the issue happening:

  1. Change master's tier
  2. Promote replica to master while the master tier change is in progress
bksxznpy

bksxznpy2#

Just had the same problem using GCloud. Deleting the failover replica first and then the master instance worked for me.

64jmpszr

64jmpszr3#

dont use any google product.

all the products are not stable. are products are poorly coded. have many problems and latency. they are all at development stage.

相关问题