When domain controllers are taken offline without being demoted first, the domain metadata is still left in Active Directory. This article illustrates how to remove that domain metadata with the help of NTDSUTIL utility.
Open PowerShell with elevated privileges and execute the following commands in sequence.
Step 1. Type ntdsutil and hit enter from keyboard