How To Install User Cal License In Windows 2016 Server
In this commodity, we'll consider the installation, configuration, and activation of the Remote Desktop Licensing role on Windows Server 2019 and 2016, too as the installation and activation of the RDS client access licenses (CALs).
I remind you that later the installation of the Remote Desktop Session Host role, users can utilize it only for 120 days of a trial menses (evaluation license), and users tin't connect to an RDS host afterward. According to Microsoft licensing rules, all users or devices that use RDS features must be licensed. To register and issue Remote Desktop Client Access Licenses (RDS CALs), at that place is a split Windows service in the RDS role chosen Remote Desktop License Server.
Contents:
- Install the Remote Desktop Licensing Office on Windows Server 2019/2016
- Activating the RDS License Server on Windows Server
- RDS CALs: Types of Remote Desktop Client Access Licenses
- Installing RDS CALs on Windows Server 2019/2016
- RDS CAL Usage Reports
- How to Remove RDS CALs from an RD License Server?
- Configuring RDS Licenses on RD Session Hosts
Install the Remote Desktop Licensing Role on Windows Server 2019/2016
You can deploy the Remote Desktop License service on whatsoever domain server. Information technology is not necessary to install it on one of the servers on the RDSH subcontract.
Earlier you start the installation, add a new server to the Terminal Server License Servers domain security group (or brand certain you take the permission to change this group membership), otherwise, the server won't exist able to issue RDS Per User CAL to the domain users.
You can install Remote Desktop Licensing using Server Manager. To do it, select the Remote Desktop Services role in the Add Roles and Features Sorcerer.
Select Remote Desktop Licensing as the office service.
It remains to wait until the installation of the role is completed.
The RDS-Licensing service is managed using the Remote Desktop Licensing Managing director console (licmgr.exe
).
In Windows Server, information technology's easier to install roles and features using PowerShell. To install the RDS Licensing Service and RD Licensing Diagnoser, just run one command:
Install-WindowsFeature RDS-Licensing –IncludeAllSubFeature -IncludeManagementTools
To list the RDS services installed on the host, use the command:
Get-WindowsFeature -Name RDS* | Where installed
Activating the RDS License Server on Windows Server
In order to issue licenses to RDP clients, your RDS License Server must be activated. To exercise information technology, open the Remote Desktop Licensing Manager (licmgr.exe
), right-click the proper name of your server, and select Activate Server.
The RDS licensing server activation wizard will commencement. Here you lot volition need to select the activation method you lot prefer. If your server is continued to the Internet, it can automatically connect to Microsoft servers and activate the RDS license server. If in that location is no direct Net access from the server, you can activate the server using a web browser or by phone.
Then you must make full in some information virtually your company (some of the fields are required).
It remains to click the Finish push button.
If you lot right-click the server proper name in the console and select Review Configuration, you lot can verify that the RDS License Server is activated and can be used to activate RDSH clients in your domain.
-
This license server is a member of the Last Server License Servers group in Active Directory. This license server will be able to issue RDS Per User CALs to users in the domain, and you lot will be able to track the usage of RDS Per User CALs.
-
This license server is registered as a service connection point (SCP) in Agile Directory Domain Services.
RDS CALs: Types of Remote Desktop Client Access Licenses
Each user or device that connects to Remote Desktop Session hosts must take a client access license (CAL). There are two types of RDS CALs:
- Per-Device CAL – is the permanent license type assigned to a reckoner (device) that connects to the RDS server more than once (when a device is first continued, a temporary license is issued to it). These licenses are non concurrent, i.eastward., if y'all have 10 Per Device licenses, only ten hosts tin connect to your RDS server. The current OVL RDS CAL is called:
WinRmtDsktpSrvcsCAL 2019 SNGL OLV NL Each AP DvcCAL
; - Per-User CAL – is the type of license that allows a user to connect to the RDS server from any number of computers/devices. This type of license is associated with an Agile Directory user and issued non permanently, but for a specific menstruation of time. The license is issued for a menses of 52 to 89 days (random number). The current Open Value license of this type is chosen
WinRmtDsktpSrvcsCAL 2019 SNGL OLV NL Each AP UsrCAL
.If you endeavor to apply RDS 2019 Per User CAL in a workgroup (not in a domain), then the RDSH server volition forcibly ending a user session every lx minutes with a message: "Remote Desktop License Consequence: At that place is a problem with your Remote Desktop license, and your session will be asunder in 60 minutes". Therefore, for RDS servers in a Windows Workgroup environment, you need to use the only device licensing (Per Device RDS CALs).
.
Notation. We should note that the 2016 RDS CAL may exist installed only on a licensing server running Windows Server 2016 or 2019. Installing RDS CALs to the previous Windows Server versions is not supported. Those, yous cannot install 2016 RDS CALs on a Windows Server 2012 R2 licensing host.
When trying to add new RDS CALs 2019 on Windows Server 2016, an mistake volition appear:
RD Licensing Managing director The license lawmaking is not recognized. Ensure that you have entered the correct license code.
Installing RDS CALs on Windows Server 2019/2016
Now yous must install the pack of Remote Desktop client licenses (RDS CAL) you have purchased on the License Server.
Right-click your server in Remote Desktop Licensing Manager and select Install Licenses.
Select the activation method (automated, online, or by phone) and the license program (in our case, it is Enterprise Understanding).
Many enterprise understanding numbers for RDS have already been leaked on the Internet. I retrieve it won't exist a problem to find the numbers (4965437), you lot don't fifty-fifty need to look for rds cracks or activators.
The next steps of the wizard depend on which license program yous have selected. In the instance of an Enterprise Agreement, you must specify its number. If you accept chosen License Pack (Retail Purchase), enter the 25-character product key you got from Microsoft or a partner.
Specify the product version (Windows Server 2019/2016), license type (RDS Per user CAL), and the number of licenses to be installed on the server.
Afterwards that, the server can issue licenses (RDS CAL) to clients.
You can catechumen RDS User CALs to Device CALs (and vice versa) using the Catechumen Licenses menu item in the RD Licensing Manager panel.
If you have run out of free RDS licenses, you can revoke previously issued RDS Device CALs for inactive computers using the post-obit PowerShell script:
$RevokedPCName="lon-bc1-123"
$licensepacks = Go-WmiObject win32_tslicensekeypack | where {($_.keypacktype -ne 0) -and ($_.keypacktype -ne iv) -and ($_.keypacktype -ne 6)}
$licensepacks.TotalLicenses
$TSLicensesAssigned = gwmi win32_tsissuedlicense | where {$_.licensestatus -eq 2}
$RevokePC = $TSLicensesAssigned | ? sIssuedToComputer -EQ $RevokedPCName
$RevokePC.Revoke()
Up to 20% of Per-Device RDS CALs can be revoked. Per-User CALs cannot be revoked.
RDS CAL Usage Reports
In the RDS License Console, you tin generate a license usage report. To do this, select Create Report -> CAL Usage from the server context carte du jour.
However, I prefer to use PowerShell to study RDS CAL usage. The following script will show the remaining number of licenses in all RDS CAL packs:
Import-Module RemoteDesktopServices -ErrorAction Stop
Set-Location -Path 'rds:' -ErrorAction Cease
$licenses = (Get-Particular -Path RDS:\LicenseServer\LicenseKeyPacks\* | Where-Object Proper noun -Like "-Per User-*").Name
$total=0;
$issued=0;
foreach ($license in $licenses) {
$count=(Become-Detail -Path RDS:\LicenseServer\LicenseKeyPacks\$license\TotalLicenses).CurrentValue
$total= $total + $count
$count2=(Get-Item -Path RDS:\LicenseServer\LicenseKeyPacks\$license\IssuedLicensesCount).CurrentValue
$issued= $issued + $count2
}
$available = $total - $issued
Write-Host "Total Licenses available: $available"
You can run this PowerShell script via Zabbix and set up an alert if the remaining number of licenses is less, for example, five.
The following Powershell script volition let yous to generate a Per User CAL Written report:
Import-Module RemoteDesktopServices -ErrorAction Stop
Set-Location -Path 'rds:' -ErrorAction Finish
$path = "C:\Reports\RDS_CAL_Usage.csv"
$fileName = (Invoke-WmiMethod Win32_TSLicenseReport -Name GenerateReportEx).FileName
$fileEntries = (Become-WmiObject Win32_TSLicenseReport | Where-Object FileName -eq $fileName).FetchReportEntries(0,0).ReportEntries
$objArray = @()
foreach($entry in $fileEntries){
$objArray += $entry | select User, ProductVersion, CALType, ExpirationDate
$objArray[-1].User = $objArray[-1].User.Dissever('\') | select -Last 1
$fourth dimension = $objArray[-1].ExpirationDate.Split('.') | select -showtime one
$objArray[-1].ExpirationDate = [datetime]::ParseExact($time, "yyyyMMddHHmmss", $nada)
}
$objArray | Export-Csv -Path $path -Delimiter ',' -NoTypeInformation
How to Remove RDS CALs from an RD License Server?
If you want to move your RDS CAL license packs from one Remote Desktop licensing server to some other, you can remove the installed RDS CAL license pack from the licensing server using PowerShell.
Using the following cmdlet, you can list all the installed RDS CAL packs on the server:
Go-WmiObject Win32_TSLicenseKeyPack|select-object KeyPackId,ProductVersion,TypeAndModel,AvailableLicenses,IssuedLicenses |ft
Notice the KeyPackId value for the RDS CAL package that you want to remove and run the command:
wmic /namespace:\\root\CIMV2 PATH Win32_TSLicenseKeyPack CALL UninstallLicenseKeyPackWithId yourKeyPackId
You can also completely remove all CALs by re-creating the RDS license database. To practise this, cease the Remote Desktop Licensing service:
Terminate-Service TermServLicensing
Rename the file C:\Windows\System32\lserver\TLSLic.edb
to C:\Windows\System32\lserver\TLSLic.edb_bak
and kickoff the service:
Showtime-Service TermServLicensing
After that, all RDS CAL licenses volition exist removed, and you must reactivate them.
Configuring RDS Licenses on RD Session Hosts
Afterward the RDS License Server is activated and being run, yous can reconfigure RD Session Host to obtain CAL licenses from this server. You tin can set the license type and specify the name of the license server from the Server Manager GUI, using PowerShell, or Grouping Policy.
To change the name/address of the licensing server on the RDS host, open Server Manager -> Remote Desktop Services -> Collections. In the upper right carte "Tasks" select "Edit Deployment Properties".
In the deployment properties, go to the RD Licensing tab, select the Remote Desktop licensing mode, and set the RDS license server. Click Add -> Ok.
You can alter the RDS license server address and CAL type using PowerShell:
$obj = gwmi -namespace "Root/CIMV2/TerminalServices" Win32_TerminalServiceSetting
Then specify the license type you demand:
$obj.ChangeMode(4)
Annotation. Enter 4 if the server must apply Per User licensing type, and 2, if it is Per Device.
Then specify the proper name of the RDS License Server:
$obj.SetSpecifiedLicenseServerList("rdslic2016.woshub.com")
And check the current settings:
$obj.GetSpecifiedLicenseServerList()
If yous desire to assign the RDS licensing server parameters via Grouping Policy, you demand to create a new GPO and link it to the OU with RDS servers (or you tin can specify the name of the RDS licensing server using the Local Group Policy Editor – gpedit.msc
). The RD licensing settings are located under the following GPO section: Calculator Configuration -> Policies -> Admin Templates -> Windows Components -> Remote Desktop Services -> Remote Desktop Session Host -> Licensing.
In that location are two Remote Desktop settings that nosotros need to configure:
- Use the specified Remote Desktop license servers – the address of the License Server is set;
- Fix the Remote Desktop licensing mode – select RDS CAL license type.
RDSH hosts use the post-obit network ports to obtain an RDS license from the RDS Licensing server. Make certain that they are not blocked past firewalls (or Windows Defender Firewall):
- TCP/135 – Microsoft RPC;
- UDP/137 – NetBIOS Datagram Service;
- UDP/138 – NetBIOS Name Resolution;
- TCP/139 – NetBIOS Session Service;
- TCP/445 – SMB;
- TCP/49152–65535 – RPC dynamic accost range
Y'all tin check for open ports using the PortQry tool or the Test-NetConnection cmdlet.
Try to check the RD License Server condition and the number of the issued licenses using the Remote Desktop Licensing Diagnoser tool (lsdiag.msc
or Administrative Tools -> Remote Desktop Services -> RD Licensing Diagnoser). RD Licensing Diagnoster can be installed on RDSH servers using Server Manager (Features -> Remote Server Administration Tools -> Role Administration Tools -> Remote Desktop Services Tools -> Remote Desktop Licensing Diagnoser Tools).
If the RDSH server is not configured to use an RDS license server, the post-obit warnings will appear in the Licensing Diagnoser console:
-
Licenses are not available for this Remoter Desktop Session Host server, and RD Licensing Diagnose has identified licensing issues for the RDSH.
-
Number of licenses available for clients: 0
-
The licensing mode for the Remote Desktop Session Host server is non configured.
-
Remote Desktop Session Host server is within its grace flow, but the RD Session Host server has not been configured with whatever license server.
If yous installed RDSH on the Windows Server Evaluation edition, do not forget to catechumen it to the full version according to the guide. Without conversion, RDSH services on such a host volition just work for 120 days, even if y'all target it to an activated RDS license server.
If in that location are no warnings, and you lot see the message "RD Licensing Diagnoser did non identify whatever licensing problems for the Remote Desktop Session Host server", then the RDSH server tin can successfully receive RDS CALs for remote users and/or devices.
Note. In our case, subsequently we specified the new License Server address the post-obit error started to announced on the RDP client: "The remote session was disconnected considering there are no Remote Desktop License Servers available to provide a license". The problem can be solved by removing the L$RTMTIMEBOMB key from the registry on the RDSH server.
Source: http://woshub.com/install-activate-rds-licensing-role-windows-server/
Posted by: fraziertiontems.blogspot.com
0 Response to "How To Install User Cal License In Windows 2016 Server"
Post a Comment