APACHECTL2(8)apachectl2APACHECTL2(8)NAMEapachectl2 - Apache HTTP Server Control Interface
SYNOPSIS
When acting in pass-through mode, apachectl2 can take all the arguments
available for the httpd2 binary.
apachectl2 [ httpd2-argument ]
When acting in SysV init mode, apachectl2 takes simple, one-word com-
mands, defined below.
apachectl2 command
SUMMARYapachectl2 is a front end to the Apache HyperText Transfer Protocol
(HTTP) server. It is designed to help the administrator control the
functioning of the Apache httpd2 daemon.
The apachectl2 script can operate in two modes. First, it can act as a
simple front-end to the httpd2 command that simply sets any necessary
environment variables and then invokes httpd2, passing through any com-
mand line arguments. Second, apachectl2 can act as a SysV init script,
taking simple one-word arguments like start, restart, and stop, and
translating them into appropriate signals to httpd2.
If your Apache installation uses non-standard paths, you will need to
edit the apachectl2 script to set the appropriate paths to the httpd2
binary. You can also specify any necessary httpd2 command line argu-
ments. See the comments in the script for details.
The apachectl2 script returns a 0 exit value on success, and >0 if an
error occurs. For more details, view the comments in the script.
OPTIONS
Only the SysV init-style options are defined here. Other arguments are
defined on the httpd2 manual page.
start Start the Apache httpd2 daemon. Gives an error if it is already
running. This is equivalent to apachectl2-k start.
Apache HTTP Server 2005-09-20 1
APACHECTL2(8)apachectl2APACHECTL2(8)
stop Stops the Apache httpd2 daemon. This is equivalent to apachectl2-k stop.
restart
Restarts the Apache httpd2 daemon. If the daemon is not running,
it is started. This command automatically checks the configura-
tion files as in configtest before initiating the restart to
make sure the daemon doesn't die. This is equivalent to
apachectl2-k restart.
fullstatus
Displays a full status report from mod_status. For this to work,
you need to have mod_status enabled on your server and a text-
based browser such as lynx available on your system. The URL
used to access the status report can be set by editing the STA-
TUSURL variable in the script.
status Displays a brief status report. Similar to the fullstatus
option, except that the list of requests currently being served
is omitted.
graceful
Gracefully restarts the Apache httpd2 daemon. If the daemon is
not running, it is started. This differs from a normal restart
in that currently open connections are not aborted. A side
effect is that old log files will not be closed immediately.
This means that if used in a log rotation script, a substantial
delay may be necessary to ensure that the old log files are
closed before processing them. This command automatically checks
the configuration files as in configtest before initiating the
restart to make sure Apache doesn't die. This is equivalent to
apachectl2-k graceful.
graceful-stop
Gracefully stops the Apache httpd2 daemon. This differs from a
normal stop in that currently open connections are not aborted.
A side effect is that old log files will not be closed immedi-
ately. This is equivalent to apachectl2-k graceful-stop.
configtest
Run a configuration file syntax test. It parses the configura-
tion files and either reports Syntax Ok or detailed information
about the particular syntax error. This is equivalent to
apachectl2-t.
The following option was available in earlier versions but has been
removed.
startssl
To start httpd2 with SSL support, you should edit your configu-
ration file to include the relevant directives and then use the
Apache HTTP Server 2005-09-20 2
APACHECTL2(8)apachectl2APACHECTL2(8)
normal apachectl2 start.
Apache HTTP Server 2005-09-20 3