The server that was the license server for my remote desktop server was decommissioned, so I want to remove it from the configuration.

If I go in Server Manager > Remote Desktop Services > Overview and then RD Licensing > right click > Remove RD Licensing Servers I end up with Could not remove the configuration. Object reference not set to an instance of an object.

If I try to do it with PowerShell using remove-rdserver server.domain.local rds-licensing I get the same error with more "details"

Object reference not set to an instance of an object.
    + CategoryInfo          : InvalidResult: (:) [], NullReferenceException
    + FullyQualifiedErrorId : JobStateFailed
    + PSComputerName        : localhost

Is there a way to remove this old license server? Without deleting the whole remote desktop configuration and re-creating everything I mean.


I had the same error. Login with the SQL-Manager Server to the localhost.


TSQL> To remove the orphaned Server with the ID 1005.
use RDCms
delete from rds.RoleRdsh where ServerId = ‘1005’

Dave Harris wrote a excelent blog to this issue.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.