How to Set GSLB Algorithms at Both the GSLB Service and GSLB Pool Levels - Two-Level GSLB Pool Member Service Selection
Background
In Avi GSLB, selection of a GSLB pool member service is a two-level process: First select a pool, then select a service. This is supported by two service-level algorithms and three pool-level algorithms. This article shows how to select the algorithms at both levels.
Instructions
In the below example, pressing the TAB key prior to completing the first command reveals the two CLI options introduced with 17.2.3: gslb_service_algorithm_geo
and gslb_service_algorithm_priority
. Once the GSLB service object named gs2
is created, definition of its GSLB pools begins with a single pool named grp1
/, whose first member is located at IP address 1.2.3.4
. After the last save
command, we see the fields that have been set for this bare-bones global service. Notice how the grp1
GSLB pool group has been assigned the GSLB_ALGORITHM_ROUND_ROBIN
algorithm and priority = 10 by default.
Avi CLI
[admin:john-ctlr-1]: > configure gslbservice gs2 algorithm gslb_service_algorithm_
gslb_service_algorithm_geo Use the client (LDNS) source IP to choose the GSLB Pool closest by geographical location
gslb_service_algorithm_priority Pick the GSLB pool with the highest priority.
[admin:john-ctlr-1]: > configure gslbservice gs1 algorithm gslb_service_algorithm_geo domain_names 1.abc.com
New object being created
[admin:john-ctlr-1]: gslbservice> groups name grp1
New object being created
[admin:john-ctlr-1]: gslbservice:groups> members ip 1.2.3.4
New object being created
[admin:john-ctlr-1]: gslbservice:groups:members> save
[admin:john-ctlr-1]: gslbservice:groups> save
[admin:john-ctlr-1]: gslbservice> save
+----------------------------------+--------------------------------------------------+
| Field | Value |
+----------------------------------+--------------------------------------------------+
| uuid | gslbservice-5030d012-c291-4717-8796-40d9cfc3ad1e |
| name | gs1 |
| domain_names[1] | 1.abc.com |
| groups[1] | |
| name | grp1 |
| priority | 10 |
| algorithm | GSLB_ALGORITHM_ROUND_ROBIN |
| members[1] | |
| ip | 1.2.3.4 |
| ratio | 1 |
| enabled | True |
| controller_health_status_enabled | True |
| health_monitor_scope | GSLB_SERVICE_HEALTH_MONITOR_ALL_MEMBERS |
| enabled | True |
| use_edns_client_subnet | True |
| wildcard_match | False |
| site_persistence_enabled | False |
| algorithm | GSLB_SERVICE_ALGORITHM_GEO |
| is_federated | True |
| tenant_ref | admin |
+----------------------------------+--------------------------------------------------+
[admin:john-ctlr-1]: >
Avi UI
In the GSLB service editor there are two fields via which to choose the algorithms that apply at the first (service) and second (pool) levels.
At the first (service) level one has two choices:
At the second (pool) level one has three choices: