11.07.2015 Views

Changes to Windows 2008 terminal Server ... - TechNet Blogs

Changes to Windows 2008 terminal Server ... - TechNet Blogs

Changes to Windows 2008 terminal Server ... - TechNet Blogs

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

License Database Files<strong>Changes</strong> <strong>to</strong> database files <strong>to</strong> <strong>Windows</strong> <strong>2008</strong><strong>Windows</strong> <strong>Server</strong> <strong>2008</strong> <strong>Windows</strong> <strong>Server</strong> 2003 Purposeedb.chk edb.chk This is a checkpoint file used <strong>to</strong> determine whichtransactions in the transaction log (edb.log) must stillbe committed <strong>to</strong> the licensing database. This file isupdated each time a transaction is committed <strong>to</strong> diskand is used <strong>to</strong> quickly recover the integrity of thelicensing database if the database was not shut downcorrectly.edb.log edb.log Current transaction log for the Terminal ServiceLicensing database (TLSLic.edb). This file will grow <strong>to</strong> 5MB in size, at which time it will be renamed <strong>to</strong>edbxxxxx.log, starting with edb00001.log andincrementing each time.edbres00001.jrsedbres00002.jrsres1.logres2.logReserve transaction log files that serve as a drive spaceplaceholder. There are two of these created, typically 5MB in size, and are only used in the event the drivehosting the transaction logs runs out of space. Thesefiles are used <strong>to</strong> facilitate a clean shutdown of thedatabase.In <strong>Windows</strong> <strong>Server</strong> 2003, these files were simplyres1.log and res2.log.edbtmp.log --- This is used as a template transaction log file, which isused when the edb.log file reaches 5 MB in size and isrenamed. While edb.log is being renamed, edbtmp.logbegins accumulating new transactions, and is thenrenamed <strong>to</strong> edb.log once the existing edb.log file hasbeen renamed.Once edbtmp.log is renamed <strong>to</strong> edb.log, a new emptyedbtmp.log file will be created. There was no <strong>Windows</strong><strong>Server</strong> 2003 equivalent.TLSLic.edb TLSLic.edb This is the actual Terminal Services Licensing databasefile.tmp.edb tmp.edb This is temporary workspace for processingtransactions.6 | P a g e


<strong>Windows</strong> <strong>2008</strong> Client Access License Support:Operating System Per-User CAL<strong>Windows</strong> <strong>Server</strong><strong>2008</strong><strong>Windows</strong> <strong>Server</strong>2003<strong>Windows</strong> 2000<strong>Server</strong>Per DeviceCALInternet/ExternalConnec<strong>to</strong>rLicenseTemporaryCAL“Built-In” CALX X - X -X X X - -- X X - XGrace Period based on Operating System:The Length of the Grace Period is based on the operating system running on the Terminal<strong>Server</strong>.Operating system running on the <strong>terminal</strong> server<strong>Windows</strong> <strong>Server</strong> <strong>2008</strong>:<strong>Windows</strong> <strong>Server</strong> 2003 R2:<strong>Windows</strong> <strong>Server</strong> 2003:<strong>Windows</strong> 2000:Grace period120 days120 days120 days90 days7 | P a g e


Reviewing Configuration of Terminal License <strong>Server</strong> and Creating PerUser License Usage Report:To create a per user license usage report1. Open TS Licensing Manager (LicMgr.Exe)2. Right-click the license server name for which you want <strong>to</strong> generate the report, and thenselect the "Create Report" and "Per User CAL Usage …" options.8 | P a g e


