How to Remove the Server From The Cluster

I have removed the server from the DAG using the below command as I want to shutdown/decommission the server. The server has been removed from the DAG but it has not been removed from the cluster.

Remove-DatabaseAvailabilityGroupServer -Identity DAG -MailboxServer MBX01 -ConfigurationOnly

How can I remove it from the cluster as it showing in the cluster if I run the command Get-ClusterNode?
Muhammad AsifSenior Solutions ArchitectAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Vidit BhardwajAdminCommented:
Run set-dag command without any parameters see if it is updated after this, if this doesn't work remove the node from cluster.. cluster node servername /forcecleanup

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Muhammad AsifSenior Solutions ArchitectAuthor Commented:
Hi Vidit,

Thanks for your reply. Should I need to run the below command without any parameter?

Set-DatabaseAvailabilityGroup -Identity DAG-Name
Vidit BhardwajAdminCommented:
Yes that's correct nothing else required, we are trying to just replicate the dag settings to cluster
Muhammad AsifSenior Solutions ArchitectAuthor Commented:

I have tried to run the command Set-DatabaseAvailabilityGroup -Identity DAG-Name but was getting an below error.

The following servers in the Windows Failover Cluster are not in Active Directory: This is usually the
result of an incomplete membership change (add or remove) of the database availabilty group.
    + CategoryInfo          : InvalidArgument: (:) [Set-DatabaseAvailabilityGroup],

After it, i have remove the server from the cluster with the following command and then everything looks good and issue has been resolved.

Remove-ClusterNode -Name Server-Name
Vidit BhardwajAdminCommented:
Yeah that's right...I was hoping to replicate the configuration the force removal should have been last options!!

Cheers mate!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.