Concepts and Theory of Operations

 Top

The mod_benchmark package is made up of different components (see the diagram below).
Each of them play one of the following roles:

RoleDescription
Collector Collectors are components which are able to gather performance indicators.
There are 2 collectors which can collect 3 different kinds of counters and indicators:

mod_benchmark
  • computes the time needed for Apache to serve the requests (see the BenchmarkEngine directive)
  • collects counters from the Apache Scoreboard (indicators collected are the # of busy servers and the # of ready servers - see the BenchmarkUseScoreBoard directive)
sysstat2
  • computes the System indicators values (average CPU Load, % of use memory and swap, # of sleeping, zombie, waiting and running process - see the BenchmarkWithSysInfo directive
Dispatcher mod_benchmark is an Apache module which purpose is to collect information by itself or from other Collectors and then dispatch them to the Archivers or the Alerters (see below).
Archiver Once the indicator values have been collected, they are dispatched to one or more archiving/logging mechanisms.

There are 3 different archiving facilities (not exclusive):

Apache Log Files Each monitored request can be logged with the collected performance indicators in a Apache Log file (see BenchmarkWithLogInfo directive)
Database Each monitored request can be logged with the collected performance indicators in MySQL, PostgreSQL, Sybase or Oracle Database (see BenchmarkStore directive).
Logging information in Databases is a time-consuming task that may impact the global response time. But the information stored can be used by the PHP/Perl Web based interface to display the statistics.
benchmark_rt The real-time Statistics dump tool can be used to get the performance indicator values and the request processing mean time on a periodical basis. This is much faster than using the Database. (see BenchmarkStatProg directive)
Displayer Statistics and performance indicators can be displayed using either the Web-base interface (only if the data are stored in a Database) either a plug-in such benchmark-larrd.pl used to integrate the package with Big-Brother.

benchmark-larrd.pl works together with benchmark-bf.sh which gets the data computer by benchmark_rt
Alerter The package is shipped with two alert mechanisms (not exclusive):

alerter.sh This small program is given as an sample of the capability for mod_benchmark to call in real-time an external process each time threshold is reached when serving the requests (see the BenchmarkAlertAction and BenchmarkAlertLimit directives).
benchmark-bf.sh If you plan to integrate mod_benchmark with Big-Brother, this script can compute "green", "yellow" or "red" status according to average mean time.

mod_benchmark Architecture Overview


www.trickytools.com