Load Balancing Final..

Download Report

Transcript Load Balancing Final..


Load balancing is the process of
distributing a workload evenly
throughout a group or cluster of
computers to maximize throughput.

This means that workload on individual
nodes is reduced, and multiple nodes
work together to complete tasks.

High availability clusters allow systems to
run continuously even if an error occurs
on one ore more nodes.

This works by having multiple redundant
nodes in a cluster, each monitoring
another with Heartbeat to detect
failures, and ready to deploy at any
time.
High availability is implemented in almost
all cluster systems today.
 Most useful in the following systems:

› Critical Databases
› E-commerce Websites
› Network File Sharing

In all of the above systems, any
downtime or loss of data is a major
problem for business or security.

Apache (or Apache 2.0 for this project) is
an open-source, web server software
maintained by an open community of
web developers.

We chose Apache for ease of use and its
readily available packages and support
for our heartbeat and high availability on
our Unix based system.

Our goal for this project was to create a
load balanced, high availability Apache
cluster with the following software:
› Ultra Monkey
› Heartbeat
› Apache 2.0

This was set up on a four-node cluster
with all computers running Ubuntu 8.04





Apache node 1: IP address: 190.111.50.201; Apache document root: /var/www
Apache node 2: IP address: 190.111.50.202; Apache document root: /var/www
Load Balancer node 1: IP address: 190.111.50.203
Load Balancer node 2: IP address: 190.111.50.204
Virtual IP Address: 190.111.50.205 (used for incoming requests)

After installing Ubuntu 8.04 on all of the
nodes, we had to set up the two
Apache nodes:
› Installing the proper packages.
› Setting up the ethernet configurations in
/etc/init.d/network
› Configuring the web page in the proper
directory
› Creating and ensuring redundancy between
the two individual Apache server nodes.

Once the Apache nodes were set up,
we configured the load balancing
nodes with Ultra Monkey.

Most of the issues encountered during
configuration occurred during this step.
Our load balancing system uses the Linux
based project, Ultra Monkey.
 We chose this software as it is freeware,
able to run on any size cluster that is
needed, and able to run on any OS.
 Ultra Monkey also includes the package for
Heartbeat protocol, which sends scheduled
messages through the system and listens for
replies, to check for downed nodes.
 If a node is found to be down, due to lack
of Heartbeat response, the node assumes
the other has failed and takes action.


The following steps were used to
configure load balancing on our nodes:
› Installing proper packages
› Setting up ethernet configurations in
/etc/init.d/network
› Installing and configuring Ultra Monkey
› Setting up Heartbeat
Some of the major issues encountered
during this project involved the Ultra
Monkey configuration.
 Was mainly trial and error during
configuration due to lack of
documentation some places and poor
or incorrect documentation others.
 Did intensive testing and studying to find
the correct commands and protocol for
setting up the system.


A problem which stalled our project for a
long period of time was the firewall.
› Not thought to be an issue at all.
› After working for hours trying to find out why
our setup wasn’t connecting between
nodes, we disabled.
› Project worked perfectly after this.
In order to test our four-node system, we
sequentially cut off machines, both load
balancing nodes and Apache nodes in
order to see if the system would stay up and
online.
 The load balancing service was maintained
through this process, and the secondary
Apache server was able to flawlessly step in
when the other was brought down without
interrupting service.

It’s easy to see how this project is easily
applicable to real world scenarios, as
most companies will implement this
technology for their cluster systems.
 Our setup was for a small cluster, and we
didn’t do much optimization; but with
the customization options available, load
balancing can greatly optimize a
system’s capacity.
