How to fix Server 2012r2 RDP Licensing Problem

To fix the problem, run commands in powershell to set the licensing server properly on the rd session host using the WMI CIM provider:

$obj = gwmi -namespace “Root/CIMV2/TerminalServices” Win32_TerminalServiceSetting
$obj. SetSpecifiedLicenseServerList(“licserver.domain.local”)

Then, go into the registry and manually set the licensing mode:

HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server\RCM\Licensing Core\LicensingMode

You need to change the DWORD to 2 for Per Device or 4 for Per User.

Next, reboot the system. The changes made previously will report everything properly and the RDS host will now recognize the licensing configuration.