From 478d6757a8064cfba37c7ec88d928cddb80ecf8d Mon Sep 17 00:00:00 2001 From: Joshua Slive Date: Sat, 27 Jan 2001 23:32:36 +0000 Subject: [PATCH] - Remove documentation on command line options from invoking.html since the man pages are now in the html docs. - Move information on "starting the server" from install.html to a more proper location "invoking.html" - Add a few more details here and there. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87877 13f79535-47bb-0310-9956-ffa450edef68 --- docs/manual/install.html | 78 ----------- docs/manual/install.html.en | 78 ----------- docs/manual/invoking.html | 259 ++++++++++++----------------------- docs/manual/invoking.html.en | 259 ++++++++++++----------------------- 4 files changed, 176 insertions(+), 498 deletions(-) diff --git a/docs/manual/install.html b/docs/manual/install.html index e8aed6807f..be166f3b1e 100644 --- a/docs/manual/install.html +++ b/docs/manual/install.html @@ -183,84 +183,6 @@ of day. So, it's time to investigate setting up NTP or some other time synchronization system on your Unix box, or whatever the equivalent on NT would be. -

Starting and Stopping the Server

- -To start the server, simply run httpd. This will look for -httpd.conf in the location compiled into the code (by -default /usr/local/apache/conf/httpd.conf). If -this file is somewhere else, you can give the real -location with the -f argument. For example: - -
-    /usr/local/apache/httpd -f /usr/local/apache/conf/httpd.conf
-
- -If all goes well this will return to the command prompt almost -immediately. This indicates that the server is now up and running. If -anything goes wrong during the initialization of the server you will -see an error message on the screen. - -If the server started ok, you can now use your browser to -connect to the server and read the documentation. If you are running -the browser on the same machine as the server and using the default -port of 80, a suitable URL to enter into your browser is - -
-    http://localhost/
-
- -

- -Note that when the server starts it will create a number of -child processes to handle the requests. If you started Apache -as the root user, the parent process will continue to run as root -while the children will change to the user as given in the httpd.conf -file. - -

- -If when you run httpd it complained about being unable to -"bind" to an address, then either some other process is already using -the port you have configured Apache to use, or you are running httpd -as a normal user but trying to use a port below 1024 (such as the -default port 80). - -

- -If the server is not running, read the error message displayed -when you run httpd. You should also check the server -error_log for additional information (with the default configuration, -this will be located in the file error_log in the -logs directory). - -

- -If you want your server to continue running after a system reboot, you -should add a call to httpd to your system startup files -(typically rc.local or a file in an -rc.N directory). This will start Apache as root. -Before doing this ensure that your server is properly configured -for security and access restrictions. - -

- -To stop Apache send the parent process a TERM signal. The PID of this -process is written to the file httpd.pid in the -logs directory (unless configured otherwise). Do not -attempt to kill the child processes because they will be renewed by -the parent. A typical command to stop the server is: - -

-    kill -TERM `cat /usr/local/apache/logs/httpd.pid`
-
- -

- -For more information about Apache command line options, configuration -and log files, see Starting Apache. For a -reference guide to all Apache directives supported by the distributed -modules, see the Apache directives. -

Compiling Support Programs

In addition to the main httpd server which is compiled diff --git a/docs/manual/install.html.en b/docs/manual/install.html.en index e8aed6807f..be166f3b1e 100644 --- a/docs/manual/install.html.en +++ b/docs/manual/install.html.en @@ -183,84 +183,6 @@ of day. So, it's time to investigate setting up NTP or some other time synchronization system on your Unix box, or whatever the equivalent on NT would be. -

Starting and Stopping the Server

- -To start the server, simply run httpd. This will look for -httpd.conf in the location compiled into the code (by -default /usr/local/apache/conf/httpd.conf). If -this file is somewhere else, you can give the real -location with the -f argument. For example: - -
-    /usr/local/apache/httpd -f /usr/local/apache/conf/httpd.conf
-
- -If all goes well this will return to the command prompt almost -immediately. This indicates that the server is now up and running. If -anything goes wrong during the initialization of the server you will -see an error message on the screen. - -If the server started ok, you can now use your browser to -connect to the server and read the documentation. If you are running -the browser on the same machine as the server and using the default -port of 80, a suitable URL to enter into your browser is - -
-    http://localhost/
-
- -