Managing Reports using WMI Providers:<strong>Windows</strong> <strong>Server</strong> <strong>2008</strong> also provides support for managing Per User usage reports using WMIproviders. Now, an administra<strong>to</strong>r can write a simple script <strong>to</strong> generate a usage report for agiven scope. Within the script, he can take further action based on the reports. For example, ifthe number of issued licenses exceeds the number of installed licenses, the script can send ane-mail <strong>to</strong> the administra<strong>to</strong>r.Reports generated using WMI are displayed in the TS Licensing Manager, and reports deletedusing WMI are also deleted from the TS Licensing Manager.The following WMI classes are used <strong>to</strong> generate reports.Win32_TSLicenseReport:<strong>Windows</strong> <strong>Server</strong> <strong>2008</strong> has a WMI class named "Win32_TSLicenseReport" for managing per userlicense reports.This WMI class provides three different interfaces <strong>to</strong> manage reports:i. GenerateReport: This interface is used for generating per user license usage reports. Reportscan be generated across three different scopes as discussed above. This is a static function.The syntax of the API isuint32 GenerateReport ( [in] uint32 ScopeType,[in] string ScopeValue,[out] string FileName);WhereScopeType: Defines the scope for which the report needs <strong>to</strong> be generated1 -> Domain2 -> Organizational Unit (OU)3 -> All trusted DomainsScopeValue: This is used only when ScopeType is "Organizational Unit (OU)",It should contain the name of the OU for which you want <strong>to</strong> generate the report in the format"OU=OUName"9 | P a g e


Reviewing Configuration of Terminal License <strong>Server</strong>1. Any configuration problems on the Terminal <strong>Server</strong> side e.g.: Terminal <strong>Server</strong> runningout of grace period2. A list of License <strong>Server</strong>s that the Terminal <strong>Server</strong> will contact for licenses. This list willinclude both au<strong>to</strong>-discovered license servers as well as manually configured licenseservers3. For each License <strong>Server</strong> that the Terminal <strong>Server</strong> can contact,a. A list of configuration problems with the License <strong>Server</strong>b. Type and number of CALs issued and available on the serverTotal number of available CALs the Terminal <strong>Server</strong> can get from the contactable License<strong>Server</strong>s.(Licensing Diagnosis: Problems and Resolution provided in the End of the Document)11 | P a g e


12 | P a g e


Improvements <strong>to</strong> License Manager:Improvements <strong>to</strong> the License Manager User Interface <strong>to</strong> easily spot configuration issuesWhen you are setting up a license server in the Domain or Forest mode, you could run in<strong>to</strong>configuration errors. Currently there is no easy way <strong>to</strong> find such errors. With the improvementswe have made <strong>to</strong> License Manager, you will be alerted in the License Manager UI if there areerrors in your configuration. In addition you will also be pointed <strong>to</strong> ways in which you canremedy this situation. Examples of configuration errors that the License Manager will help poin<strong>to</strong>ut are –a. The License <strong>Server</strong> is in the Forest mode but not published in Active Direc<strong>to</strong>ry. Thismeans that the License <strong>Server</strong> will not be au<strong>to</strong>-discoverable.b. The License <strong>Server</strong> has a Group Policy set <strong>to</strong> “Restrict Access <strong>to</strong> specified Terminal<strong>Server</strong>s”. However, the local group “Terminal <strong>Server</strong> Computers” is not present.c. The License <strong>Server</strong> is in Domain mode but not installed on a Domain Controller. Thismeans that the License <strong>Server</strong> will not be au<strong>to</strong>-discoverable.d. The License <strong>Server</strong> is not part of the “Terminal <strong>Server</strong> License <strong>Server</strong>s” group in ActiveDirec<strong>to</strong>ry. This would prevent per-user licensing from working.WMI Providers for Administration:With <strong>Windows</strong> <strong>2008</strong>, we added support for WMI providers for Terminal Services Licensing. Withthe use of these WMI providers, administra<strong>to</strong>rs can now script tasks that were in the pastavailable only through the UI. Some of the capabilities that the WMI providers expose wouldhelp enable support for tasks like periodically moni<strong>to</strong>ring available licenses on the License<strong>Server</strong>, generating license usage reports, querying for various properties of the License <strong>Server</strong>etc.Listed below are examples of the tasks that can be accomplished via WMI –a) Activating, deactivating or reactivating the license serverb) Installing license key-packsc) View details of licenses issued by the License <strong>Server</strong>d) Generate per-user license reportse) View configuration information of the License <strong>Server</strong> (e.g.: Is the license serverinstalled on the Domain Controller? Is the Group Policy <strong>to</strong> prevent upgrades groupenabled on the LS? Etc.)f) Publish or un-publish the License <strong>Server</strong> in Active Direc<strong>to</strong>ryg) Revoke licenses13 | P a g e


