This document explains how to compile and run flood.
Flood is built around Apache Portable Runtime - specifically apr and apr-util.
Flood has been primarily developed on Linux and Solaris. FreeBSD is also known to work. Since flood is built around APR, any APR-supported platform should work without too much hassle. We expect Win32 would work with some additional magic provided someone has the time and inclination to do so. APR has completed most of the dirty work, but none of the current flood developers use Win32.
The current copy of flood is available via Subversion. Flood also depends on the apr and apr-util packages available from the same Subversion repository.
Note: Flood will automatically detect and configure APR and APR-util if they are in the appropriate subdirectories. If you have an already installed copy of APR and APR-util (such as the ones that come with httpd-2.0 or Subversion), you may specify --with-apr and --with-apr-util at configure-time.
% svn co http://svn.apache.org/repos/asf/httpd/flood/trunk flood % cd flood % svn co http://svn.apache.org/repos/asf/apr/apr/trunk apr % svn co http://svn.apache.org/repos/asf/apr/apr-util/trunk apr-util
Now that you have all of the required modules checked out, you now need to generate the configure scripts and execute them for your platform.
Note: SSL support is not enabled by
default in flood. If you wish to enable SSL support, you must specify
--enable-ssl when configuring flood.
If you attempt to run flood against a https URL without SSL support compiled-in, you will receive an error similar to the following:
%./flood examples/round-robin-ssl.xml open request failed (https://www.modssl.org/example/test.phtml). Error running farmer 'Joe': This function has not been implemented on this platform
--enable-ssl option enables detection of the OpenSSL libraries. If
flood can not automatically detect OpenSSL, you will need to specify
--with-openssl to point at the appropriate installed version of OpenSSL.
--with-capath option points at a directory that contains the
Certificate Authorities ( CA s) for OpenSSL. The default capath is in
%./buildconf %./configure --disable-shared
In this example, APR and apr-util will automatically be built with flood. So, you only need to issue a make in the flood directory.
% make all
By default, flood is a static executable, so the executable is relocatable. There are some example flood profiles in the examples/ directory from CVS.
%./flood examples/round-robin.xml > foo.out
The foo.out file generated above is in a simple easy-to-parse format. There are some included shell and awk scripts in the examples directory that provide some easy mechanisms to extract info from the flood output files.
This should provide a quick and easy way to jumpstart your flood installation. If you have any questions, please email the email@example.com mailing list.