Cloud Computing 13 min read

Introduction to Content Delivery Networks (CDN) and Global Server Load Balancing (GSLB)

This article explains the concepts, principles, functions, and service models of Content Delivery Networks (CDN) and details various Global Server Load Balancing (GSLB) techniques—including DNS‑based, HTTP‑redirect, and IP‑spoofing methods—along with their advantages, disadvantages, and server‑selection strategies.

Architects' Tech Alliance
Architects' Tech Alliance
Architects' Tech Alliance
Introduction to Content Delivery Networks (CDN) and Global Server Load Balancing (GSLB)

CDN Overview

CDN (Content Delivery Network) is an intelligent virtual network built on top of the existing Internet infrastructure. By deploying edge servers worldwide and using load‑balancing, content distribution, and scheduling modules, a CDN delivers content from the nearest server to users, reducing congestion, improving response speed, and increasing hit rates. In simple terms, data is placed on geographically distributed servers and users retrieve it via load‑balancing.

CDN Principle

The core principle is to place many cache servers in regions with high user concentration. Global load‑balancing directs user requests to the nearest healthy cache server, which then directly responds to the request.

Global Load Balancing enables a site with servers in multiple regions to be accessed via a single IP or domain, ensuring users connect to the closest server for the fastest access.

The basic idea is to avoid network bottlenecks and deliver content faster and more stably by routing requests to the nearest node based on traffic, connection status, distance, and response time.

CDN Functions

Key functions include:

Saving backbone bandwidth and reducing bandwidth demand.

Providing server‑side acceleration to prevent overload from high traffic.

Using web‑cache technology to store frequently accessed pages locally, reducing outbound bandwidth and improving response time.

Mitigating uneven site distribution and lowering construction and maintenance costs.

Reducing the impact of traffic spikes and improving network stability.

CDN Service Model

A CDN is a strategically deployed system consisting of distributed storage, load balancing, request redirection, and content management. Content management and global traffic management are the core. By judging user proximity and server load, the CDN efficiently serves user requests. The edge server (also called a surrogate cache) sits one hop away from the user.

The surrogate cache mirrors the origin server in the CDN provider’s data center, allowing the provider to deliver optimal experience to end users who cannot tolerate latency.

Global Server Load Balancing (GSLB)

GSLB performs load balancing across server groups located in different geographic locations. It ensures that a global user can reach the nearest server using a single IP or domain.

Server‑Group Selection

Selection is based on two main factors: proximity and load. Proximity can be evaluated statically (IP‑to‑server mapping) or dynamically (real‑time distance measurement). Load considers overall server‑group load, connection count, average response time, and service quality.

GSLB Implementation Methods

Three common approaches:

DNS round‑robin

HTTP redirect

IP spoofing (triangular routing)

DNS‑Based GSLB

Users resolve the domain name via DNS; the GSLB device may replace the DNS server to return the IP of the optimal server. This method is simple, low‑cost, but can misjudge proximity because it often sees the IP of the user’s local DNS resolver rather than the actual user.

HTTP‑Redirect GSLB

The GSLB device’s IP is set as the domain’s A record. After the user’s HTTP request reaches the GSLB, it selects the best server and issues an HTTP 302 redirect to the chosen server’s IP, allowing the real client IP to be used for accurate proximity decisions. It works only for HTTP traffic.

IP‑Spoofing (Triangular Routing) GSLB

Similar to HTTP redirect but works for any protocol (HTTP, FTP, etc.). The GSLB device rewrites the source IP of the response packet to its own IP, making the client think it communicated directly with the origin server. This adds extra hops and latency, so it is usually a fallback to HTTP‑redirect.

Server‑Group Selection Strategies

Common strategies include:

Geographic or custom regions: map IP prefixes to regions and assign users to healthy sites within the same region.

IP‑address weighting: assign traffic weights to each candidate IP.

Round‑Trip Time (RTT): measure latency to each site. Two modes exist—active RTT (using DNS queries or ICMP) and passive RTT (measuring the time from TCP SYN to TCP ACK). Passive RTT reflects real user experience without generating extra traffic.

Active RTT can be blocked by security policies and adds extra traffic, while passive RTT is more accurate and unobtrusive.

Author: 等不到的口琴 Source: https://www.cnblogs.com/Courage129/p/14363627.html

Note: The original article includes promotional material for a paid “architect technical collection”; that part is omitted from the academic summary.

cloud computingEdge Computingcdnnetwork optimizationContent DeliveryGSLBGlobal Load Balancing
Architects' Tech Alliance
Written by

Architects' Tech Alliance

Sharing project experiences, insights into cutting-edge architectures, focusing on cloud computing, microservices, big data, hyper-convergence, storage, data protection, artificial intelligence, industry practices and solutions.

0 followers
Reader feedback

How this landed with the community

login Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.