Example for revocation of CAL using WMI Providers:<strong>Windows</strong> <strong>Server</strong> <strong>2008</strong> also provides support for revocation of issued CALs using WMI providers.CALs revoked through WMI are reflected in TS Licensing Manager.The following WMI class is used <strong>to</strong> revoke issued CALs:Win32_TSIssuedLicense:<strong>Windows</strong> <strong>Server</strong> <strong>2008</strong> has a WMI class named "Win32_TSIssuedLicense" for managing issuedper device CALs. This WMI class provides the following interface <strong>to</strong> manually revoke issuedCALs:Revoke: This API can be used <strong>to</strong> manually revoke an issued CAL. This is a not a static function.The syntax of the API isuint32 Revoke([out] uint32 RevokableCals,[out] DATETIME NextRevokeAllowedOn );Where,RevokableCals: Number of TS CALs of the same type as the current object that can berevoked.NextRevokeAllowedOn: Date that the administra<strong>to</strong>r can next try <strong>to</strong> revoke licenses. Thisparameter only contains valid data when the Revoke method call has failed because themaximum revoke count has been reached.Manually publishing and Un-Publishing Terminal <strong>Server</strong> license <strong>Server</strong>:Terminal <strong>Server</strong>s au<strong>to</strong>matically discover TS License <strong>Server</strong>s available in a deployment byquerying the Active Direc<strong>to</strong>ry Catalog for a list of license servers. This list is in the "TS-Enterprise-License-<strong>Server</strong>" object in the Catalog <strong>Server</strong>. Typically, License <strong>Server</strong>s in "Forest"discovery mode publish themselves <strong>to</strong> this list during installation. However, this process may gowrong for a variety of reasons, and the publishing step may need <strong>to</strong> be performed manually.Alternatively, when the discovery mode or deployment location of a License <strong>Server</strong> changes, itmay be necessary <strong>to</strong> un-publish the LS from the list. In this post, I want <strong>to</strong> discuss how you canperform these manual operations in <strong>Windows</strong> <strong>Server</strong> 2003 License <strong>Server</strong>.Manually Publishing a License <strong>Server</strong> for Forest Discovery14 | P a g e


Typical problems that cause the failure of publishing the TS License <strong>Server</strong> are:If during the installation of the License <strong>Server</strong>, Active Direc<strong>to</strong>ry was down and theLicense <strong>Server</strong> was not published in the Catalog.If the License <strong>Server</strong> was installed in Forest mode, but without Enterprise Administra<strong>to</strong>rCredentials, it will not be published in the Catalog.In these cases, the License <strong>Server</strong> may need <strong>to</strong> be manually published. You may also have <strong>to</strong>create the TS-Enterprise-License-<strong>Server</strong> object if it does not yet exist in the Catalog <strong>Server</strong>.Publishing a License <strong>Server</strong>We can manually publish the Terminal <strong>Server</strong> License <strong>Server</strong>, using one of the following twomethods,Using "Active Direc<strong>to</strong>ry Sites and Services":1. Open the "Active Direc<strong>to</strong>ry Sites and Services" snapin; Start -> Programs ->Administrative <strong>to</strong>ols -> "Active Direc<strong>to</strong>ry Sites and Services"2. Select the Site in which you wish <strong>to</strong> publish the Terminal <strong>Server</strong> License <strong>Server</strong>3. Open the "TS-Enterprise-License-<strong>Server</strong>" Object. If the "TS-Enterprise-License-<strong>Server</strong>"object is does not exist, you may have <strong>to</strong> create it. See below.4. Under the "Licensing Setting" tab click on the "Change" but<strong>to</strong>n5. Add the License <strong>Server</strong> machine name and click OKUsing ADSI Edit <strong>to</strong>ol:1. Open the ADSI* Edit <strong>to</strong>ol2. Select the "CN=Configuration" node3. Select the "CN=Sites"4. Open the node of the site where you wish <strong>to</strong> publish the License <strong>Server</strong>5. Open the "CN= TS-Enterprise-License-<strong>Server</strong>" Object in the right hand panel of the UI. Ifthe "CN=TS-Enterprise-License-<strong>Server</strong>" Object is not present use "Creating the "TS-Enterprise-License-<strong>Server</strong>" Object in the Catalog" <strong>to</strong> create the "TS-Enterprise-License-<strong>Server</strong>" Object6. Select the "site<strong>Server</strong>" Attribute and click "Edit"7. Give the License <strong>Server</strong> machine name in the LDAP form (for example"CN=LSMachine,CN=Computers,DC=example,DC=com") and click "Add"15 | P a g e


