Modification to Apache for www.washington.edu
The UW Technology WWW systems use Apache httpd 1.1 with modifications for the www.washington.edu cluster, which in this document is referred to as UW Technology Apache. These changes include:
Document root path searching
UW Technology Apache has the ability to search multiple directories for documents. Stock Apache allows only one directory to be the Document_Root. This has been enhanced to allow a path of directories, and each will be searched (in the order given) for a document.
When a directory path is defined, UW Technology Apache will apply each document root to the request until it either finds a match or has no more directories to try. If the resulting path is a regular file, no more special processing is done. If it is a directory, however, the files index.html, index.htm, and index.cgi are looked for in that directory, in that order. For example, assuming the document root path is defined as:
/www/uw /www/world
and /www/uw/cambots and /www/world/cambots both exist as directories. The file index.html only exists in /www/world/cambots, but the file image.gif exists in both directories. The following will occur when a client requests /cambots/:
- /www/uw/cambots will be found, but it is a directory which does not contain the files index.html, index.htm, or index.cgi, so processing continues.
- /www/world/cambots is found to be a directory, and the file index.html exists. This is the file returned to the client.
A request for /cambots/image.gif will return /www/uw/cambots/image.gif since that file exists.
Extended Logging
UW Technology Apache logs more information than the stock Apache. In addition to client host, remote username, given user name, time, the HTTP request string, the return code, and the number of bytes transferred, UW Technology Apache will log:
- The user agent, which is the string passed by the browser identifying what browser and version the user is running. Displayed within the request string prepended with
User-Agent=
.
- If a document root directory other than the default one is used, the root which was used is logged within the request string, prepended with
root=
.
- If a
.htreroute
script specifies an alternate filename, that name is logged in the request string prepended with reroute=
.
- The Referer document, prepended with
Referer=
.
- The number of seconds required to do the transfer, starting from when data has started being sent. This is the time taken to only transfer the file requested and does not include the header. This number is logged immediately after the number of bytes sent.
Redirects Issued via Symbolic Links
If you wish to issue a redirect for a file, you can make it a symbolic link to the URL to which a redirect should be issued. For example, if you wish to issue a redirect to http://somehost/somefile.html whenever the file localfile is accessed, you would do:
ln -s http://somehost/somefile.html localfile
Conditional HTML
Conditional HTML (chtml) is not part of the standard Apache distribution.