Mailing lists
Help: configuring mod_backhand
Configuring mod_backhand is fairly straight forward. If you installed mod_backhand by "patching" the Apache source tree as is recommended, then you have a notable advantage over those who did not. The "patching" process adds the directives into the default httpd.conf file and adds a test cgi-bin script that should give you a basic feel for how things are working.

Otherwise, you have to know about all the directive that mob_backhand understands. Here is how it works (what you need for a basic configuration): Let us set up an environment for this example (ours at CNDS): We have 10 Intel Linux machines that we wish to place on our cluster. The network is (and ths the broadcast address is The web servers IPs are -> sans We like to install out backhand enable apache server with the prefix /var/backhand.

LoadModule backhand_module libexec/ Add the following line before any other AddModule directive, but after ClearModuleList:
AddModule mod_backhand.c
OK, now backhand is loaded into the system. Now we need to tell it how to communicate with child httpd processes and other backhand enabled servers. Add:
<IfModule mod_backhand.c>
# This directorty must be readable and writable by euid of apache (nobody)
#  The mod_backhand-Arriba and the AF_UNIX domain files are stored in here.
    UnixSocketDir /var/backhand/backhand
#    This would be the way to do ethernet broadcast
#    MulticastStats
#    but we choose to use the following IP multicast address with a TTL of 1
#    We want to accept resource information originating from any IP on our
#     network.
OK, now it should be able to share information. We would like to be able to see what the servers personal view of the world (cluster resources) is at any given time, so let's enable the diagnostic handler:
<Location "/backhand/">
    SetHandler backhand-handler
Now, let us enable it for a single directory. The cgi-bin directory on our servers has some really hefty web applications (that really drive the load up). We want to have the cgi-bin requests automatically redirected to the server with the lowest load. Due to the possibility of multiple servers contending for the same resources, we want to have each server only consider a random subset of the servers. Of course, we only want server we have heard from lately. So, inside the <Directory> declaration for your cgi-bin directory we add our Backhand directives.
<Directory "/var/backhand/cgi-bin">
    AllowOverride None
    Options None
    Order allow,deny
    Allow from all
    Backhand byAge
    Backhand byRandom
    Backhand byLogWindow
    Backhand byLoad

Presto! Restart your server and try it out. We have included in the source distribution a same CGI script (that will tell you where you connected to and which site you were redirected to.

We have this site up as Visit:

Copyright © 1999 Theo Schlossnagle. All rights reserved.