DH2i DxEnterprise 21.0 Software: AWS Load Balancer Quick Start Guide

Download the PDF

AWS Load Balancer

This quick start guide describes how to set up and configure a load balancing solution for DxEnterprise running in AWS. Using this guide, the user will create virtual machines and a security group, configure applications, and create and configure an AWS load balancer that will allow access to the resources assigned to the DxEnterprise Vhost.

Prerequisites

  • Access to Amazon Web Services (AWS) with permissions to launch instances, create and modify security groups, and create load balancers.

Create Availability Set and Virtual Machines

  1. Login to the AWS Management Console.
  2. Search for EC2 under AWS Services > Find Services.
  3. On the left of the window, select Instances.
  4. Select Launch Instance at the top of the window.
  5. Select AWS Marketplace on the left of the window.
  6. Search for DxEnterprise using the search bar near the top of the window.
  7. Select one of the DxEnterprise offerings listed in the results.
  8. Create the VM.
    1. Choose an instance type.
      NOTE: SQL Server requires at least 2GB of free RAM.
    2. Select Next: Configure Instance Details at the bottom right of the window.
    3. Select a subnet for the VM. Note the selected subnet for later use.
    4. Select 6. Configure Security Group from the options at the top of the window.
    5. Assign a name and description for the security group.
    6. If desired, modify the SSH rule to allow access from known IP addresses only.
    7. Select Review and Launch at the bottom-right of the window, then Launch.
    8. Create a new key pair or select and existing key pair, then launch the instance.
  9. Repeat steps 8a-c for additional VM(s). Assign the VMs to the same subnet from step 8c of the first VM.
    1. Select 6. Configure Security Group from the options at the top of the window and assign the VM to the existing security group configured during the setup of the first VM.
    2. Select Review and Launch at the bottom-right of the window, then Launch.
    3. Create a new key pair or select and existing key pair, then launch the instance.
  10. The EC2 instances have been created and are initializing. Return to the EC2 landing page by clicking the AWS icon in the top-left corner and searching for EC2 under AWS Services > Find Services.
  11. Edit the security group.
    1. Select Security Groups under Network & Security.
    2. Select the security group from the list, then select Edit inbound rules.
    3. Add a rule to allow all inbound traffic originating from members of the security group and save the rule.
  12. Return to the AWS Console by selecting the AWS icon in the top-left corner.

Configure DxEnterprise and Applications

  1. The application must be installed and DxEnterprise configured before continuing. DH2i provides quick start guides for some applications – such as Microsoft SQL Server – running on physical or virtual machines; hyperlinks for these guides are provided below. Various other DxEnterprise configurations may take advantage of the AWS Load Balancer. After configuring the application, leave the console or DxAdmin window open for the second step.
  2. After configuring DxEnterprise and your application on the VM, add a probe port to the Vhost using DxCli or DxAdmin.
    • For DxAdmin:
    1. Right-click on the Vhost and select Update virtual host.
    2. Select the pencil icon to the right of the Probe Port field, then enter a port number into the field. More than one probe port may be added to the Vhost by separating the ports with a comma.
    3. Note the Vhost IP and probe port for later use. Save the changes by selecting OK at the bottom of the window.
    • For DxCli:
    1. Run the command sudo dxcli set-vhost-ilbports to add a load balancer port to the Vhost.

      Syntax

      dxcli set-vhost-ilbports <vhost> <ilb_ports>

      Parameters

      Name Description Required
      vhost The name of the Vhost. True
      ilb_ports List of ports to use for internal load balancer probing (Comma-separated list for multiples). True

      Example

      sudo dxcli set-vhost-ilbports VHOST1 50000

    2. Run the command sudo dxcli get-vhost to gather the Vhost IP address and verify the load balancer port is correct. Save these two items for later use.

      Syntax

      dxcli get-vhost <vhost>

      Parameters

      Name Description Required
      vhost The name of the Vhost. True

      Example

      sudo dxcli get-vhost VHOST1

  3. After adding the probe port to the Vhost, return to the AWS Management Console for the next section.

Create and Configure the AWS Load Balancer

  1. Search for EC2 under AWS Services > Find Services.
  2. Edit the security group.
    1. Select Security Groups under Network & Security.
    2. Select the security group from the list, then select Edit inbound rules.
    3. Add the following rules:
      • Allow traffic on the application listener port from all VMs in the Vhost using their IP addresses. To find a VMs IP address, select Instances from the left panel and select one of the instances that belong to the Vhost. The IP address will be listed under Private IPs.
      • Allow traffic on the application listener port from the subnet the VMs belong to. To find the correct CIDR for the subnet, select Instances from the left panel, select one of the instances that belong to the Vhost, then select the Subnet ID in the information pane. The CIDR for the subnet will be listed in the subnet information pane.
  3. Under Load Balancing, select Load Balancers.
  4. Create a load balancer and register the target(s).
    1. At the top-left of the window, select Create Load Balancer.
    2. Select Create under Network Load Balancer.
    3. Under basic configuration, assign the load balancer a name and change the scheme to internal.
    4. Under Listeners, change the Load Balancer Port to the Vhost probe port.
    5. Under Availability Zones, select the availability zone and subnet the VMs belong to.
    6. Select Next: Configure Security Settings, then Next: Configure Routing.
    7. Under Target Group, assign a name and set the port to Vhost probe port.
    8. Select Next: Register Targets.
    9. Under Instances, select the instances that belong to the Vhost and select Add to registered. More information on registering targets can be found in the references section at the end of this document.
    10. Select Next: Review, then Create.
  5. AWS will begin provisioning the load balancer and registering the targets. To view the status of the targets, select Load Balancing > Target Groups, then select the Targets tab in the information pane.

References

Download the PDF