- -Note that when the server starts it will create a number of -child processes to handle the requests. If you started Apache -as the root user, the parent process will continue to run as root -while the children will change to the user as given in the httpd.conf -file. - -

- -If when you run httpd it complained about being unable to -"bind" to an address, then either some other process is already using -the port you have configured Apache to use, or you are running httpd -as a normal user but trying to use a port below 1024 (such as the -default port 80). - -

- -If the server is not running, read the error message displayed -when you run httpd. You should also check the server -error_log for additional information (with the default configuration, -this will be located in the file error_log in the -logs directory). - -

- -If you want your server to continue running after a system reboot, you -should add a call to httpd to your system startup files -(typically rc.local or a file in an -rc.N directory). This will start Apache as root. -Before doing this ensure that your server is properly configured -for security and access restrictions. - -

- -To stop Apache send the parent process a TERM signal. The PID of this -process is written to the file httpd.pid in the -logs directory (unless configured otherwise). Do not -attempt to kill the child processes because they will be renewed by -the parent. A typical command to stop the server is: - -

-    kill -TERM `cat /usr/local/apache/logs/httpd.pid`
-
- -

- -For more information about Apache command line options, configuration -and log files, see Starting Apache. For a -reference guide to all Apache directives supported by the distributed -modules, see the Apache directives. -

Compiling Support Programs

In addition to the main httpd server which is compiled diff --git a/docs/manual/invoking.html b/docs/manual/invoking.html index 49746bfcc1..9f42048c62 100644 --- a/docs/manual/invoking.html +++ b/docs/manual/invoking.html @@ -15,185 +15,102 @@

Starting Apache

-

Starting Apache On Windows

+ + + +
+ +

Starting Apache On Windows

On Windows, Apache is normally run as a service on Windows NT, or as a console application on Windows 95. For details, see running Apache for Windows.

-

Starting Apache on Unix

+

Starting Apache on Unix

-

On Unix, the httpd program is run as a daemon -which executes continuously in the background to handle requests. -A shell script called apachectl is provided which -can be used to control the daemon process. This shell script -can often be used as an init script to start httpd -on system boot, or it can be called directly with the options -listed below.

+

On Unix, the httpd program is run +as a daemon which executes continuously in the background to handle +requests.

If the Port specified in the -configuration file is the default of 80, then it is necessary to have -root privileges in order to start apache. If Apache will not start -and no error messages are printed to the console, be sure to check the -ErrorLog for a report of -the problem. See also the debugging instructions outlined in -the Apache FAQ.

- -

apachectl Command Line Options

- -
- -
start
Start httpd. If -additional command line options need to be passed to -httpd (see below), then the HTTPD variable -at the top of the apachectl script should be edited to -include them.
- -
stop
-
Stop httpd by issuing the kill signal to the -parent httpd process, whose process ID is contained -in the file pointed to by the -PidFile directive.
- -
restart
-
Restart httpd if it is running by sending a -SIGHUP -signal to the parent process. If the server is not running, then -it will be started. apachectl will refuse to -restart the server if there is a syntax error in the configuration -files (see configtest below).
- -
graceful
Restart httpd if it is -running by sending a SIGWINCH signal to the parent -process. This type of restart is less disruptive to current clients. -If the server is not running, then it will be -started. apachectl will refuse to restart the server if -there is a syntax error in the configuration files.
- -
fullstatus
-
Show a screen indicating the status of the Apache processes. -This option requires the presence of lynx, and -for mod_status to be enabled.
- -
status
-
A shorter form of the fullstatus display. -This option requires the presence of lynx, and -for mod_status to be enabled.
- -
configtest
-
Do a syntax test of the Apache configuration files. See -the httpd -t command line option below.
-
help
-
Show a help screen.
- -
- -

