Articles

Saturday, December 1, 2012

Changing the hostname on Windows Server 2012

Use the following commands to change the hostname on a Windows Server 2012 Core or Full server from the command line. This can be done with either the Command Prompt or PowerShell console:

Change the hostname from the Command Prompt

> netdom renamecomputer %computername% /newname:<NewName> /reboot:0

Change the hostname from the PowerShell console

> netdom renamecomputer $env:computername /newname:<NewName> /reboot:0


You will be warned that certain services such as Active Directory Certificate Services may not function correctly after changing the hostname. If you do not want to reboot the system immediately omit the /reboot switch. To reboot the server a later time use shutdown -r -t 0.

No comments:

Post a Comment