I know number of post is available on this topic, but it’s not stopping me to make a note here for future reference.
Clean Failed/offline Domain controllers from Active Directory.
Remove failed Domain controllers from AD manually
‘Dcpromo’ normally used to install and uninstall Doman controllers, however if domain controllers is crash and unable to run dcpromo scenarios for uninstall, it’s indeed to use manual way to clean metadata from the active directory. Below is discussing the step by step process
First thing need to check failed DC’s are holding any FSMO roles. If its holding FSMO, require to seize fsmo role to other domain controllers. The detail steps of FSMO transfer mentioned in below article
The next step is clean server metadata from active directory database. There are three methods to cleanup and my choice always using command line
The following sections contains metadata cleanup using ntdsutil and follow above hyperlinks to know other methods
Method 2 : Using metadata cleanup to force demote failed/offline DCs using command line
1). Log on to a working well DC open a prompt command, run “ntdsutil”.
2). Run “metadata cleanup”, and then run “connections”.
3). Run “connect to server servername”, whereservername is the server which is working well in your environment.
4). Run “quit”, the “Metadata Cleanup” menu appears.
5). Run “select operation target”, and then run “list domains”.
6). Run “select domain number”, where number is the number associated with the domain the server you are removing is a member of.
7). Run “list sites”, and then run “select site number”, where number is the number associated with the site the server you are removing is a member of.
8). Run “list servers in site”, and then run “select server number”, where number is the number associated with the server you want to remove. (If display No current site” “No current server’’ please ignore)
9). Run “quit”, the “Metadata Cleanup” menu appears.
10). Run “remove selected server”, You should receive confirmation that the connection disconnected successfully.
Please do not forget to delete all remaining DNS records of the cleaned domain controlers
After the above actions, the failed DC can go forever. Please wait for a while as we should wait for the AD replication completed.