Dela via


What is the simplest command line to dcpromo *down* a Server Core machine?

In my test environment I just discovered an issue and need to remove the Domain Controller role from one of my Hyper-V hosts which happens to be running Server Core.  This brought a question to mind, if I want to demote a DC running Core, what is the path of least resistance?

I found that if I am willing to accept all default parameters I could do it with just one command line argument –

dcpromo /AdministratorPassword:<password>

To review the default parameters, type “dcpromo /?:Demotion”.  Unfortunately my RDP session closed before I could copy/paste the full output of the command.  If anyone captures it, feel free to drop it in the comments.  It basically confirms each step of removing the role, dns records, binaries, etc.  Note that if your DC is the last DC within the domain you would need to specify additional parameters.

Comments

  • Anonymous
    January 09, 2010
    What a dangerous and yet sweet command!  Haha, I was about to capture it for you... but then it rebooted!

  • Anonymous
    September 20, 2010
    The comment has been removed

  • Anonymous
    April 01, 2015
    Hi
    I have another question.
    Why do I receive an error message which goes as " The specified argument AdministratorPassword was not recognized" every time i type dcpromo /unattend /AdministratorPassword:Passw0rd and hit enter