# 3. HI GIO Auto Scale

## <mark style="color:green;">**Overview**</mark>

This document guides using the **Auto Scale function** on HI GIO CLOUD.

## <mark style="color:green;">**Procedure**</mark>

* The network has IP addresses on a static IP Pool (used for applications **without** HI GIO Load Balancing).
* Load Balancer Pool and Virtual Service (used for applications with HI GIO Load Balancing).
* The vApp template of the VM needs to be scaled.

{% tabs %}
{% tab title="I. Create Scale Group" %}
**Step 1: Log in to HI GIO Portal > Applications > Scale Groups > NEW SCALE GROUP**

<figure><img src="/files/sqrNX5bCgsmoTPVp0rDQ" alt=""><figcaption></figcaption></figure>

**Step 2: In the General Settings:**

* Pick an owner of the Scale Group.
* Pick an Organisation VDC.
* Enter Group Name.
* Number of Min VMs.
* Number of Max VMs.<br>

  <figure><img src="/files/RpZDyKhI4NsZ2MzA9CD5" alt=""><figcaption></figcaption></figure>

**Step 3: In the Application Settings:**

* Select the vApp template of the previously prepared application.
* Pick a Storage Policy.<br>

  <figure><img src="/files/iE9na0QvK3xMZvPfadC3" alt=""><figcaption></figcaption></figure>

  **Step 4: Se**lect **a network** for the scale group in the **Network Settings** section.

  * If you want to manage the load balancer on your own or if there is **no need for a load balancer**, select *I have a fully set-up network*:
    * Pick a Network.
    * Click CREATE GROUP AND ADD RULES.<br>

      <figure><img src="/files/QpFtmMDa98xOYHDEoKJN" alt=""><figcaption></figcaption></figure>

  <div data-gb-custom-block data-tag="hint" data-style="info" class="hint hint-info"><p>Make sure the network has available Static IP Pools.</p></div>

  * If your applications use **HI GIO Load Balancing**, select *I have set-up a Load Balancer* option.
    * Enter Network CIDR.
    * Pick Edge Gateway.
    * Pick Server Pool
    * Click CREATE GROUP AND ADD RULES.<br>

      <figure><img src="/files/cUbUkFgQO6cRiObv9Vs2" alt=""><figcaption></figcaption></figure>

  **Step 5:** Set up Firewall rules depending on the application’s requirements.
  {% endtab %}

{% tab title="II. Create Auto Scaling Rules" %}

<figure><img src="/files/aRedBlEOif1qdFsDVEcE" alt=""><figcaption></figcaption></figure>

**Step 1:** Select Scale Group > Rules > ADD RULE.

**Step 2: In the General tab:**

* **Name:** enter rule name.
* **Number of VMs:** The number of VMs will scale.
* **Behavior:** Select whether the scale group must expand or shrink when the rule takes effect.
  * Grow: scale out.
  * Shink: scale in.
* **Cool down:** Enter a cooldown period in minutes after each auto scale in the group.

{% hint style="warning" %}
**Attention:** The conditions cannot trigger another scaling until the cooldown period expires. The cooldown period resets when any of the rules of the scale group takes effect.
{% endhint %}

**Step 3: In the Conditions tab, Add a condition that triggers the rule.**

* A**vg. Utilization:**
  * CPU usage.
  * memory usage.
* **Condition:**
  * greater or equal to.
  * lower or equal to.
* Amount: in percent.
* **Duration:** The period when the condition must be valid to trigger the rule.

{% hint style="warning" %}
**Attenstion:** An AND operator groups conditions in a rule.

After a condition is met, it might be executed with a delay of **up to 5 minutes.**
{% endhint %}

<figure><img src="/files/tdBRw6C9ve1vKAsdCJHa" alt=""><figcaption></figcaption></figure>
{% endtab %}
{% endtabs %}

### **Reference document**

[Auto Scale Groups](https://docs.vmware.com/en/VMware-Cloud-Director/10.4/VMware-Cloud-Director-Tenant-Portal-Guide/GUID-C179B853-709B-455D-94CA-2D5159D70A49.html)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.higiocloud.vn/compute/3.-hi-gio-auto-scale.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
