11.2.4.9. Setting Server Distribution Method¶
Operation Confirmed Version: | |
---|---|
Citrix Netscaler VPX Version11.0 Build67.12 Standard Edition |
Here, we will see how to set a distribution method of the Load Balancer.
It will determine the method (rule) how to distribute accesses from the clients (users) to multiple servers.
Setting ROUND ROBIN method¶
Load balance method by ROUND ROBIN will be introduced here.
ROUND ROBIN is a distribution method that transfers requests from the clients evenly to each server.
Presumed case for sample setting
Assume that we want to set the distribution method of the Load Balancer to ROUND ROBIN.
Configuration diagram
From the [ Configuration ] menu, move to [ Traffic Management ] → [ Load Balancing ] → [ Virtual Servers ]. The Virtual Servers List screen will be displayed. Select an arbitrary Virtual Server on the Virtual Servers List screen, and click [ Edit ].
The details screen of the Virtual Server will be displayed. From [ Advanced Settings ] in the right side of the screen, click [ Method ].
Click [ Load Balancing Method ] on the Method Edit screen.
On the Method Edit screen, select [ ROUND ROBIN ] from [ Load Balancing Method ] and click [ OK ].
The details screen of the Virtual Server will be displayed. Check that load balancing distribution method set is displayed in the [ Method ] section, and click [ Done ].
The Virtual Server List screen will be displayed. Check that the [ State ] and the [ Effective State ] of the Virtual Server are [ Up ] and that the [ Method ] shows the load balancing distribution method set.
Note
If the Status does not become [ Up ] at once, please wait for a while or update the screen.
Operation check result
When we accessed Web pages, the communication was equally distributed to server 1 and server 2. Therefore, we confirmed that the Load Balancer is distributing the traffic by ROUND ROBIN method.
Virtual webserver1 access log
Virtual webserver2 access log
Setting of LEAST CONNECTION Method¶
Load balance method by LEAST CONNECTION will be introduced here.
LEAST CONNECTION is an distribution method that transfers requests to a server with less number of connections.
It is the default distribution method with Citrix Netscaler VPX.
Presumed case for sample setting
Assume that we want to set the distribution method of the Load Balancer to LEAST CONNECTION.
Configuration diagram
From the [ Configuration ] menu, move to [ Traffic Management ] → [ Load Balancing ] → [ Virtual Servers ]. The Virtual Servers List screen will be displayed. Select an arbitrary Virtual Server on the Virtual Servers List screen, and click [ Edit ].
The details screen of the Virtual Server will be displayed. From [ Advanced Settings ] in the right side of the screen, click [ Method ].
Click [ Load Balancing Method ] on the Method Edit screen.
On the Method Edit screen, select [ LEAST CONNECTION ] from [ Load Balancing Method ] and click [ OK ].
The details screen of the Virtual Server will be displayed. Check that load balancing distribution method set is displayed in the [ Method ] section, and click [ Done ].
The Virtual Server List screen will be displayed. Check that the [ State ] and the [ Effective State ] of the Virtual Server are [ Up ] and that the [ Method ] shows the load balancing distribution method set.
Note
If the Status does not become [ Up ] at once, please wait for a while or update the screen.
Operation check result
Many accesses were generated from the Load Balancer to the Server 1 in advance. The Server 2, in a state of the number of accesses zero, got multiple accesses from the client.
When we accessed Web pages, the communication was distributed only to Server 2 access log. Therefore, we confirmed that the Load Balancer is distributing the traffic by LEAST CONNECTION method.
Communication record was not confirmed in the Virtual Web Server 1 log.
Communication records were confirmed in the Virtual Web Server 2 log.
Setting of SOURCE IP HASH Method¶
Load balance method by SOURCE IP HASH will be introduced here.
SOURCE IP HASH is a distribution method that transfers requests from the clients to servers based on the hash value of the source IP header from the clients.
In this methods, clients using the same IP header will be always transferred to the same server.
Presumed case for sample setting
Assume that we want to set the distribution method of the Load Balancer to SOURCE IP HASH.
Configuration diagram
From the [ Configuration ] menu, move to [ Traffic Management ] → [ Load Balancing ] → [ Virtual Servers ]. The Virtual Servers List screen will be displayed. Select an arbitrary Virtual Server on the Virtual Servers List screen, and click [ Edit ].
The details screen of the Virtual Server will be displayed. From [ Advanced Settings ] in the right side of the screen, click [ Method ].
Click [ Load Balancing Method ] on the Method Edit screen.
On the Method Edit screen, select [ SOURCE IP HASH ] from [ Load Balancing Method ] and click [ OK ].
The details screen of the Virtual Server will be displayed. Check that load balancing distribution method set is displayed in the [ Method ] section, and click [ Done ].
The Virtual Server List screen will be displayed. Check that the [ State ] and the [ Effective State ] of the Virtual Server are [ Up ] and that the [ Method ] shows the load balancing distribution method set.
Note
If the Status does not become [ Up ] at once, please wait for a while or update the screen.
Operation check result
As source IP address from the client does not change, access is fixed to the Server 1 due to the calculation result by hash function. As the communication was not distributed to the Server 2, distribution by SOURCE IP HASH Method is confirmed.
Communication records were confirmed in the Virtual Web Server 1 log.
Communication record was not confirmed in the Virtual Web Server 2 log.