As I am currently between jobs (read: Unemployed), I thought I would build my own mini lab to help practice the timeless art of being a Windows System Administrator. To that end I have purchased a Intel i5 NUC (D54250WYKH). I chose this as a lab computer because my current place doesn’t have much space, and while it may not have incredible performance, it’s reasonably powerful enough to run a number of virtualised servers, provided you have enough ram and an SSD.
This post will cover installing Windows Server 2012 R2 Core with Hyper-V on an Intel NUC in a workgroup environment (non domain joined).
Initial Notes
- According to Intel the D54250WYKH does not come with AMT, so unfortunately you’ll have to connect a keyboard and monitor at least initially as Windows Server 2012 R2 does not come with the nic drivers ootb.
- The steps below rely on using both the command prompt and PowerShell. To enter PowerShell from the command prompt in Windows Server Core, just type: powershell. To exit PowerShell back to the command prompt, just type: exit.
- The client I am using is a Windows 8.1 Pro computer
Ingredients
You’ll need the following:
- An Intel NUC (D54250WYKH), and the following drivers:
- Ethernet Adapter (you will need to modify the driver to allow installation on Windows Server 2012 R2, follow these steps)
- Chipset Device Software (you will need to extract the driver from the installer, you can do that by running SetupChipset.exe with the -extract argument)
- Management Engine Driver
- Windows 2012 R2 on a bootable USB
- Hyper-V Remote Management Configuration Utility (HVRemote)
Steps
- Install Windows Server 2012 R2 Core.
- Give the server a name, in PowerShell run:
Rename-Computer -NewName server-name -Restart - Because we are installing modified drivers, we need to disable Windows restrictions around unsigned drivers, run the following commands in command prompt:
bcdedit /set LOADOPTIONS DISABLE_INTEGRITY_CHECKS
bcdedit /set TESTSIGNING ON
bcdedit /set nointegritychecks ON
You will now need to reboot the server - Install the drivers using pnputil in command prompt:
pnputil.exe -i -a D:intel-driversnicRarSFX0PRO1000Winx64NDIS64e1d64x64.inf
You will be prompted with Windows can’t verify the publisher of this driver software, just Install this driver software anyway
pnputil.exe -i -a D:intel-driverssmbusChipset_SMBus.inf
pnputil.exe -i -a D:intel-driversintelMEDriversMEIheci.inf - Now you should have network connectivity, lets enable remote desktop connections, file sharing and ping with powershell:
Set-ItemProperty -Path ‘HKLM:SystemCurrentControlSetControlTerminal Server’ -Name “fDenyTSConnections” -Value 0
Enable-NetFirewallRule -DisplayGroup “Remote Desktop”
Enable-NetFirewallRule –DisplayGroup “File and Printer Sharing” - Install Hyper-V and allow remote management (this is where you will need the hvremote script):
Install HyperV: Install-WindowsFeature –Name Hyper-V -IncludeManagementTools –Restart
cscript hvremote.wsf /mode:server /add:administrator
cscript hvremote.wsf /mode:server /firewallhypervmgmt:enable
cscript hvremote.wsf /mode:client /anondcom:grant - If you are remoting to this server you will need to whitelist clients using the following command:
winrm set winrm/config/client @{TrustedHosts=”client-name”} - On your Hyper-V client
- Make sure you have PowerShell and the HyperV Management Tools installed
- Open Component Services
- Expand Component Services, then Computers
- Right click on My Computer and click on Properties.
- In the COM Security tab, click Edit Limits under Access Permissions.
- Enable Remote Access for Anonymous Logon
- In PowerShell run:
Set-Item WSMAN:LocalhostClientTrustedHosts -Value * -Force # * - In command prompt (replace the server-name and password):
cmdkey /add:server-name /user:ADMINISTRATOR /pass:password
Closing Notes
You should now be able to:
- Connect your client HyperV manager to the server you created
- Enter remote PowerShell sessions via Enter-PSSession -ComputerName
- Ping and File Share with your server
There will be some devices that aren’t installed, these are 2 Audio Devices and the Infrared sensor on the front of the Nuc, I have not bothered to install those drivers.
If you have any comments, please leave them! I would appreciate the feedback, and I would also love to know if I have missed anything or whether I should have done something differently.