Centos+nginx Configure load Balancing from scratch, Centosnginx
Understanding of Nginx Load Balancing
Nginx is a lightweight, high-performance webserver, he can mainly do the following
Download Nginx for Windows version
Download Address: http://nginx.org/en/download.html
Open cmd window
CD C:\nginx pointing to Nginx directory
Start Nginx start Nginx
Nginx-s Stop//Stop NginxNginx-s Reload//Reload configur
Bad mud: nginx load balancing, bad mud nginx Load Balancing
This article was sponsored by Xiuyi linfeng and first launched in the dark world.
Today, we will learn about nginx Server
How does the Nginx load balancer do it? In fact, nginx load balancing has a lot of methods can be achieved, the following I will give you a concrete introduction of the Nginx load
After configuring Nginx, when accessing Tomcat, Tomcat displays such as:
From this state can be seen, guess is CSS and JS these files are not loaded.
In addition, access to the pages deployed on the Tomcat project is the same, with different nginx accesses to the project under Tomcat such as:
Through Nginx as a proxy server, access to the page is like this:
Quickly understand the principles and configurations of Nginx load balancing and nginx Load BalancingWhat is Server Load balancer?
When a server has more traffic per unit time, the server is under greater pressure and exceeds its
(round robin), WRR (with weighted rotation), LC (minimum Connection), WLC (minimum weight connection)6, the configuration is complex, dependence on the network is relatively large, high stability.Features of Ngnix:1, work in the network on the 7 layer, can be targeted for HTTP applications to do some diversion strategy, such as for the domain name, directory structure;2, Nginx dependence on the network is relatively small, in theory can ping through
Method One, Nginx polling shunt to achieve load balancing
Prepare for work, 3 servers, or open a virtual machine! I'm just running a virtual machine.IP is: 192.168.1.10 192.168.1.11 192.168.1.12 (Environment installed NGIXN did not do any configuration)3 Server environment Best, I am a VM directly cloned, the environment is absolutely the same! Not the same, I e
the number of VIPs will be more.Nginx can be used as the LVS node machine, one can use Nginx function, the second is the performance of Nginx can be used. Of course, this level can also directly use the function of Squid,squid is weaker than Nginx, performance is also inferior to nginx.Nginx can also be used as a middle-tier agent, this level
the number of VIPs will be more.Nginx can be used as the LVS node machine, one can use Nginx function, the second is the performance of Nginx can be used. Of course, this level can also directly use the function of Squid,squid is weaker than Nginx, performance is also inferior to nginx.Nginx can also be used as a middle-tier agent, this level
Both LVS and nginx can be used as multi-host load solutions. They have advantages and disadvantages. in the production environment, you need to analyze the actual situation and make use of it.
First of all, I would like to remind you that technology is not a cloud, and my cloud is your cloud. At the same time, we should not be too conservative, too confident in the old method and wait for others to help you
Nginx works with IIS to achieve simple load balancing and nginxiis Load BalancingDeploy nginx in linux. This article mainly introduces how to implement load balancing with iis after
command: nginx-t
Of course Nginx load Balancing function is also very strong, and it is generally as a seven-tier load balancing (Application protocol layer). Here is a description of the four common settings that are supporte
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.