Workflow for Setting Up a High Availability Cluster in Alibaba Cloud Platform
Step 1: Deploy a Template in Alibaba Cloud
Deploy this solution throughout the Alibaba Cloud Portal using Terraform:
-
Check Point CloudGuard High Availability BYOL (Bring Your Own License)
How to run Terraform:
-
Each module has its own
README
file that explains how to run the module and where to configure the parameters. -
Parameters are configured in the modules terraform.tfvars file.
-
Open the terraform.tfvars file and fill all relevant input parameters.
You may need to prepare some manual preparation in the Alibaba Cloud Console (VPC, vSwitches, SSH key etc.). -
Open command line in the module's directory and Initialize the module -
Run:terraform init
-
See the terraform plan to be executed:
terraform plan
-
Execute the module deployment plan (shows the plan again and prompts the user to type 'yes' to continue with execution). Run:
terraform apply
|
Notes
|
At least five minutes are needed for the deployment. After the deployment is finished, information is displayed in the deployment terminal, such as the public IP addresses created and the network used for Primary Cluster Synchronization used later in this guide.
Components of the Check Point Solution
The CloudGuard Network Security deployed solution has these components:
-
EIP - conditional creation
-
Route Entry - conditional creation
-
ECS Instance - Gateway Instances
|
Important - No other ECS instances can be deployed in the solution's vSwitch. |
|
Notes about the templates
|
Step 2: Configure Cluster Objects in SmartConsole
To configure objects in SmartConsole:
-
If the Security Management Serveris deployed in Alibaba Cloud Platform and manages a Cluster Member in a different VPC, then modify the Security Management IP object inSmartConsolee to be the public IP of the Management Server.
Click Publish to apply the change. -
Click the Objects menu > New > More > Network Object > Gateways & Servers > Cluster > New Cluster.
-
Select Classic Mode.
The Check Point Installed Gateway Cluster classic window opens.
-
Define the Cluster's general properties:
In the Cluster Name field, enter a name for the Cluster object (as in "Cluster_HA").
In the IPv4 Address field, enter the Cluster IP address (VIP). You can find the Cluster IP address in the Alibaba Cloud Platform portal:
-
Browse to the ECS page.
-
Locate Member A under instances.
-
Use the IP address property.
-
-
Define the Cluster Members:
-
In the Cluster's object left pane, click Cluster Members.
-
Select Member A
-
Click Add > New Cluster Member….
-
-
In the Name field, enter the member's name (in our example: Member_A).
-
In the IPv4 Address field, enter the member's IP address of its management interface (eth1).
-
If the management connects to the Cluster Members over a private IP, enter the private IP of the interface.
-
-
If the management connects to the Cluster Members over a public IP, enter the Elastic IP of the interface.
-
Click Communication….
-
Enter the one-time activation key used in the Terraform Template.
-
Click Initialize.
-
Member B
-
Click Add > New Cluster Member.
-
-
In the Name field, enter a member's name (in our example: Member_B).
-
In the IPv4 Address field, enter the member's IP address of its external interface (eth1)
-
If the management is connecting to the Cluster Members over private IP, enter the private IP of the interface.
-
-
If the management is connecting to the Cluster Members over public IP, enter the Elastic IP of the interface.
-
Click Communication
-
Enter the one-time activation key used in the Terraform Template.
-
Click Initialize.
-
-
Get the Cluster's Topology:
-
In the Cluster's object left pane, click Network Management.
-
Click Get Interfaces > Get Interfaces With Topology.
-
Click eth0, in the Network Type select Private.
-
From the Network eth0 window, click Topology and disable Anti-Spoofing.
-
Click eth1, in the Network Type select Sync.
-
From the Network eth1 window, click Topology and disable Anti-Spoofing.
-
Click eth2, in the Network Type select Private.
-
From the Network eth2 window, click Topology and disable Anti-Spoofing.
-
-
The IPsec VPN blade is automatically enabled. To use the VPN blade, see Step 7: Configure VPN. Otherwise, disable the VPN blade.
-
Verify the settings:
-
To close the window, click OK.
-
Install policy on the Cluster.
-
A few minutes after the applicable Access Control Policy is installed, these changes occur automatically in Alibaba Cloud Platform:
-
In each of the internal vSwitch, an Alibaba Cloud Platform Route routes all outbound traffic (0.0.0.0/0) to the Active member.
|
Notes -
|
Step 3: Set Up Routes on Cluster to the Internal vSwitches
To set up routes on each Cluster member to the internal vSwitches:
-
Connect over SSH to each Member.
-
Log in to Gaia Clish, or Expert mode.
-
Add this route:
-
In Gaia Clish, run these two commands:
set static-route <VPC-IP-address/Prefix> nexthop gateway address <eth2-router-IP-address> on
save config
-
In Expert mode, run this command:
clish -c 'set static-route <VPC-IP-address/Prefix> nexthop gateway address <eth2-router-IP-address> on' -s
Example:
set static-route 10.0.0.0/16 nexthop gateway address 10.0.2.253 on
-
Parameters:
Parameter |
Description |
---|---|
<VPC-IP-address/Prefix> |
Specifies the prefix of the entire VPC. Example: 10.0.0.0/16 |
<eth2-router-IP-address> |
Specifies the unicast IP address on the subnet, to which the eth2 is connected. Example: 10.0.2.253 |
|
Note - If the VPC comprises several non-contiguous address prefixes, repeat the command for each prefix. |
Step 4: Enable Outbound Traffic
-
Enable outbound traffic:
-
From SmartConsole, connect to the Security Management Server.
-
Find the Security Cluster object in the Gateways & Servers tab.
-
Select the NAT tab.
-
Check the Hide internal networks behind the Gateway's external IP check box.
-
Click OK.
-
Install policy.
Note - NAT does not support Connection synchronization during failover. If you configure the Cluster to always hide the internal networks (by selecting to automatically add address translation rules - instead of the option described above) this prevents connection synchronization in additional use cases, such as East-West traffic between internal VPCs.
-
-
Add a custom route table for the new vSwitch you created:
-
Go to Alibaba Cloud ECS console, Route tables > Create Route Table.
-
Select the VPC of the relevant vSwitch.
-
Enter a name and click OK.
-
Select the route table you created > Custom route > Add Route Entry.
-
Set Destination CIDR to 0.0.0.0/0.
-
Set the next hop to ENI > select your Gateway's internal interface (eth1).
-
Go to Associated vSwitch tab > click Associated vSwitch > Select your peer vSwitch.
-
Click OK.
-
Step 5: Create Object LocalGatewayExternal
In SmartConsole, create the Dynamic object called LocalGatewayExternal.
This object represents the private Cluster Member's IP addresses.
-
Click Objects menu > More object types > Network Object > Dynamic Object > New Dynamic Object.
Enter this exact name (case-sensitive, no spaces):
LocalGatewayExternal
-
Click OK.
-
Publish the SmartConsole session.
|
Note - This Dynamic object step is used in Step 7: Configure VPN |
Step 6: Configure Inbound Protection
Overview
-
You need to configure Access Control and NAT rules for North-South inbound traffic.
-
You can configure the Cluster's External IP to listen on the TCP port 443, and forward this traffic to the Active Cluster Member. The Active Cluster Member then inspects the traffic and forward it to the Application server on the TCP port 8084.
-
The Active Cluster Member uses NAT to forward traffic that belongs to the two web applications, to the appropriate web server.
-
NAT rules are defined with the special Dynamic Object.
-
The Dynamic object
LocalGatewayExternal
represents the private IP addresses of the external interface of Member 1 and Member 2.
For more information, see Step 5: Create Object LocalGatewayExternal.
To configure Inbound Protection:
-
Connect with SmartConsole to your Security Management Server.
-
Create a host object to represent the specific host that you want to access through the Internet.
-
Create a new TCP service.
Do the following for each internal port, such as port 8081.
Do these steps:
-
Click the Objects menu > More object types > Service > New TCP.
-
Enter a descriptive name. For example:
http-8081
-
In the Protocol field, select the applicable protocol (such as HTTP or HTTPS).
-
In the Port field, select Customize and enter the port number. For example: 8081
-
Click OK.
-
Configure Access Control and NAT rules for North-South inbound traffic by using the following NAT rules:
Create a NAT rule with these values.
NAT Rule |
Value |
---|---|
Rule No |
1 |
Original Source |
All_Internet (do not use *Any) |
Original Destination |
LocalGatewayExternal |
Original Services |
The service object that represents the internal port |
Translated Source |
Original |
Translated Destination |
The Host object that represents your web server |
Translated Services |
The service object that represents the port on which the Active member listens (for example, HTTP) |
Install On |
*Policy Targets |
About this NAT rule:
-
Matches any traffic that arrives at the CloudGuard Security Gateway on the applicable internal port.
-
Translates the destination IP address to the IP address of the Web Servers.
Step 7: Configure VPN
For more information, see the R81 Quantum Security Management Administration Guide.
To configure a VPN:
-
Create a Network Group object to represent the encryption domain of the Cluster:
-
In SmartConsole, click the Objects menu > Object Explorer.
-
From the top toolbar, select New > Network Group.
-
In the Enter Object Name field, enter the desired name.
-
Click the + icon and select the applicable network objects.
-
Click OK.
-
Close the Object Explorer.
-
-
Edit the Cluster object:
-
In SmartConsole, from the left navigation panel, click Gateways & Servers.
-
Double-click the Cluster object.
The Gateway Cluster Properties window opens.
-
-
Define your Network Group as the encryption domain of the Cluster object:
-
In SmartConsole, from the left navigation panel, click Gateways & Servers.
-
Double-click the Cluster object.
The Gateway Cluster Properties window shows. -
In the Cluster object left tree, click Network Management > VPN Domain.
-
Select Manually defined.
-
In the right corner of this field, click the [...] button and select the Network Group object created in Step 1.
-
-
Configure the VPN community:
-
In the Cluster object left tree, click IPsec VPN.
-
In the section This Security Gateway participates in the following VPN Communities, select the applicable VPN community.
-
-
Configure Geo mode:
-
Go to ClusterXL and VRRP > enable Use Geo mode in a cloud.
-
Click OK to close the Gateway Cluster Properties window and save the changes.
-
-
Configure the VPN Community to use Permanent Tunnels:
-
In SmartConsole, click the Objects menu > Object Explorer.
-
In the left tree, clear all boxes except for VPN Communities.
-
Double-click the VPN community, in which this Cluster object participates.
The VPN Community window opens. -
In the left tree, click Tunnel Management.
-
Select Set Permanent Tunnels.
-
Select the applicable option.
-
To close the VPN Community properties window, click OK.
-
Close the Object Explorer.
-
-
Install the applicable Access Control Policy on the Cluster object.