Appendix D: Set up HA health check based on AWS Network Load Balancer in dual-zone
Step 1: Create and configure your target group
-
Open the Amazon EC2 console.
-
In the navigation pane, under Load Balancing, choose Target Groups.
- Click Create target group and configure the group.
-
Click Next.
-
On the Register targets page, complete the following steps.
This is an optional step to create a target group. However, you must register your targets if you want to test your load balancer and ensure that it is routing traffic to your targets.
-
For Available instances, select all FortiSandbox instances belonging to this HA Cluster.
-
Verify the Ports for the selected instances is 514, or If the health check was created on Port 443, verify the Ports for the selected instances is 443.
-
-
Click Include as pending below, then click Create target group.
Step 2: Create Network load balancer
- On the navigation bar, choose a Region for your load balancer. Be sure to choose the same Region that you used for your FortiSandbox instances.
- In the navigation pane, under Load Balancing, choose Load Balancers.
- Choose Create load balancer and then select the Network Load Balancer.
- For Network Load Balancer, click Create.
Step 3: Configure network load balancer and listener
- Configure the following settings:
- Review your configuration, and click Create load balancer. A few default attributes are applied to your load balancer during creation. You can view and edit them after creating the load balancer
Step 4: Test your load balancer on TCP Port 514
- After you are notified that your load balancer was created successfully, click Close.
- In the navigation pane, under Load Balancing, choose Target Groups.
- Select the newly created target group
- Choose Targets and verify that your instances are ready. If the status of an instance is initial, it is likely because the instance is still in the process of being registered, or it has not passed the minimum number of health checks to be considered healthy. After the status of at least one instance is healthy, you can test your load balancer.
- In the navigation pane, under Load Balancing, choose Load Balancers.
- Select the name of the newly created load balancer to open its details page.
- Copy the DNS name of the load balancer (for example, my-load-balancer-1234567890abcdef.elb.us-east-2.amazonaws.com).
- Telnet the DNS name. For example, telnet my-load-balancer-1234567890abcdef.elb.us-east-2.amazonaws.com 514
Health check for 443 Secure listener settings
To import the certificate:
-
Open the Amazon EC2 console.
- In the navigation pane, under AWS Certificate Manager (ACM), choose Import certificate.
-
Follows the AWS import certificate steps and complete the certificate import.
To configure the network load balancer and listener on port 443:
- Follow the steps in Create and configure your target group. Where applicable:
For Protocol select TCP/TLS.
For Port select 443.
- Follow steps 1-3 in Step 3: Configure network load balancer and listener.
- For Listeners and routing:
- For Protocol, choose TLS.
- For Port, choose 443.
- For Default action, select the target group you created and registered previously.
- For Secure listener settings:
- For Security policy, select the AWS recommended. For example, ELBSecurityPolicy-TLS13-1-2-2021-06 (recommended).
- For Default SSL/TLS certificate, choose From ACM and select the imported certificate.
- For ALPN policy, keep the default settings (None).
- Review your configuration, and click Create load balancer.
To test your load balancer on TLS Port 443:
-
Open the target group details page, wait until all members status changes to healthy.
-
On the details page of the newly created load balancer:
-
Copy the DNS name of the load balancer.
-
Paste the DNS name into the address field of an internet-connected web browser. If everything is working, the browser displays the default page of your server.
For example, https://my-load-balancer-1234567890abcdef.elb.us-east-2.amazonaws.com
-