Applies To:

Show Versions Show Versions

Manual Chapter: BIG-IP VE and AWS Auto Scaling
Manual Chapter
Table of Contents   |   << Previous Chapter   |   Next Chapter >>

Task List: Auto Scaling BIG-IP VEs in AWS

These tasks are required to use Auto Scaling with BIG-IP® VE.

Step Task Description Details
1 In BIG-IP VE, specify the Auto Scaling group name you will use in AWS BIG-IP VE needs to know the name you plan to use for the AWS Auto Scaling group. You will create a group with this name later in AWS. modify sys autoscale-group autoscale-group-id <groupname>
2 Optional. In BIG-IP VE, set up communication of metrics to AWS BIG-IP VE can send metrics about its health to AWS; you can use these metrics to trigger Auto Scaling. If you want to use AWS metrics instead, you do not need to perform this task. load sys config merge file /usr/share/aws/metrics/aws-cloudwatch-icall-metrics-config
3 In BIG-IP VE, finalize the instance by removing license files You must remove license files specific to this instance of BIG-IP VE. This ensures that new instances created from the image retrieve new licensing from F5. run util finalize-custom-ami
4 In AWS, create an image of the BIG-IP VE instance you want to scale Shut down BIG-IP VE and create an Amazon machine image (AMI). This image will be used to create new instances.  
5 In AWS, create a CloudWatch alarm If you want to use BIG-IP metrics to trigger Auto Scaling, create the CloudWatch alarm before creating the launch configuration. If you want to use AWS metrics, you do not need this task; you can create the alarm while creating the Auto Scaling group.  
6 In AWS, create a launch configuration and Auto Scaling group The name you entered in BIG-IP VE for the Auto Scaling group must be the name of the AWS Auto Scaling group. Each time a new BIG-IP VE instance is created, it is added to the AWS ELB.  

Set AWS Auto Scaling group name in BIG-IP VE

Before you can create an Auto Scaling group for BIG-IP VEs in AWS, you must log in to BIG-IP VE and specify the name that you plan to use for the Auto Scaling group.
  1. Use SSH to log in to the BIG-IP VE as admin.
    Ensure you are at the tmsh prompt, not the bash prompt.
  2. Specify a name for the group.
    Important: If you have other Auto Scaling groups in AWS, ensure that this name is not a duplicate of one that already exists.
    modify sys autoscale-group autoscale-group-id <group_name>
  3. Confirm that the group name was updated successfully.
    list sys autoscale-group
  4. Save the changes.
    save /sys config
Later you will use this name for the Auto Scaling group in AWS.

Make BIG-IP VE communicate metrics to AWS

If you plan to use BIG-IP® metrics to trigger Auto Scaling of BIG-IP VE instances, you must enable a script to send the metrics from BIG-IP VE to AWS.
  1. Use SSH to log in to the BIG-IP VE as admin.
    Ensure you are at the tmsh prompt, not the bash prompt.
  2. Load a script that BIG-IP VE uses to periodically send metrics to AWS.
    load sys config merge file /usr/share/aws/metrics/aws-cloudwatch-icall-metrics-config
  3. Save the changes.
    save /sys config
When the metrics are being sent to AWS, you can see them in the AWS console in the CloudWatch Metrics area.

Note: Communication happens every 10 minutes (600 seconds). To change the interval, run this case-sensitive tmsh command: modify sys icall handler periodic metricUploadHandler interval <number_of_seconds>

Remove licensing and create an AMI

You must remove licensing information from the BIG-IP® VE instance before creating an image of it. This allows new instances to be licensed automatically.
  1. Use SSH to log in to the BIG-IP VE as admin.
    Ensure you are at the tmsh prompt, not the bash prompt.
  2. Remove licensing files.
    run util finalize-custom-ami
  3. In AWS, stop the instance and create an image (AMI) by right-clicking the instance and clicking Image > Create Image.
The AMI will be used to create new BIG-IP VE instances.

Create a CloudWatch alarm for custom BIG-IP metrics

