Preface:
The company has developed a website. The estimated maximum number of online users is 30 thousand, and the maximum number of concurrent users is 100. Whether or not the developed website can withstand this pressure and how to ensure that the load of the website is no problem, after research, it is decided as follows:
(1) Server Load balancer and cluster t
Based on the huge network structure, the use of Cluster Server brings a lot of load problems such as traffic. So the relative, load-balanced technology also emerged. Each technology requires product support, so let's now look at one of the F5 load balancers. So first of all, we first introduce the structure of the prod
Load Balancing is built on the existing network structure, it provides a cheap, effective, and transparent method to expand the bandwidth of network devices and servers, increase throughput, enhance network data processing capabilities, and improve network flexibility and av
Introduction to load Balancing clusters
The software that realizes load Balancing cluster is: LVS, keepalived, Nginx, Haproxy and so on. The LVS belong to four layer (network OSI model), Nginx belongs to seven layer, haproxy can be considered as four layer, also can be used as seven layer.
The Keepalived load
/data0/htdocs/www;}Restart Nginx, in the browser input a.com:8080 try to see if you can access. Results can be accessed normallySince the normal access, then we can add the main server to upstream, but the port to change, the following code:Upstream A.com {Server 192.168.5.126:80;Server 192.168.5.27:80;Server 127.0.0.1:8080;}Since the main server can be added here IP192.168.5.149 or 127.0.0.1 can both represent access to themselves.Restart Nginx, and then visit a.com to see if it will be assigne
the main server can be added here IP192.168.5.149 or 127.0.0.1 can both represent access to themselves.Restart Nginx, and then visit a.com to see if it will be assigned to the primary server.OkThe primary server is also able to join the service normally.finallyOne, load balancing is not nginx unique, famous dingding Apache also have, but performance may not be as nginx.Second, more than one server to provide services, but the domain name only resolve
Linux Cluster Server Load balancer lab notes I,Network Topology: II,Virtual Machine Configuration Create three virtual machines on one physical computer.WindowsOperating System, Configuration192.168.1.0The IP address of the CIDR block.Centos5.4. One Server Load balancer
Introduction to load Balancing clusters
Main open source software LVs, keepalived, Haproxy, Nginx, etc.
The LVS belong to 4 layer (network OSI 7 layer model), Nginx belongs to 7 layer, Haproxy can be considered as 4 layer, can also be used as 7 layer
The Keepalived load balancing function is actually the LVS
LVS This 4-tier
;Server 127.0.0.1:8080;}Since the main server can be added here IP192.168.5.149 or 127.0.0.1 can both represent access to themselves.Restart Nginx, and then visit a.com to see if it will be assigned to the primary server.The primary server is also able to join the service normally.At lastOne, load balancing is not nginx unique, famous dingding Apache also have, but performance may not be as nginx.Second, more than one server to provide services, but t
server can be added here IP192.168.5.149 or 127.0.0.1 can both represent access to themselves.Restart Nginx, and then visit a.com to see if it will be assigned to the primary server.The primary server is also able to join the service normally.At lastOne, load balancing is not nginx unique, famous dingding Apache also have, but performance may not be as nginx.Second, more than one server to provide services, but the domain name only resolves to the pr
:80;Server 127.0.0.1:8080;}Since the main server can be added here IP192.168.5.149 or 127.0.0.1 can both represent access to themselves.Restart Nginx, and then visit a.com to see if it will be assigned to the primary server.The primary server is also able to join the service normally.At lastOne, load balancing is not nginx unique, famous dingding Apache also have, but performance may not be as nginx.Second, more than one server to provide services, bu
192.168.16.16;
# Charset koi8-r;Charset UTF-8;# Set access logs for the current virtual hostAccess_log logs/host. access. log main;# If you access/img/*,/js/*,/css/* resources, you can directly obtain the local document without passing squid# If there are many documents, this method is not recommended because the squid cache has better results.# Location ~ ^/(Img | js | css )/{# Root/data3/Html;# Expires 24 h;#}# Enable Server Load
In "high concurrency, massive data, distributed, nosql, cloud computing ...... I believe many of my friends have heard of and even often talked about "clusters and Server Load balancer". But not all of them have the opportunity to really come into use these technologies, not everyone really understands these technical terms. The following is a brief explanation.
Cluster)
A cluster is a loosely coupled mult
requestsDoRouting.First, assume that each request is processed by a computer on the server. If the external request load is evenly distributed to each computer node, the server load balancer will be successful.Without considering the backend technology of distributed databases, the core of server load
bindings on the RS side, do not set 0 even if the VIP bindings are stoppedif [${#VIP [@]}-le 1];thenecho "0" >/proc/sys/net/ipv4/config/lo/arp_ignoreecho "0" >/proc/sys/net/ipv4/config/lo/arp_announceecho "0" >/proc/sys/net/ipv4/config/all/arp_ignoreecho "0" >/proc/sys/net/ipv4/config/all/arp_announceFi
Inspection of the service provided by the RS node itself
Auxiliary exclusion Tool Tcpdump Ping
Load balancing and reverse proxy clusters
code:Upstream A.com {Server 192.168.5.126:80;Server 192.168.5.27:80;Server 127.0.0.1:8080;}Since the main server can be added here IP192.168.5.149 or 127.0.0.1 can both represent access to themselves.Restart Nginx, and then visit a.com to see if it will be assigned to the primary server.The primary server is also able to join the service normally.At lastOne, load balancing is not nginx unique, famous dingding Apache also have, but performance may not
server is also able to join the service normally.At lastOne, load balancing is not nginx unique, famous dingding Apache also have, but performance may not be as nginx.Second, more than one server to provide services, but the domain name only resolves to the primary server, and the real server IP will not be ping can be obtained, add a certain security.Third, the IP in the upstream is not necessarily the intranet, the external
HAProxy for Server Load balancer
HAProxy provides high availability, Server Load balancer, and TCP and HTTP application-based proxy. It supports Virtual Hosts and is a free, fast, and reliable solution. HAProxy is especially suitable for websites with extremely high loads, which usually require session persistence or l
I. LVS principles
1. The full name of LVS is Linux Virtual Server, that is, Linux Virtual Server. It is an open-source project of Dr. Zhang Wenyu from our country. In linux memory 2.6, it has become a part of the kernel. in earlier versions, the kernel needs to be re-compiled ., LVS is mainly used for multi-server load balancing. It works at the network layer to implement high-performance and high-availabil
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.