Creating the "TS-Enterprise-License-<strong>Server</strong>" Object in the Catalog1. Open ADSI Edit <strong>to</strong>ol2. Select the "CN=Configuration" node3. Select the "CN=Sites" node4. Open the node of the site where you wish <strong>to</strong> create the "TS-Enterprise-License-<strong>Server</strong>"object. If there is no such node then there is no License <strong>Server</strong> installed in "Enterprisemode" in that particular site5. Action -> New -> Object6. Select the "licensingSiteSettings" class7. Give the Value as "TS-Enterprise-License-<strong>Server</strong>"8. Click FinishManually Un-Publishing a License <strong>Server</strong>Typical scenarios that may require manually un-publishing License <strong>Server</strong>:While the License <strong>Server</strong> was being uninstalled, Active Direc<strong>to</strong>ry was down and License<strong>Server</strong> could not be un-published from the Catalog.If you uninstalled the License <strong>Server</strong>, but without Enterprise Administra<strong>to</strong>r Credentials,in that case also License <strong>Server</strong> won't be Un-Published from the Catalog.If License <strong>Server</strong> machine is being moved from domain <strong>to</strong> workgroup, then License<strong>Server</strong> scope au<strong>to</strong>matically changes <strong>to</strong> workgroup mode. It needs <strong>to</strong> be un-publishedmanually from the Catalog.In all of these cases, the entry that is left behind in the TS-Enterprise-License-<strong>Server</strong> objectwould cause the TS servers <strong>to</strong> still look for the License <strong>Server</strong>, even though the LS server may nolonger be available or may have moved <strong>to</strong> a different network. This may lead problems inlicense discovery and cause the TS servers <strong>to</strong> not find the type of CAL needed for a particularuser. Therefore, it is a good idea <strong>to</strong> keep the list as current as possible by manually unpublishinga removed License server from the list in the TS-Enterprise-License-<strong>Server</strong> object.Un-Publishing a License <strong>Server</strong>We can manually Un-Publish Terminal <strong>Server</strong> License <strong>Server</strong> using ADSI Edit <strong>to</strong>ol.Open ADSI Edit <strong>to</strong>ol*Select the "CN=Configuration" nodeAgain select the "CN=Sites"Open the node of the site, where one wishes <strong>to</strong> publish the License <strong>Server</strong>Open the "CN= TS-Enterprise-License-<strong>Server</strong>" Object in right hand panel of the UISelect "site<strong>Server</strong>" Attribute and click "Edit"Select the License <strong>Server</strong> name under the heading "Value" and click "Remove"16 | P a g e


