Deploy Windows Server as an application server

Updated at:

An application server is where you install applications and publish them through the RemoteApp service. Before you perform application O&M by using Bastionhost, you must prepare an application server. This topic uses Windows Server 2019 as an example to describe how to deploy Windows Server as an application server.

Windows Server deployment notes

  • Windows Server 2000 and Windows Server 2003 do not support the RemoteApp service. Choose Windows Server 2016, Windows Server 2019, or Windows Server 2022 instead.

  • The Windows Server can be a physical device or a virtual machine.

  • Application O&M depends on Windows Server Remote Desktop Services. The service has a default trial period of 120 days. After the trial period expires, you must activate Remote Desktop Licensing before you can continue to use the service.

    Warning

    By default, Remote Desktop Services has a free trial period. After the trial period expires, the application O&M feature becomes unavailable. To use the service on a long-term basis, purchase a Client Access License (CAL) from the official Microsoft website, and then activate Remote Desktop Licensing on the application publishing server.

    The following list describes when to use each Client Access License (CAL) type:

    • Per Device CAL: Purchase RDS licenses based on the maximum number of concurrent application O&M connections. Each O&M connection requires one license. This license type applies when the number of users who perform application O&M concurrently is smaller than the total number of O&M engineers. It is the default recommendation because concurrent O&M connections are usually fewer than the total number of O&M engineers.

    • Per User CAL: Purchase RDS licenses based on the number of O&M engineers who need to use application O&M. Each user requires one license. This license type applies when the number of users who perform application O&M concurrently equals the total number of O&M engineers.

Recommended application server configurations

Configuration item

1 to 10 concurrent connections

11 to 20 concurrent connections

21 to 50 concurrent connections

51 to 100 concurrent connections

More than 100 concurrent connections

CPU

4 cores

4 cores

8 cores

8 cores

16 cores

Memory

8 GB

16 GB

16 GB

32 GB

64 GB

System disk

200 GB

200 GB

300 GB

300 GB

500 GB

RemoteApp overview

RemoteApp is a service feature that Microsoft integrated into Windows Server 2008 and later. It lets users access remote desktops and programs through Remote Desktop. Users can use the desktops and applications published on the remote server without installing an operating system or applications on the local client. When you perform application O&M by using Bastionhost, you must log on to the application server and start the client on the server. This process depends on RemoteApp.

Step 1: Create an AD domain

  1. Log on to the Windows Server 2019 server.

    If you use an Elastic Compute Service (ECS) instance, you can connect to the ECS instance in multiple ways. For more information about the connection methods, see Choose a connection method.

  2. Click the image..pngStart icon, select Server Manager, and on the Dashboard page, click Add Roles and Features.

  3. Follow the wizard. Unless otherwise specified, keep the default settings.

    • Installation Type: Select Role-based or feature-based installation.

    • Server Roles: Select Active Directory Domain Services.

    • Features: Select .NET Framework 3.5 Features and .NET Framework 4.7 features.

  4. After the features are installed, restart the server.

Step 2: Promote the server to a domain controller

  1. On the Dashboard page, click Promote this server to a domain controller.

  2. Follow the wizard. Unless otherwise specified, keep the default settings.

    • Deployment Configuration: You can specify any root domain name, such as example.com.

    • Domain Controller Options: Enter a password for Directory Services Restore Mode (DSRM). The password must contain uppercase and lowercase letters, digits, and symbols.

    • DNS Options: Ignore the prompt and click Next.

  3. After the installation is complete, restart the server. After the restart, check whether the server is in the domain.

    On the System Properties page, you can see that Domain is displayed as example.com, which indicates that the server has joined the domain.

Step 3: Install Remote Desktop Services

  1. Log on to the server by using a domain account or the Administrator account.

    If the domain is example.com, the domain account is example. The logon password is the same as the password of the Administrator account.

  2. Click the image..pngStart icon, select Server Manager, and on the Dashboard page, click Add Roles and Features.

  3. Follow the wizard. Unless otherwise specified, keep the default settings.

    • Server Roles: Select Remote Desktop Services.

    • Role Services: Select Remote Desktop Session Host and Remote Desktop Licensing.

      Also make sure that Remote Desktop Web Access is selected.

    • Confirmation: Select Restart the destination server automatically if required.

Step 4: Install the RemoteApp service

  1. Log on to the server by using a domain account or the Administrator account.

    If the domain is example.com, the domain account is example. The logon password is the same as the password of the Administrator account.

  2. Click the image..pngStart icon, select Server Manager, and on the Dashboard page, click Add Roles and Features.

  3. Follow the wizard. Unless otherwise specified, keep the default settings.

    • Installation Type: Select Remote Desktop Services installation.

    • Deployment Type: Select Quick Start.

    • Deployment Scenario: Select Session-based desktop deployment.

    • Server Selection: Select the destination server and click Next.

      If a compatibility error occurs, run the Enable-PSRemoting command in Windows PowerShell (Administrator). After the command runs, return to the server selection page and click Next.

      PS C:\Users\Administrator> Enable-PSRemoting
      WinRM is configured to receive requests on this computer.
      WinRM has been updated for remote management.
      Created a WinRM listener on HTTP://* to accept WS-Man requests to any IP on this machine.
      PS C:\Users\Administrator>
    • Confirmation: Select Restart the destination server automatically if required (R). This action deploys the RD Connection Broker and RD Web Access role services on the server.

    • After the deployment is successful:

      The deployment progress page shows that the Remote Desktop Services role services, session collection, and RemoteApp programs are all complete. The bottom of the page displays the access URL of the RD Web Access site.

Step 5: Adjust application server policies

Adjust the local group policy

  1. Open the Run dialog box and enter gpedit.msc.

  2. On the page, configure the connection settings and session time settings for the Remote Desktop Session Host.

    1. Connection settings

      • Allow users to connect remotely by using Remote Desktop Services: Set the value to Enabled.

      • Limit the number of connections: Set the value to Enabled and enter 999999 as the maximum number of allowed RD connections.

      • Restrict Remote Desktop Services users to a single Remote Desktop Services session: Set the value to Disabled.

      • Allow remote start of unlisted programs: Set the value to Enabled.

    2. Session time settings

      Set time limit for disconnected sessions: Set the value to Enabled and set End a disconnected session to 1 minute.

Hide the IE address bar

  1. Open the Run dialog box and enter gpedit.msc.

  2. On the page, set Enforce full-screen mode to Enabled.

    After you configure this setting, open Internet Explorer to check the result. If the address bar is not displayed, the restriction is in effect.

Disable Windows Firewall

On the page, disable the firewall.

In the Domain network settings, Private network settings, and Public network settings sections, select Turn off Windows Defender Firewall.

Disable IE Enhanced Security Configuration

  1. Click the image..pngStart icon and select Server Manager.

  2. In the left-side navigation pane, click Local Server and then disable IE Enhanced Security Configuration.

Set the RD licensing mode

  1. Click the image..pngStart icon, select Server Manager, and on the Remote Desktop Services page, double-click RD Licensing.

  2. Select the destination server, click Next, and then follow the wizard to complete the remaining steps.

  3. Return to the Remote Desktop Services page and select .

  4. Set the RD licensing mode to Per Device, select the Remote Desktop Licensing server, and then click Apply.

Enable Remote Desktop

  1. On the page, click Allow remote access.

  2. On the Remote tab, select Allow connections to this computer, clear Allow connections only from computers running Remote Desktop with Network Level Authentication (recommended), and then click OK.