For additional information on the effects of the various -apachectl options, see the documentation on stopping and restarting Apache.

- -

httpd Command Line Options

-The following options are recognized on the httpd command line: -
- -
-d directory -
Set the initial value for the -ServerRoot variable to -directory. This can be overridden by the ServerRoot command -in the configuration file. The default is -/usr/local/apache on Unix, /apache on -Windows and /os2httpd on OS/2. - -
-D name -
Define a name for use in in -IfDefine directives. -This option can be used to optionally enable certain functionality in the -configuration file, or to use a common configuration for -several independent hosts, where host specific information is enclosed in -<IfDefine> sections. - -
-f file -
Execute the commands in the file on startup. If -config does not begin with a /, then it is taken to be a -path relative to the ServerRoot. The -default is conf/httpd.conf. - -
-C "directive" -
Process the given apache "directive" (just as if it had been part -of a configuration file) before actually reading the -regular configuration files. - -
-c "directive" -
Process the given apache "directive" after reading -all the regular configuration files. - -
-v -
Print the version of httpd and its build date, and then exit. - -
-V -
Print the base version of httpd, its -build date, and a list of compile time settings which influence the -behavior and performance of the apache server (e.g., --DUSE_MMAP_FILES), -then exit. - -
-L -
Give a list of directives together with expected arguments and places -where the directive is valid, then exit. - -
-l -
Give a list of all modules compiled into the server, then exit. - -
-h -
Print a list of the httpd command line options, then exit. - -
-t -
Test the configuration file syntax -(i.e., read all configuration files and interpret them) but -do not start the server. If the configuration contains errors, display -an error message and exit with a non-zero exit status, otherwise -display "Syntax OK" and terminate with a zero exit status. This -command checks to see if all DocumentRoot entries exist and are -directories. For sites with many vhosts, this is expensive; consider -the -T command instead.
- -To check and print a summary of the current virtual host settings, -use -t -D DUMP_VHOSTS.
- -
-T -
Test the configuration file syntax (i.e., read all configuration files -and interpret them) but do not start the server. If the configuration contains -errors, display an error message and exit with a non-zero exit status, -otherwise display "Syntax OK" and terminate with a zero exit status. This -command does not perform any checking of the DocumentRoot entries. - -
-R directory
-
If Apache is compiled with SHARED_CORE, then this -directive can be used to specify an alternate location for shared -object files.
- -
- -

When Apache is used under Windows, the following additional -command line options are available.

- -
- -
-n name
-
Set service name and use its ServerConfigFile.
- -
-k option -
Signal Apache to restart or shutdown. option -is one of "shutdown" or "restart". - -
-i
-
Install an Apache service
- -
-u
-
Uninstall an Apache Service
- -
- +configuration file is the default of 80 (or any other port below +1024), then it is necessary to have root privileges in order to start +apache, so that it can bind to this privileged port. Once the server +has started and performed a few preliminary activities such as opening +its log files, it will launch several child processes which +do the work of listening for and answering requests from clients. The +main httpd process continues to run as the root user, but +the child processes run as a less privileged user. This is controlled +by the selected Multi-Processing Module.

+ +

The first thing that httpd does when it is invoked is +to locate and read the configuration +file httpd.conf. The location of this file is set at +compile-time, but it is possible to specify its location at run time +using the -f command-line option as in

+
/usr/local/apache/bin/httpd -f +/usr/local/apache/conf/httpd.conf
+ +

As an alternative to invoking the httpd binary +directly, a shell script called apachectl is provided which can be +used to control the daemon process with simple commands such as +apachectl start and apachectl stop.

+ +

If all goes well during startup, the server will detach from the +terminal and the command prompt will return almost immediately. +This indicates that the server is up and running. You can then +use your browser to connect to the server and view the test +page in the DocumentRoot +directory and the local copy of the documentation linked from +that page.

+ +

Errors During Start-up

+ +