Licensing Diagnosis: Problems and ResolutionsLicensing Diagnosis is capable of diagnosing potential problems in a typical <strong>terminal</strong> server/license server deployment. Here is the list of the potential problems along with their suggestedresolutions.ISSUES WITH DISCOVERYProblem 1: The <strong>terminal</strong> server has not discovered any license servers. If the grace period forthe <strong>terminal</strong> server has expired, connections <strong>to</strong> the <strong>terminal</strong> server will be denied unless alicense server is configured for the <strong>terminal</strong> server.Resolution 1: Configure a license server for the <strong>terminal</strong> server. If you have an existing licenseserver, use the Terminal Services Configuration <strong>to</strong>ol <strong>to</strong> specify that license server for the<strong>terminal</strong> server. Otherwise, install TS Licensing on a computer on your network.If you have configured a license server for the <strong>terminal</strong> server but the license server does notappear in the list of discovered license servers, use TS Licensing Manager <strong>to</strong> review theconfiguration of the license server. TS Licensing Manager may be launched using the ‘Start TSLicensing manager' action item available in the action pane for Licensing Diagnosis <strong>to</strong>ol.Problem 2: License server is not available. This could be caused by networkconnectivity problems, the Terminal Services Licensing service is s<strong>to</strong>pped on the license server,or TS Licensing is no longer installed on the computer.Resolution 2: Make sure you have network connectivity between the <strong>terminal</strong> server and thelicense server. Also check that the Terminal Services Licensing service is started on the licenseserver. If TS Licensing is no longer installed on the computer, ensure that the license server isnot manually specified and/or is no longer published in Active Direc<strong>to</strong>ry Domain Services.17 | P a g e


ISSUES WITH CREDENTIALSProblem 3: The Terminal Services Configuration <strong>to</strong>ol is running with local account credentials.Licensing Diagnosis will not be able <strong>to</strong> discover domain or forest license servers au<strong>to</strong>maticallyand the Total Number of TS client access licenses available value may be inaccurate.Resolution 3: For best results with Licensing Diagnosis, use the Terminal Services Configuration<strong>to</strong>ol with domain account credentials.Problem 4: To identify possible licensing issues, administra<strong>to</strong>r credentials for license server are required.Resolution 4: Provide administra<strong>to</strong>r credentials for the Terminal Services license server. Toprovide credentials use the ‘Provide Credentials' action item in the action pane for LicensingDiagnosis.ISSUES WITH CONFIGURATIONProblem 5: License server cannot issue TS CALs <strong>to</strong> the <strong>terminal</strong> server becauseof a version incompatibility.Resolution 5: Check that the version of the license server supports issuing TS CALs <strong>to</strong> the<strong>terminal</strong> server. The license server must be running the same (or a more recent) version of theoperating system as the <strong>terminal</strong> server. You might need <strong>to</strong> upgrade your license server <strong>to</strong> anappropriate operating system or install a new license server with the appropriate operatingsystem.Problem 6: License server is not activated.Resolution 6: Use TS Licensing Manager <strong>to</strong> activate and install TS CALs on the license server. TSLicensing manager may be launched using the ‘Start TS Licensing manager' action item availablein the action pane for the Licensing Diagnosis <strong>to</strong>ol.Problem 7: License server cannot issue TS CALs <strong>to</strong> the <strong>terminal</strong> server becausethe "License server security group" Group Policy setting is enabled.Resolution 7: Add the computer account for the <strong>terminal</strong> server <strong>to</strong> the Terminal <strong>Server</strong>Computers group on the license server.Problem 8: The licensing mode for the <strong>terminal</strong> server is not configured.Resolution 8: Set the licensing mode on the <strong>terminal</strong> server <strong>to</strong> either Per User or Per Device byusing Terminal Services Configuration <strong>to</strong>ol. Use TS Licensing Manager <strong>to</strong> install thecorresponding TS CALs on the license server.18 | P a g e


Problem 9: The <strong>terminal</strong> server is in licensing mode, but license server does not have any TS CALsinstalled.Resolution 9: Use TS Licensing Manager <strong>to</strong> install the appropriate TS CALs on the license server.If the license server has installed licenses of the other mode, changing the licensing mode forthe <strong>terminal</strong> server may also resolve the issue. To change the licensing mode, use the TerminalServices Configuration <strong>to</strong>ol.Problem 10: The <strong>terminal</strong> server is in licensing mode, but licenseserver does not have any TSCALs available. (Note: The license server may have CALs installed but these CALs are currentlynot available for issuance.)Resolution 10: Use TS Licensing Manager <strong>to</strong> install the appropriate TS CALs on the licenseserver. TS Licensing manager may be launched using the ‘Start TS Licensing manager' actionitem available in the action pane for Licensing Diagnosis <strong>to</strong>ol.19 | P a g e

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!