question

geradmin-6282 avatar image
0 Votes"
geradmin-6282 asked AmeliaGu-msft commented

SQL always on maintenance mode

Hi,

i have 2 sql 2016 standard with some DB configured with basic always on availability.

So, next weekend the electricity will be disconnected for 2 days and i need to poweroff all server.

Since it is the first time that this happens to me, what's the correct procedure to put the 2 sql server on maintence and power off?

I will need to pause the alwayson, suspend the cluster service on replica sql server ( Suspend-ClusterNode) and power off it and then power off the first sql server? right?

thanks

Andrea

sql-server-general
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi geradmin-6282,
Did the answer help you?
Please feel free to let us know if you have any other question.
If you find any post in the thread is helpful, you could kindly accept it as answer.

Best Regards,
Amelia

0 Votes 0 ·

1 Answer

AmeliaGu-msft avatar image
0 Votes"
AmeliaGu-msft answered

Hi geradmin-6282,
Welcome to Microsoft Q&A.

I will need to pause the alwayson, suspend the cluster service on replica sql server ( Suspend-ClusterNode) and power off it and then power off the first sql server? right?

We can suspend the data movement for the primary replica.

 ALTER DATABASE database_name SET HADR SUSPEND;

After maintenance, we can resume a suspended availability database to make it work again.

 ALTER DATABASE database_name SET HADR RESUME;

Please refer to this article which might help.

For Windows failover cluster, if you need to perform extensive diagnosis or maintenance on cluster nodes, it might be more workable to stop (not pause) the Cluster service on the nodes. Please refer to Stop-ClusterNode which might help.

Best Regards,
Amelia


If the answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.