CloudWatch alarms are the triggers that determine when Auto Scaling policies are invoked. To auto scale instances of BIG-IP® VE, you can use AWS metrics or metrics provided by BIG-IP.

If you want to use metrics provided by BIG-IP, complete the following steps.

  1. In the AWS Management Console, from the Services menu, select CloudWatch.
  2. In the Navigation pane, under ALARM, select ALARM.
  3. Click Create Alarm.
  4. In the Custom Metrics area, in the list, click the name of the custom metrics you created earlier.
  5. In the BIGIPMetrics > Metrics with no dimensions list, select the metric you want to trigger the alarm.
  6. Click Next.
  7. Type a name for the alarm and specify where to send the notification.
  8. Click Create Alarm.
Now you can create an Auto Scaling group that uses this alarm to trigger Auto Scaling.

Create a BIG-IP VE launch configuration

Before you can create a BIG-IP® VE launch configuration, you must have an Amazon machine image (AMI) of BIG-IP VE that you want to use as the model for AWS to generate new instances.
A launch configuration is a template that determines how new instances will be launched. To scale BIG-IP VE instances, you must create a launch configuration.
Note: Launch configurations cannot be revised after they are created.
  1. In the AWS Management Console, from the Services menu at the top of the screen, select EC2.
  2. In the Navigation pane, under AUTO SCALING, select Launch Configurations.
  3. Click Create launch configuration.
  4. From the My AMIs list, select the BIG-IP VE image.
  5. Specify settings appropriate for your use.
    Setting Details
    IAM role Select the role you created earlier. This is required, unless you are using an IAM user's keys instead.
    Enable CloudWatch detailed monitoring Select this option.
    Advanced Details > IP Address Type > Assign a public IP address to every instance Select this option. BIG-IP VE must access the internet when it launches, so it can be licensed with F5.
    Advanced Details > User data > As text If you want to use IAM user keys instead of an IAM role, or a different user created the BIG-IP VE image, enter your keys:

    AWS_ACCESS_KEY,<user_access_key>

    AWS_SECRET_KEY,<user_secret_key>

    Note: Keys override roles.
    Configure Security Group Select an existing group that is associated with the VPC.
  6. Click Create launch configuration.

Create a BIG-IP VE Auto Scaling group

Auto Scaling groups are a logical grouping of auto scaled instances. In order for AWS to automatically create BIG-IP VE instances, you must create an Auto Scaling group with CloudWatch alarms that trigger Auto Scaling.
Important: After you complete this task, any changes to the BIG-IP configuration will require you to stop running instances of BIG-IP VE, effectively stopping traffic to your applications. Be sure BIG-IP is configured properly before proceeding.
  1. In the AWS Management Console, from the Services menu at the top of the screen, select EC2.
  2. In the Navigation pane, under AUTO SCALING, select Auto Scaling groups.
  3. Click Create Auto Scaling group and create an Auto Scaling group associated with your BIG-IP VE launch configuration.
  4. Specify settings appropriate for your use.
    Setting Details
    Group name Type the name of the Auto Scaling group you created in tmsh.
    Network and Subnet Select the virtual private cloud (VPC) and its subnet (10.0.0.0/24).
    Receive traffic from Elastic Load Balancer(s) Select this check box and choose your ELB. This ensures that traffic flows from AWS ELB load balancer to the BIG-IP VE instances.
    Use scaling policies to adjust the capacity of this group Set the minimum and maximum number of instances and add an alarm.

    If you want to use BIG-IP metrics to trigger scaling of BIG-IP instances, from the Execute policy when list, select the CloudWatch alarm you created previously.

  5. When done, click Create Auto Scaling group.
BIG-IP VE instances are created based on the alarms you specified.
Table of Contents   |   << Previous Chapter   |   Next Chapter >>

Was this resource helpful in solving your issue?




NOTE: Please do not provide personal information.



Incorrect answer. Please try again: Please enter the words to the right: Please enter the numbers you hear:

Additional Comments (optional)