Help Center/ Elastic Load Balance/ User Guide/ Listener/ Transfer Client IP Address (Shared Load Balancers)
Updated on 2024-03-19 GMT+08:00

Transfer Client IP Address (Shared Load Balancers)

Scenario

Generally, load balancers use IP addresses in 100.125.0.0/16 to communicate with backend servers. If you want a load balancer to communicate with backend servers using real IP addresses of the clients, you can enable Transfer Client IP Address to pass the IP addresses of the clients to backend servers.

Table 1 lists whether you can enable or disable the transfer client IP address function.

Table 1 Transfer client IP address

Listener Type

Enabling Transfer Client IP Address

Disabling Transfer Client IP Address

TCP and UDP

HTTP and HTTPS

Enabled by default

×

Constraints

  • When you enable or disable the function, if the listener has backend servers associated, traffic to this listener will be interrupted for about 10 seconds. The interruption duration is twice the health check interval configured for the backend server group.
  • If Transfer Client IP Address is enabled, a server cannot serve as both a backend server and a client. If the client and the backend server are using the same server and the Transfer Client IP Address option is enabled, the backend server will think the packet is sent by itself but not from the client and will not return a response packet to the load balancer. As a result, the return traffic will be interrupted.
  • If a backend server has been associated with the listener and health checks are enabled, enabling this function will check the health of the backend server, and traffic to this server will be interrupted for one or two health check intervals.
  • After this function is enabled, unidirectional download or push traffic may be interrupted when backend servers are being migrated. After the backend servers are migrated, retransmit the packets to restore the traffic.

Enabling Transfer Client IP Address

  1. Log in to the management console.
  2. In the upper left corner of the page, click and select the desired region and project.
  3. Hover on in the upper left corner to display Service List and choose Network > Elastic Load Balance.
  4. Locate the load balancer and click its name.
  5. You can use either of the following methods to enable the function:
    • On the Listeners page, locate the listener, and click Edit in the Operation column.
    • Click the name of the target listener. On the Summary tab page, click Edit on the top right corner.
  6. In the displayed dialog box, enable Transfer Client IP Address.
  7. Confirm the configurations and click OK.

After Transfer Client IP Address is enabled, configure security groups, network ACLs, and OS and software security policies so that IP addresses of the clients can access these backend servers.

Disabling Transfer Client IP Address

  1. Log in to the management console.
  2. In the upper left corner of the page, click and select the desired region and project.
  3. Hover on in the upper left corner to display Service List and choose Network > Elastic Load Balance.
  4. Locate the load balancer and click its name.
  5. You can use either of the following methods to disable the function:
    • On the Listeners page, locate the listener, and click Edit in the Operation column.
    • Click the name of the target listener. On the Summary tab page, click Edit on the top right corner.
  6. In the displayed dialog box, disable Transfer Client IP Address.
  7. Confirm the configurations and click OK.

Alternatives for Obtaining the IP Address of the Client

You can obtain the IP address of a client in one of the ways listed in Table 2.

Table 2 Alternatives

Listener Type

Alternatives

TCP and UDP

Configuring the TOA Module

HTTP and HTTPS

Layer 7 Load Balancing