Server Farm setup
In this section we are going to configure the server farm. For server
farm I understard the logical configuration of the machines, or how
to group them to build cluster. So, a cluster is a group of machines,
used to server resources, and the server farm is all the clusters
configured.
The configuration directive for this feature is serverfarm
Under this tag, you can configure the clusters and the servers that build
them. Inside this tag, you have to configure, at least, one cluster, with
at least one host inside of them.
The configuration parameters for this tag are:
| Option | Description | 
| cluster | 
This is the configuration directive. Under this, you can
configure the hosts that belongs to this cluster.
 
Configuration options
 
name: This is the name of the cluster. 
 
Now, under this configuration directive, you add the hosts
that belongs to this cluster. To do this, you use the 
server directive:
Server 
 
host: This is the name of the host that belongs to
                 this cluster. You can specify their name in
                 the two common ways; dotted notation, or 
                 by name.
port: The port where the service is running
weight: This is the relative weight that has this
                   server in the cluster. For example, if we
                   configure a cluster with three servers,
                   and their weights are 25, 25 and 50, this
                   means that the 25% of the requests go to
                   the first server, 25% of them to the 
                   another server, and the rest to the last
                   one.
 
 | 
 
ServerFarm Sample
<serverfarm>
        <cluster name="cluster1">
            <server host="192.168.0.1" port="80" weight="50" />
            <server host="192.168.0.2" port="8080" weight="50" />
        </cluster>
        <cluster name="cluster2">
            <server host="192.168.0.1" port="8080" weight="100" />
        </cluster>
</serverfarm>