If Apache suffers a fatal problem during startup, it will write a +message describing the problem either to the console or to the ErrorLog before exiting. One of the +most common error messages is "Unable to bind to Port +...". This message is usually caused by either:

+ +

For further trouble-shooting instructions, consult the Apache FAQ.

+ +

Starting at Boot-Time

+ +

If you want your server to continue running after a system reboot, +you should add a call to httpd or apachectl +to your system startup files (typically rc.local or a +file in an rc.N directory). This will start Apache as +root. Before doing this ensure that your server is properly configured +for security and access restrictions. The apachectl +script is designed so that it can often be linked directly as an init +script, but be sure to check the exact requirements of your system.

+ +

Additional Information

+ +

Additional information about the command-line options of httpd and apachectl as well as other support +programs included with the server is available on the Server and Supporting Programs page. There is +also documentation on all the modules included with +the Apache distribution and the directives that they provide.

diff --git a/docs/manual/invoking.html.en b/docs/manual/invoking.html.en index 49746bfcc1..9f42048c62 100644 --- a/docs/manual/invoking.html.en +++ b/docs/manual/invoking.html.en @@ -15,185 +15,102 @@

Starting Apache

-

Starting Apache On Windows

+ + + +
+ +

Starting Apache On Windows

On Windows, Apache is normally run as a service on Windows NT, or as a console application on Windows 95. For details, see running Apache for Windows.

-

Starting Apache on Unix

+

Starting Apache on Unix

-

On Unix, the httpd program is run as a daemon -which executes continuously in the background to handle requests. -A shell script called apachectl is provided which -can be used to control the daemon process. This shell script -can often be used as an init script to start httpd -on system boot, or it can be called directly with the options -listed below.

+

On Unix, the httpd program is run +as a daemon which executes continuously in the background to handle +requests.

If the Port specified in the -configuration file is the default of 80, then it is necessary to have -root privileges in order to start apache. If Apache will not start -and no error messages are printed to the console, be sure to check the -ErrorLog for a report of -the problem. See also the debugging instructions outlined in -the Apache FAQ.

- -

apachectl Command Line Options

- -
- -
start
Start httpd. If -additional command line options need to be passed to -httpd (see below), then the HTTPD variable -at the top of the apachectl script should be edited to -include them.
- -
stop
-
Stop httpd by issuing the kill signal to the -parent httpd process, whose process ID is contained -in the file pointed to by the -PidFile directive.
- -
restart
-
Restart httpd if it is running by sending a -SIGHUP -signal to the parent process. If the server is not running, then -it will be started. apachectl will refuse to -restart the server if there is a syntax error in the configuration -files (see configtest below).
- -
graceful
Restart httpd if it is -running by sending a SIGWINCH signal to the parent -process. This type of restart is less disruptive to current clients. -If the server is not running, then it will be -started. apachectl will refuse to restart the server if -there is a syntax error in the configuration files.
- -
fullstatus
-
Show a screen indicating the status of the Apache processes. -This option requires the presence of lynx, and -for mod_status to be enabled.
- -
status
-
A shorter form of the fullstatus display. -This option requires the presence of lynx, and -for mod_status to be enabled.
- -
configtest
-
Do a syntax test of the Apache configuration files. See -the httpd -t command line option below.
-
help
-
Show a help screen.
- -
- -

For additional information on the effects of the various -apachectl options, see the documentation on stopping and restarting Apache.

- -

httpd Command Line Options

