275 lines
5.2 KiB
HTML
275 lines
5.2 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of apache2ctl</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>apache2ctl</H1>
|
|
Section: Maintenance Commands (8)<BR>Updated: April 2008<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NAME</H2>
|
|
|
|
apache2ctl - Apache HTTP server control interface
|
|
<A NAME="lbAC"> </A>
|
|
<H2>SYNOPSIS</H2>
|
|
|
|
When acting in SysV init mode, apache2ctl takes simple, one-word commands,
|
|
defined below.
|
|
<P>
|
|
|
|
<B>apachectl </B>
|
|
|
|
<I>command</I>
|
|
|
|
<P>
|
|
|
|
<B>apache2ctl </B>
|
|
|
|
<I>command</I>
|
|
|
|
<P>
|
|
|
|
When acting in pass-through mode, apache2ctl can take all the arguments available
|
|
for the httpd binary.
|
|
<P>
|
|
|
|
<B>apachectl </B>
|
|
|
|
[<I>httpd-argument</I>]
|
|
|
|
<P>
|
|
|
|
<B>apache2ctl </B>
|
|
|
|
[<I>httpd-argument</I>]
|
|
|
|
<P>
|
|
|
|
<A NAME="lbAD"> </A>
|
|
<H2>DESCRIPTION</H2>
|
|
|
|
<B>apache2ctl</B>
|
|
|
|
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
|
|
<B>apache2</B>
|
|
|
|
daemon.
|
|
<P>
|
|
|
|
<B>NOTE: </B>
|
|
|
|
The default Debian configuration requires the environment variables
|
|
<B>APACHE_RUN_USER</B>,
|
|
|
|
<B>APACHE_RUN_GROUP</B>,
|
|
|
|
and
|
|
<B>APACHE_PID_FILE</B>
|
|
|
|
to be set in
|
|
<B>/etc/apache2/envvars</B>.
|
|
|
|
<P>
|
|
|
|
The
|
|
<B>apache2ctl</B>
|
|
|
|
script returns a 0 exit value on success, and >0 if an error
|
|
occurs. For more details, view the comments in the script.
|
|
<P>
|
|
|
|
<A NAME="lbAE"> </A>
|
|
<H2>OPTIONS</H2>
|
|
|
|
The <I>command</I> can be any one or more of the following options:
|
|
<DL COMPACT>
|
|
<DT id="1"><B>start</B>
|
|
|
|
<DD>
|
|
Start the Apache daemon. Gives an error if it is already running.
|
|
<DT id="2"><B>stop</B>
|
|
|
|
<DD>
|
|
Stops the Apache daemon.
|
|
<DT id="3"><B>restart</B>
|
|
|
|
<DD>
|
|
Restarts the Apache daemon by sending it a SIGHUP. If the daemon
|
|
is not running, it is started.
|
|
This command automatically checks the configuration files via
|
|
<B>configtest</B>
|
|
|
|
before initiating the restart to to catch the most obvious errors.
|
|
However, it is still possible for the daemon to die because of problems
|
|
with the configuration.
|
|
<DT id="4"><B>fullstatus</B>
|
|
|
|
<DD>
|
|
Displays a full status report from
|
|
<B>mod_status. </B>
|
|
|
|
For this to work, you need to have mod_status enabled on your server
|
|
and a text-based browser such as <I>lynx</I> available on your system. The
|
|
URL used to access the status report can be set by setting the
|
|
<B>APACHE_STATUSURL</B>
|
|
|
|
variable in
|
|
<B>/etc/apache2/envvars</B>.
|
|
|
|
<DT id="5"><B>status</B>
|
|
|
|
<DD>
|
|
Displays a brief status report. Similar to the fullstatus option,
|
|
except that the list of requests currently being served is omitted.
|
|
<DT id="6"><B>graceful</B>
|
|
|
|
<DD>
|
|
Gracefully restarts the Apache daemon by sending it a SIGUSR1. 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 via apache2ctl
|
|
configtest before initiating the restart to to catch the most obvious errors.
|
|
However, it is still possible for the daemon to die because of problems with
|
|
the configuration.
|
|
<DT id="7"><B>graceful-stop</B>
|
|
|
|
<DD>
|
|
Gracefully stops the Apache httpd 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 immediately.
|
|
<DT id="8"><B>configtest</B>
|
|
|
|
<DD>
|
|
Run a configuration file syntax test. It parses the configuration
|
|
files and either reports
|
|
<B>Syntax Ok</B>
|
|
|
|
or information about the particular syntax error. This test does not catch
|
|
all errors.
|
|
<DT id="9"><B>help</B>
|
|
|
|
<DD>
|
|
Displays a short help message.
|
|
<DT id="10">The following option was available in earlier versions but has been removed.<DD>
|
|
<DT id="11"><B>startssl</B>
|
|
|
|
<DD>
|
|
To start httpd with SSL support, you should edit your configuration file to
|
|
include the relevant directives and then use the normal apache2ctl start.
|
|
</DL>
|
|
<A NAME="lbAF"> </A>
|
|
<H2>ENVIRONMENT</H2>
|
|
|
|
The behaviour of
|
|
<B>apache2ctl</B>
|
|
|
|
can be influenced with these environment variables:
|
|
<B>APACHE_HTTPD</B>,
|
|
|
|
<B>APACHE_LYNX</B>,
|
|
|
|
<B>APACHE_STATUSURL</B>,
|
|
|
|
<B>APACHE_ULIMIT_MAX_FILES</B>,
|
|
|
|
<B>APACHE_RUN_DIR</B>,
|
|
|
|
<B>APACHE_LOCK_DIR</B>,
|
|
|
|
<B>APACHE_RUN_USER</B>,
|
|
|
|
<B>APACHE_ARGUMENTS</B>,
|
|
|
|
<B>APACHE_ENVVARS</B>.
|
|
|
|
See the comments in the script for details.
|
|
These variables (except
|
|
<B>APACHE_ENVVARS</B>)
|
|
|
|
can be set in
|
|
<B>/etc/apache2/envvars</B>.
|
|
|
|
<A NAME="lbAG"> </A>
|
|
<H2>SEE ALSO</H2>
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?8+apache2">apache2</A>(8)</B>,
|
|
|
|
<B>/usr/share/doc/apache2/README.Debian.gz</B>
|
|
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="12"><A HREF="#lbAB">NAME</A><DD>
|
|
<DT id="13"><A HREF="#lbAC">SYNOPSIS</A><DD>
|
|
<DT id="14"><A HREF="#lbAD">DESCRIPTION</A><DD>
|
|
<DT id="15"><A HREF="#lbAE">OPTIONS</A><DD>
|
|
<DT id="16"><A HREF="#lbAF">ENVIRONMENT</A><DD>
|
|
<DT id="17"><A HREF="#lbAG">SEE ALSO</A><DD>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:06:10 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|