In Windows Server 2016 you no longer have an opportunity to switch back and forth between core and GUI installation, hence you cannot do install and configure AD DS in a lazy way (using full GUI) and then convert it to core. That was something I discovered hard way long time ago – so I already have separate VHDX templates for Server 2016 core and full GUI VMs.
But it has been quite a while since I was playing with Server Core so when I starting provisioning my new Server 2016 core domain controller VMs today I realized that I need to remember quite a few commands to fully install AD DS on Server Core. I was about to create a blog post listing essential commands, but actually found very well written blog post on TechNet covering exactly that: Chad’s Quick Notes – Installing a Domain Controller with Server 2016 Core. So just sharing it here, instead of writing the same myself 🙂
Just a quick note on renaming Windows based machine using CLI (this may be especially useful when working with Server Core).
Before renaming machine you may want to see its current name which can be achieved in three different ways:
1) ipconfig /all
As you can see third option is best one as it gives you specifically machine name without need to search through loads of other details.
Now how to rename. You can use either NETDOM command or Rename-Computer cmdlet:
1) netdom (more details here):
netdom renamecomputer %computername% /newname:NewName /userd:domain\username /passwordd:P@ssw0rd /reboot:0
Rename-Computer -NewName "NewComputerName" -Restart
Since Windows Server 2012 allowed add/remove of GUI “on the fly” via Uninstall-WindowsFeature/Ininstall-WindowsFeature and their aliases amount of questions “How do I do X in Server Core” decreased drastically as there is now universal lazy man response to this – temporarily add GUI do thing X and remove GUI again. Not always time efficient but effective 🙂
Anyhow almost everything can be done without GUI. Here is your option to perform domain join operation for server core box:
1) Old-school crutch sconfig 🙂 Option (1):
You may see that it actually uses in netdom.exe in the background when it asks for password:
It even suggest you to change computer name in case you forgot do it in advance:
Assuming you entered correct password and DNS/IP settings allow you to locate and reach out domain controller you will receive reboot prompt in the end of this process:
Once restart is performed you can verify the results either via WMIC or PowerShell:
2) Add-Computer commandlet.
3) djoin command. This one allows to perform offline domain join.
There is also related dsadd command but this can only be used to pre-create computer account in domain. This utility will create a computer account in the domain, but will not join the local computer from a workgroup to a domain.
Just a brief disclaimer on why I’m writing this for those who find it strange to see words “what’s new” and “Server 2008 R2” at the time when everyone talks about Windows Server 2012 (probably even 2012 R2): 1) I decided to complete my WS 2008 certification so jotting down some points for myself. 2) As I’m going into details what was actually added in WS2008 R2 I do realize that there are loads of good stuff and foundations for some of the things which WS2012 offers have been laid in this release actually (and it sadly that “R2” releases often perceived as something minor). After disclaimer has been made I may proceed with my post.
So the new features available are following:
1. .NET Framework – 2.0, 3.0, 3.5.1, 4.0 are now supported on Server Core installation.
2. ASP.NET – as .NET is now supported on Server Core R2 ASP.NET can be enabled.
4. AD CS – AD Certificate Services role can be installed on Server Core R2 system.
5. SCONFIG (something which may remind you text option menus in old games by its pseudo-GUI, think of Duke Nukem, Doom or something): just type SCONFIG & configure your server core deployment – knowledge of proper CLI commands no longer is prerequisite. Things you can do with SCONFIG: Domain Join, Rename Computer, Configure Remote Management, Network Settings, Download and Install Updates etc.
Those who use pre R2 version of Windows Serve core may employ Server Core Configurator 1.1 which will provide you with GUI for your Windows 2008 Server Core configuration tasks. Version 2.0 runs only on Windows Server 2008 R2 as it requires PoSh 2.0 and NetFx.