-The following options are recognized on the httpd command line: -
- -
-d directory -
Set the initial value for the -ServerRoot variable to -directory. This can be overridden by the ServerRoot command -in the configuration file. The default is -/usr/local/apache on Unix, /apache on -Windows and /os2httpd on OS/2. - -
-D name -
Define a name for use in in -IfDefine directives. -This option can be used to optionally enable certain functionality in the -configuration file, or to use a common configuration for -several independent hosts, where host specific information is enclosed in -<IfDefine> sections. - -
-f file -
Execute the commands in the file on startup. If -config does not begin with a /, then it is taken to be a -path relative to the ServerRoot. The -default is conf/httpd.conf. - -
-C "directive" -
Process the given apache "directive" (just as if it had been part -of a configuration file) before actually reading the -regular configuration files. - -
-c "directive" -
Process the given apache "directive" after reading -all the regular configuration files. - -
-v -
Print the version of httpd and its build date, and then exit. - -
-V -
Print the base version of httpd, its -build date, and a list of compile time settings which influence the -behavior and performance of the apache server (e.g., --DUSE_MMAP_FILES), -then exit. - -
-L -
Give a list of directives together with expected arguments and places -where the directive is valid, then exit. - -
-l -
Give a list of all modules compiled into the server, then exit. - -
-h -
Print a list of the httpd command line options, then exit. - -
-t -
Test the configuration file syntax -(i.e., read all configuration files and interpret them) but -do not start the server. If the configuration contains errors, display -an error message and exit with a non-zero exit status, otherwise -display "Syntax OK" and terminate with a zero exit status. This -command checks to see if all DocumentRoot entries exist and are -directories. For sites with many vhosts, this is expensive; consider -the -T command instead.
- -To check and print a summary of the current virtual host settings, -use -t -D DUMP_VHOSTS.
- -
-T -
Test the configuration file syntax (i.e., read all configuration files -and interpret them) but do not start the server. If the configuration contains -errors, display an error message and exit with a non-zero exit status, -otherwise display "Syntax OK" and terminate with a zero exit status. This -command does not perform any checking of the DocumentRoot entries. - -
-R directory
-
If Apache is compiled with SHARED_CORE, then this -directive can be used to specify an alternate location for shared -object files.
- -
- -

When Apache is used under Windows, the following additional -command line options are available.

- -
- -
-n name
-
Set service name and use its ServerConfigFile.
- -
-k option -
Signal Apache to restart or shutdown. option -is one of "shutdown" or "restart". - -
-i
-
Install an Apache service
- -
-u
-
Uninstall an Apache Service
- -
- +configuration file is the default of 80 (or any other port below +1024), then it is necessary to have root privileges in order to start +apache, so that it can bind to this privileged port. Once the server +has started and performed a few preliminary activities such as opening +its log files, it will launch several child processes which +do the work of listening for and answering requests from clients. The +main httpd process continues to run as the root user, but +the child processes run as a less privileged user. This is controlled +by the selected Multi-Processing Module.

+ +

The first thing that httpd does when it is invoked is +to locate and read the configuration +file httpd.conf. The location of this file is set at +compile-time, but it is possible to specify its location at run time +using the -f command-line option as in

+
/usr/local/apache/bin/httpd -f +/usr/local/apache/conf/httpd.conf
+ +

As an alternative to invoking the httpd binary +directly, a shell script called apachectl is provided which can be +used to control the daemon process with simple commands such as +apachectl start and apachectl stop.

+ +

If all goes well during startup, the server will detach from the +terminal and the command prompt will return almost immediately. +This indicates that the server is up and running. You can then +use your browser to connect to the server and view the test +page in the DocumentRoot +directory and the local copy of the documentation linked from +that page.

+ +

Errors During Start-up

+ +

If Apache suffers a fatal problem during startup, it will write a +message describing the problem either to the console or to the ErrorLog before exiting. One of the +most common error messages is "Unable to bind to Port +...". This message is usually caused by either:

+ +

For further trouble-shooting instructions, consult the Apache FAQ.

+ +

Starting at Boot-Time

+ +

If you want your server to continue running after a system reboot, +you should add a call to httpd or apachectl +to your system startup files (typically rc.local or a +file in an rc.N directory). This will start Apache as +root. Before doing this ensure that your server is properly configured +for security and access restrictions. The apachectl +script is designed so that it can often be linked directly as an init +script, but be sure to check the exact requirements of your system.

+ +

Additional Information

+ +

Additional information about the command-line options of httpd and apachectl as well as other support +programs included with the server is available on the Server and Supporting Programs page. There is +also documentation on all the modules included with +the Apache distribution and the directives that they provide.

-- 2.50.1