Load Balancing EasySLB FAQ

Published: 2015-01-19

```html

1.Q: Load balancing EasySLB architecture

  A: Conventional architecture: one scheduler at the front end, three or moreweb processing servers at the back end, and one file server (the file server storesweb and database)

2.Q: Principle of load balancing EasySLB.

A: Our company usesnat mode; the following explainsNAT mode principle in detail

  NAT mode load balancing principle brief introduction

  VS/NAT architecture diagram


1.jpg

 

 

Request process:

When a client accesses a network service throughVirtual IP Address (the virtual service'sIP address), the request packet arrives at the scheduler. The scheduler selects one server from a group of real servers according to the connection scheduling algorithm, rewrites the packet's destination address (Virtual IP Address) to the address of the selected server, rewrites the packet's destination port to the corresponding port of the selected server, and finally sends the modified packet to the selected server. At the same time, the scheduler records this connection in the connectionHash table. When the next packet of this connection arrives, the address and port of the originally selected server can be obtained from the connectionHash table, the same rewrite operation is performed, and the packet is passed to the originally selected server.


Response process:

When a response packet from a real server passes through the scheduler, the scheduler changes the source address and source port of the packet toVirtual IP Address and the corresponding port, then sends the packet to the user.


Summary:

From the request and response processes, it can be analyzed that, LVS'sNAT mode load balancing works at layer4 of theiso network model, not layer7


3. Q: NAT mode load balancing bandwidth allocation

  A: web processing servers and file servers only need1M; the scheduler needs sufficient bandwidth. If it is not enough later, just increase the scheduler's bandwidth.

Principle: NAT mode's back-endweb servers andNFS server, as well as the communication between the scheduler andweb servers, are all internal network communication, which does not consume external network bandwidth, so bandwidth is mainly added to the scheduler.

 

4. Q: How to add a whitelist

A: Just submit the whitelist to the schedulerIP; otherweb servers andnfs servers do not need to add a whitelist

 

5. Q: Besides WEB services on port 80, does load balancing EasySLB support other applications? For example, are HTTPS, SMTP, etc. supported?

  A: It can be used for other purposes. Sinceload balancing works at the network layer,it supports TCP protocol'sHTTP,HTTPS,FTP,SMTP,POP3, etc. UDP protocol's DNS,NTP,ICP, video and audio stream playback protocols, etc.,so it can not only provideweb service load balancing, but also provide load balancing for various common services.

 

6. Q: Does load balancing EasySLB support session persistence

A: Yes, our company's load balancing scheduler will by default schedule clients with the same IP address to the same back-end WEB server, so there is no need to configure session persistence separately.

 

7. Q: Do back-end servers need special settings
  
A: Under normal circumstances, after adding a back-end server to the cluster, the system will perform automatic configuration. If automatic configuration fails (for example, a cloud host opened previously), you need to reconfigure the route. For details, please refer to/faq/list.asp?unid=881


8.Q: How is the load balancing EasySLB service charged

  A: Our company's load balancing EasySLB service is built on an ordinary elastic cloud host, so the required cost is the fee for purchasing the elastic cloud host. Because a general scheduler has low requirements for CPU/memory/disk resources and only has high bandwidth requirements, these resources can use the lowest configuration, as long as sufficient bandwidth is guaranteed. 

Users only need to set up: 1. Set up file sharing by yourself , 2. Create a site on the web server.


Cluster system optimization reminders:

1. If the WEB server is Linux, it is recommended to increase the file descriptor to 655350; the default 4096 may become a bottleneck

2. If the database system uses MYSQL, the innodb storage engine must be used, and the value of innodb_flush_log_trx_commit should be changed to 2




```