Fortinet black logo

Attaching the FortiADC-VM instance to an existing Autoscaling group

Attaching the FortiADC-VM instance to an existing Autoscaling group

You can attach a FortiADC-VM (which can be licensed with PAYG or BYOL) to an existing autoscaling group.

Before you begin:
  • Ensure the FortiADC-VM is in standalone mode.
  • Ensure the image version of the FortiADC-VM is the same as the FortiADC-VMs in the ASG. If the image version is different, you will see the log from AWS CloudWatch or from FortiADC debug log. For details, see [debug].
  • Check the rules of the network security group attached to the FortiADC-VM network interface card to ensure the inbound/outbound rules include the rules of the network security group of the FortiADC-VMs in the ASG.
To attach the FortiADC-VM instance to an existing ASG:
  1. In the AWS console, go to EC2 > Instances and select the FortiADC-VM you want to add to the ASG.
  2. In the FortiADC-VM instance, click the Actions drop-down and select Instance settings > Attach to Auto Scaling Group.
  3. In the Attach to Auto Scaling group page, select the ASG to attach the FortiADC-VM to.
  4. Check the Instance page to see the FortiADC-VM instance is attached to the ASG.

  5. After the FortiADC-VM is added into the ASG, you can see the desired capacity has increased by 1, and the minimum capacity remains the same value. In this case, the scale-in event may be triggered due to the CPU load in average be lower than the set threshold. You can change the minimum capacity or make the new added instance under scale-in protection to prevent from any instances in ASG to be terminated.
  6. Configure the autoscale configuration on FortiADC-VM. If the ASG was previously empty, then configure the FortiADC-VM as the primary node, otherwise, configure it as the secondary.
    If the FortiADC-VM is the primary node, you can get a Callback URL from the launch template.
    1. Configure the FortiADC-VM to autoscaling primary role:
      1. In the AWS console, go to EC2 > Launch Templates and locate the launch template by ResourceGroup tag.
      2. Click the Details > Advanced details tab and check the User data.
        Take note of config-url and replace the API path get-config with complete.
        In the example below, the Callback URL will be https://xxxx.execute-api.us-west-2.amazonaws.com/prod/complete.
      3. Fill in the autoscaling configuration, set the role to primary and enable the status. Then, click Save.
    2. Configure the FortiADC-VM as the autoscaling secondary role.
      1. Take note of the Callback URL from the Primary Cloud Auto Scaling configuration and the port1 interface IP of the primary node.
      2. Fill in the cloud autoscaling configuration and enable the status, then click Save.
      3. Checking from the primary node, you should see this FortiADC-VM is connected. If not, please check debug.
  7. Optionally, you can detach the FortiADC-VM if you do not need it.
    On the AWS console, go to EC2 > Auto Scaling Group and locate the ASG. There, you can select the FortiADC-VM to be detached by clicking Actions > Detach.

    After FortiADC-VM is successfully detached, the status of the autoscale configuration on FortiADC-VM is automatically disabled.

Attaching the FortiADC-VM instance to an existing Autoscaling group

You can attach a FortiADC-VM (which can be licensed with PAYG or BYOL) to an existing autoscaling group.

Before you begin:
  • Ensure the FortiADC-VM is in standalone mode.
  • Ensure the image version of the FortiADC-VM is the same as the FortiADC-VMs in the ASG. If the image version is different, you will see the log from AWS CloudWatch or from FortiADC debug log. For details, see [debug].
  • Check the rules of the network security group attached to the FortiADC-VM network interface card to ensure the inbound/outbound rules include the rules of the network security group of the FortiADC-VMs in the ASG.
To attach the FortiADC-VM instance to an existing ASG:
  1. In the AWS console, go to EC2 > Instances and select the FortiADC-VM you want to add to the ASG.
  2. In the FortiADC-VM instance, click the Actions drop-down and select Instance settings > Attach to Auto Scaling Group.
  3. In the Attach to Auto Scaling group page, select the ASG to attach the FortiADC-VM to.
  4. Check the Instance page to see the FortiADC-VM instance is attached to the ASG.

  5. After the FortiADC-VM is added into the ASG, you can see the desired capacity has increased by 1, and the minimum capacity remains the same value. In this case, the scale-in event may be triggered due to the CPU load in average be lower than the set threshold. You can change the minimum capacity or make the new added instance under scale-in protection to prevent from any instances in ASG to be terminated.
  6. Configure the autoscale configuration on FortiADC-VM. If the ASG was previously empty, then configure the FortiADC-VM as the primary node, otherwise, configure it as the secondary.
    If the FortiADC-VM is the primary node, you can get a Callback URL from the launch template.
    1. Configure the FortiADC-VM to autoscaling primary role:
      1. In the AWS console, go to EC2 > Launch Templates and locate the launch template by ResourceGroup tag.
      2. Click the Details > Advanced details tab and check the User data.
        Take note of config-url and replace the API path get-config with complete.
        In the example below, the Callback URL will be https://xxxx.execute-api.us-west-2.amazonaws.com/prod/complete.
      3. Fill in the autoscaling configuration, set the role to primary and enable the status. Then, click Save.
    2. Configure the FortiADC-VM as the autoscaling secondary role.
      1. Take note of the Callback URL from the Primary Cloud Auto Scaling configuration and the port1 interface IP of the primary node.
      2. Fill in the cloud autoscaling configuration and enable the status, then click Save.
      3. Checking from the primary node, you should see this FortiADC-VM is connected. If not, please check debug.
  7. Optionally, you can detach the FortiADC-VM if you do not need it.
    On the AWS console, go to EC2 > Auto Scaling Group and locate the ASG. There, you can select the FortiADC-VM to be detached by clicking Actions > Detach.

    After FortiADC-VM is successfully detached, the status of the autoscale configuration on FortiADC-VM is automatically disabled.