Important Directories and Files

Within Apache’s server root are several important directories and symbolic links which are discussed below:

/www/bin - This directory contains the executable programs that power the Apache Web server application.

/www/conf - This directory contains the configuration files for Apache. These files control how Apache operates. The most notable of these configuration files are httpd.conf, defaults.conf, vhosts.conf and mime.types.

/www/logs - This directory contains log files for the Apache application itself. The most important one is the file called error_log, which can be helpful in troubleshooting Apache if you experience problems. The log files in this directory should not be confused with the log files for the individual Web sites that you host on your server. The log files for specific Web sites are found elsewhere.

/www/vhosts - This important directory contains the home directories for each of the Web sites, or virtual hosts, that you host on your server - including the initial one that is set up at the time you order. Each virtual host's home directory is named after the domain name of the site, and it in turn contains a number of important directories:

htdocs - This directory is known as the document root for the virtual host. This is where you should put the Web pages, graphics, and other files that make up the Web site.

logs - The directory contains the log files for the virtual host. There are two log files for a virtual host: access_log and error_log. The access_log keeps track of what pages your visitors are requesting, where they are finding out about your site and other information such as the size of the files transferred. The error_log keeps track of potential problems on your site, such as requested files that cannot be found, or files that your visitors tried to view but could not because they did not have permission to do so.

cgi-bin - Each virtual host has a cgi-bin directory which is generally used to store interactive programs and scripts used as part of the Web site.

/www/icons - In this directory are small graphics files that Apache uses for various things. For example, when Apache creates a listing of the contents of a directory, icons are shown next to file names to indicate the type of files that they are.

/www/libexec - This directory contains the dynamic modules that Apache loads in when started.  These modules add features to Apache that are not present in its core functionality.  

/www/include - This directory contains source code header files for Apache which are used when building or creating your own Apache modules.

/www/man - The man pages for Apache and its related commands are stored in this directory. If you want to view the man page for a program or file related to Apache, it is necessary to use the -M flag to the man command in order to specify that you wish to view the man pages stored here. For example, to view the man page on the htpasswd command, you would type: man -M /www/man htpasswd at the command prompt.

/www/sharedapps - This directory is intended to be used to install applications that you want to make available to all of your virtual hosts. The idea for doing so is to conserve disk space by installing common applications one time instead of multiple times. In doing so however, you lose the ability to customize each application to the specific Web site. At the time your server is created, a Web based mail reader application is installed into this directory and is available to use by pointing your Web browser to http://www.yourdomain.com/postoffice/

/www/cgi-bin - This is actually a symbolic link to the cgi-bin directory of your primary Web site. It is present merely for convenience. For example, if your primary Web site were "acme.com," you could get to the /usr/local/www/vhosts/acme.com/cgi-bin directory by simply typing: cd /www/cgi-bin

/www/htdocs - This is actually a symbolic link to the htdocs directory of your primary Web site. It is present merely for convenience.  For example, if your primary Web site were "acme.com", you could get to the /usr/local/www/vhosts/acme.com/htdocs directory by simply typing: cd /www/htdocs