Author: the disadvantage of aolinksR-proxy is that when one of the web servers stops running, apache will still forward the request, resulting in a 502 gateway error. 1) configure the polling balancing policy to go to the conf directory of Apache, open the httpd. conf file, and add: Proxy...
Author: aolinks
The disadvantage of R-proxy is that when one of the web servers stops running, apache still forwards the request, resulting in a 502 gateway error.
1) configure a polling balancing policy
Go to the conf directory of Apache, open the httpd. conf file, and add the following content to the end of the file:
ProxyPass/balancer: // proxy/# note that it ends "/"
BalancerMember http: // 192.168.6.37: 6888/
BalancerMember http: // 192.168.6.38: 6888/
2) weight-based balancing policy configuration
ProxyPass/balancer: // proxy/# note that it ends "/"
BalancerMember http: // 192.168.6.37: 6888/loadfactor = 3
BalancerMember http: // 192.168.6.38: 6888/loadfactor = 1
3) configure the server load balancer policy for responding to weight requests
ProxyPass/balancer: // proxy/lbmethod = bytraffic # note that it ends "/"
BalancerMember http: // 192.168.6.37: 6888/loadfactor = 3
BalancerMember http: // 192.168.6.38: 6888/loadfactor = 1
2) load balancing is based on the number of requests as the weight, and (3) load balancing is based on the traffic as the weight, which is the biggest difference.