The main configuration file is /etc/httpd/conf/httpd.conf. This file is well commented and self-explanatory. It contains quite a large number of settings, but we’ll concentrate on just the few necessary to setup the server.
*Note:
This is one of the most important things to remember. Always retain the copy of the original file so you can easily revert to the default. At the very least, do NOT delete default lines; instead, just comment them out so you’ll be able to see what the original settings read and refer to them.
Server Root:
The top of the directory tree under which the server's configuration, error, and log files are kept.
Listen:
The Listen command tells the Web server what ports to use for incoming connections. By default, port 80 is used, although any one or several can be used. The accepted conventions calls for using port 80 for non-secure web communications (without any encryption of traffic). Secure web communications are normally handled on port 443.
Main Server Configurations:
ServerAdmin:
Your address, where problems with the server should be e-mailed. This address appears on some server-generated pages, such as error documents. e.g. admin@your-domain.com
ServerName:
ServerName gives the name and port that the server uses to identify itself. This can often be determined automatically, but we recommend you specify it explicitly to prevent problems during startup. If your host doesn't have a registered DNS name, enter its IP address here.
Document Root:
DocumentRoot tells you where your web documents (html files, images etc) should be located. It is possible to reference files in other directories using aliases and symbolic links.
ErrorLog:
ErrorLog tells you where the log containing all server errors is located. This file is critical for debugging and solving server misconfiguration problems and for proper traffic shaping. By default, all messages with the value of warning (warn) and higher will be logged.
0 comments:
Post a Comment