Tag: remote desktop

  • How to connect to an AzureAD joined computer with Remote Desktop

    How to connect to an AzureAD joined computer with Remote Desktop

    When trying to connect using Remote Desktop Connection (RDP) to a computer which is AzureAD joined, one will not be successful as it will fail to connect. To successfully connect, one should first open the Remote Desktop Connection, enter the details of the devices and save the save your connection settings to a .rdp file.

    To do this, follow the instructions below.

    Open the Remote Desktop Connection program.
    Enter the IP Address or computer name to connect to.
    Click the Save As button at the bottom of the screen.
    Save it someplace convenient as we need to edit it.

    In the next part we will be editing the .rdp file we saved using notepad or any text editor.

    Go to the end of the file, add the following lines:

    enablecredsspsupport:i:0
    authentication level:i:2

    Save the file and close.

    Now, double clicking the modified .rdp file and login using the format:

    AzureAD\YourFullUsername

    You will be able to remote connect to the machine.

  • Fix Remote Desktop Licensing Mode is not configured

    Fix Remote Desktop Licensing Mode is not configured

    Having fully installed Remote Desktop Services (RDS) on a server with the RD Connection Broker and RDS licensing set per user and everything is working with a valid license.

    After some time you notice a popup when you connect saying,

    Remote Desktop licensing mode is not configured
    Remote Desktop Services will stop working in 104 days. On the RD Connection Broker server, use Server Manager to specify the Remote Desktop licensing mode and the license server.

    When you open the RD Licensing Diagnoser, you will be prompted with an error saying, The licensing mode for the Remote Desktop Session Host server is not configured.

    From the Server Manager under Configure the Deployment and RD licensing, all seem to be configured well.

    Open a PowerShell as Administrator on the server and run the following command

    $obj = gwmi -namespace "Root/CIMV2/TerminalServices" Win32_TerminalServiceSetting
    $obj.GetSpecifiedLicenseServerList()

    This will show a parameter called SpecifiedLicenseServerList which would be empty as below.

    To populate the parameter, use the following command

    $obj.SetSpecifiedLicenseServerList("<full fqdn server name>")

    After this is done, the RD Licensing Diagnoser parameter should not report any errors. It is suggested to restart the server after this change.

    Alternatively, one could do this with registry with the following PowerShell script

    # Specify the RDS licensing type: 2 - Per Device CAL, 4 - Per User CAL
    $RDSCALMode = 4
    $RDSlicServer = "<server full fqdn name>"
    # Set the server name and type of licensing in the registry
    New-Item "HKLM:\SYSTEM\CurrentControlSet\Services\TermService\Parameters\LicenseServers"
    New-ItemProperty "HKLM:\SYSTEM\CurrentControlSet\Services\TermService\Parameters\LicenseServers" -Name SpecifiedLicenseServers -Value $RDSlicServer -PropertyType "MultiString"
    Set-ItemProperty "HKLM:\SYSTEM\CurrentControlSet\Control\Terminal Server\RCM\Licensing Core\" -Name "LicensingMode" -Value $RDSCALMode