Site Selector works with a domain name server to load balance among a group of servers that uses measurements and weights that are gathered. You can create a site configuration to load balance traffic among a group of servers that are based on the domain name that is used for a client request.
When you set up a subdomain for Site Selector within your DNS environment, ensure that Site Selector has authority over its own subdomain. For example, your company is granted authority over company.com domain, as shown in the Example of a DNS environment figure. Within the company, there are several subdomains. Site Selector would have authority for siteload.company.com, while the DNS servers would still maintain authority for atlanta.company.com and boston.company.com.
siteload.company.com IN NS siteselector.company.com
Where siteselector.company.com is
the host name of the Site Selector server. Equivalent entries must
be made in any other named database files for use by DNS servers.A client submits a request for resolution of a domain name to a name server within its network. Name server forwards the request to the Site Selector server. Site Selector then resolves the domain name to the IP address of one of the servers that is configured under the site name. Site Selector returns the IP address of the selected server to the name server. Name server returns the IP address to the client. (Site Selector acts as a non-recursive (leaf node) name server, and it returns an error if it does not resolve the domain name request.)
Refer to the figure in the Site Selector component topic, which illustrates a site in which Site Selector is used with a DNS system to load balance across local and remote servers.
With Metric Server, Site Selector can monitor the level of activity on a server, detect when a server is the least heavily loaded, and detect a failed server. The load is a measure of how hard the server is working. The system Site Selector administrator controls the type of measurement that is used to measure the load. You can configure Site Selector to suit your environment, considering such factors as frequency of access, the total number of users, and types of access (for example, short queries, long-running queries, or CPU-intensive loads).
The four key functions of Site Selector (name server, manager, Metric Server, and advisors) interact to balance and resolve the incoming requests between servers.
Using DNS-based load balancing requires that caching of name resolutions be disabled. The TTL (time to live) value determines the effectiveness of DNS-based load balancing. TTL determines how long another name server caches the resolved response. Small TTL values allow for subtle changes in the server or network load to be realized more quickly. However, disabling caching requires that clients contact the authoritative name server for every name resolution request, thus potentially increasing the client latency. When you choose a TTL value, carefully consider the impact that disabled-caching has on an environment. Also, be aware that DNS-based load balancing is potentially limited by client-side caching of name resolutions.
Configure TTL by using the sscontrol sitename [add | set] command.
Network proximity is the calculation of each server's nearness to the requesting client. To determine network proximity, the Metric Server agent (which must be present on each load-balanced server) sends a ping to the client IP address and returns the response time to Site Selector. Site Selector uses the proximity response in the load-balancing decision. Site Selector combines the network proximity response value with the weight from the manager to create a combined final weight value for the server.
Use of the network proximity feature with Site Selector is optional.
If set to yes, the Metric Server pings the client to obtain the proximity response time. Name server waits for all Metric Servers to respond or for a timeout to occur. Then, for each server, the name server combines the proximity response time with the weight the manager calculated to create a combined weight value for each server. Site Selector supplies the client with the server IP address with the best combined weight. It is expected that most client name servers have a 5-second timeout. Site Selector tries to respond before that time out is exceeded.
If set to no, a name resolution is provided to the client based on the current manager weights. Then, the Metric Server pings the client to obtain the proximity response time. The name server caches the response time that it receives from the Metric Server. When the client returns for a second request, the name server combines the current manager weight with the cached ping response value for each server to obtain the server with the best combined weight. Site Selector returns the IP address for this server to the client for its second request.
Set network proximity options with the sscontrol sitename [add | set] command. Read the Commands reference topic to learn about Site Selector commands.