

down means that the current server is temporarily not involved in load balancing.In the HTTP Upstream module, you can specify the IP address and port of the back-end server through the server instruction, and you can also set the status of each back-end server in load balancing scheduling.
#Install nginx load balancerr for mac install
If you need to use this scheduling algorithm, you must install the Nginx hash package. Distribute requests according to the hash result of the visited URL, so that each URL is directed to the same back-end server, which can further improve the efficiency of the back-end cache server. If you need to use this scheduling algorithm, you must download the upstream_fair module of Nginx. This algorithm can intelligently perform load balancing based on page size and load time, that is, allocate requests according to the response time of the back-end server, and give priority to the short response time.

Load balancing algorithms that are more intelligent than the above two. Each request is allocated according to the hash result of the visited IP, so that visitors from the same IP regularly access a back-end server, effectively solving the session sharing problem of dynamic web pages. The larger the weight value, the higher the access probability assigned, which is mainly used when the performance of each backend server is uneven. If a certain back-end server goes down, the faulty system will be automatically eliminated, so that user access is not affected. Each request is assigned to different back-end servers one by one in chronological order.
