The following are possible reasons:
- Session persistence is enabled
If session persistence is enabled, it will cause traffic imbalance when fewer clients are accessing the Server Load Balancer instance. This is especially common when a small number of clients are used to test the Server Load Balancer instance. For example, session persistence (source-IP-based) is enabled for a TCP listener and a client is used to test the load balancing service.
- Abnormal ECS status
Backend servers with abnormal heath status can also lead to an imbalance especially during stress test. If the health check for a backend ECS instance fails or its health status changes frequently, this will cause an imbalance.
- TCP Keepalive
When some backend ECS instances enable TCP keepalive while some do not, the connections will accumulate on the ECS instances with TCP keepalive enabled, which will cause the imbalance.
- Check whether the weights of backend ECS instances are the same;
- Check if the health check of the backend ECS instances fails or if the health status is unstable in a specified period. Check if the health check is correctly configured with the status code.
- Check if both the WLC scheduling algorithm and session persistence are enabled. If so, change the scheduling algorithm to WRR and session persistence.