Boa Webserver

Boa is an open-source, small-footprint web server that is suitable for embedded applications. Originally written by Paul Phillips, it is now maintained by Larry Doolittle and Jon Nelson. Boa is a high performance HTTP Server, and we use the version of Boa modified by Axis.

Boa is a single-tasking HTTP server. Boa does not fork a copy of itself or spawn a thread to handle each incoming connection, but rather internally multiplexes the connections. Boa only forks for CGI programs, automatic directory generation, and automatic file gunzipping, each of which must be a separate process. The primary design goals of Boa are speed and security, in the sense of "can't be subverted by a malicious user", not "fine grained access control and encrypted communications".

FastCGI is not supported by boa but a similar concept is supported by a so called "transfer mechanism". The idea is to forward requests to already runnings processes just as for FastCGI, rather than starting processes for each new request. Check boa.conf for more info.

  1. Unpack
  2. Build
    1. (optional) Change the default SERVER_ROOT by setting the #define at the top of src/defines.h
    2. Type ./configure, or if you wish to compile with other compiler, for example:
    3. [root@linux ~]# ./configure CC=arm-linux-gcc --host=arm-linux
    4. If the configure step was successful, type make
    5. Report any errors to the maintainers for resolution, or strike out on your own.

  3. Configure
    1. Choose a server root. For a standard installation, /etc/boa is often used.
    2. Locate the sample configuration file in examples/boa.conf, and copy it to the server root (/etc/boa/boa.conf)
    3. Choose a user and server port under which Boa can run.
    4. The traditional port is 80, and user nobody (create if you need to) is often a good selection for security purposes. If you don't have (or choose not to use) root privileges, you can not use port numbers less than 1024, nor can you switch user id.
    5. Choose locations for log files, CGI programs (if any), and the base of your URL tree.
    6. Make sure to create any leading directories. If you use the ones provided by the, make sure to create /var/log/boa/
    7. Set the location of the mime.types file.
    8. Edit boa.conf according to your choices above (this file documents itself). Read through this file to see what other features you can configure.

  4. Start
  5. Test
  6. Install