1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><!--
4 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
5 This file is generated from xml source: DO NOT EDIT
6 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
8 <title>apachectl - Apache HTTP Server Control Interface - Apache HTTP Server</title>
9 <link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
10 <link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
11 <link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" />
12 <link href="../images/favicon.ico" rel="shortcut icon" /></head>
13 <body id="manual-page"><div id="page-header">
14 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p>
15 <p class="apache">Apache HTTP Server Version 2.0</p>
16 <img alt="" src="../images/feather.gif" /></div>
17 <div class="up"><a href="./"><img title="<-" alt="<-" src="../images/left.gif" /></a></div>
19 <a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">HTTP Server</a> > <a href="http://httpd.apache.org/docs/">Documentation</a> > <a href="../">Version 2.0</a> > <a href="./">Programs</a></div><div id="page-content"><div id="preamble"><h1>apachectl - Apache HTTP Server Control Interface</h1>
21 <p><span>Available Languages: </span><a href="../en/programs/apachectl.html" title="English"> en </a> |
22 <a href="../ko/programs/apachectl.html" hreflang="ko" rel="alternate" title="Korean"> ko </a> |
23 <a href="../tr/programs/apachectl.html" hreflang="tr" rel="alternate" title="Türkçe"> tr </a></p>
26 <p><code>apachectl</code> is a front end to the Apache HyperText
27 Transfer Protocol (HTTP) server. It is designed to help the
28 administrator control the functioning of the Apache
29 <code class="program"><a href="../programs/httpd.html">httpd</a></code> daemon.</p>
31 <p>The <code>apachectl</code> script can operate in two modes.
32 First, it can act as a simple front-end to the <code class="program"><a href="../programs/httpd.html">httpd</a></code>
33 command that simply sets any necessary environment variables and
34 then invokes <code class="program"><a href="../programs/httpd.html">httpd</a></code>, passing through any command line
35 arguments. Second, <code>apachectl</code> can act as a SysV init
36 script, taking simple one-word arguments like <code>start</code>,
37 <code>restart</code>, and <code>stop</code>, and translating them
38 into appropriate signals to <code class="program"><a href="../programs/httpd.html">httpd</a></code>.</p>
40 <p>If your Apache installation uses non-standard paths, you will
41 need to edit the <code>apachectl</code> script to set the
42 appropriate paths to the <code class="program"><a href="../programs/httpd.html">httpd</a></code> binary. You can also
43 specify any necessary <code class="program"><a href="../programs/httpd.html">httpd</a></code> command line arguments.
44 See the comments in the script for details.</p>
46 <p>The <code>apachectl</code> script returns a 0 exit value on
47 success, and >0 if an error occurs. For more details, view
48 the comments in the script.</p>
50 <div id="quickview"><ul id="toc"><li><img alt="" src="../images/down.gif" /> <a href="#synopsis">Synopsis</a></li>
51 <li><img alt="" src="../images/down.gif" /> <a href="#options">Options</a></li>
52 </ul><h3>See also</h3><ul class="seealso"><li><a href="../invoking.html">Starting Apache</a></li><li><a href="../stopping.html">Stopping Apache</a></li><li><a href="../configuring.html">Configuration Files</a></li><li><a href="../platform/">Platform Docs</a></li><li><code class="program"><a href="../programs/httpd.html">httpd</a></code></li></ul></div>
53 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
55 <h2><a name="synopsis" id="synopsis">Synopsis</a></h2>
57 <p>When acting in pass-through mode, <code>apachectl</code> can take
58 all the arguments available for the <code class="program"><a href="../programs/httpd.html">httpd</a></code>
61 <p><code><strong>apachectl</strong> [ <var>httpd-argument</var> ]</code></p>
63 <p>When acting in SysV init mode, <code>apachectl</code> takes simple,
64 one-word commands, defined below.</p>
66 <p><code><strong>apachectl</strong> <var>command</var></code></p>
68 </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
70 <h2><a name="options" id="options">Options</a></h2>
72 <p>Only the SysV init-style options are defined here. Other arguments
73 are defined on the <code class="program"><a href="../programs/httpd.html">httpd</a></code> manual page.</p>
77 <dt><code>start</code></dt>
79 <dd>Start the Apache <code class="program"><a href="../programs/httpd.html">httpd</a></code> daemon. Gives an error if it
80 is already running. This is equivalent to <code>apachectl -k
83 <dt><code>stop</code></dt>
85 <dd>Stops the Apache <code class="program"><a href="../programs/httpd.html">httpd</a></code> daemon. This is equivalent to
86 <code>apachectl -k stop</code>.</dd>
88 <dt><code>restart</code></dt>
90 <dd>Restarts the Apache <code class="program"><a href="../programs/httpd.html">httpd</a></code> daemon. If the daemon is
91 not running, it is started. This command automatically checks the
92 configuration files as in <code>configtest</code> before initiating
93 the restart to make sure the daemon doesn't die. This is equivalent
94 to <code>apachectl -k restart</code>.</dd>
96 <dt><code>fullstatus</code></dt>
98 <dd>Displays a full status report from <code class="module"><a href="../mod/mod_status.html">mod_status</a></code>.
99 For this to work, you need to have <code class="module"><a href="../mod/mod_status.html">mod_status</a></code> enabled
100 on your server and a text-based browser such as <code>lynx</code>
101 available on your system. The URL used to access the status report
102 can be set by editing the <code>STATUSURL</code> variable in the
105 <dt><code>status</code></dt>
107 <dd>Displays a brief status report. Similar to the
108 <code>fullstatus</code> option, except that the list of requests
109 currently being served is omitted.</dd>
111 <dt><code>graceful</code></dt>
113 <dd>Gracefully restarts the Apache <code class="program"><a href="../programs/httpd.html">httpd</a></code> daemon. If the
114 daemon is not running, it is started. This differs from a normal
115 restart in that currently open connections are not aborted. A side
116 effect is that old log files will not be closed immediately. This
117 means that if used in a log rotation script, a substantial delay may
118 be necessary to ensure that the old log files are closed before
119 processing them. This command automatically checks the configuration
120 files as in <code>configtest</code> before initiating the
121 restart to make sure Apache doesn't die. This is equivalent to
122 <code>apachectl -k graceful</code>.</dd>
124 <dt><code>configtest</code></dt>
126 <dd>Run a configuration file syntax test. It parses the configuration
127 files and either reports <code>Syntax Ok</code>
128 or detailed information about the particular syntax error. This is
129 equivalent to <code>apachectl -t</code>.</dd>
133 <p>The following additional option is available, but deprecated.</p>
137 <dt><code>startssl</code></dt>
139 <dd>This is equivalent to <code>apachectl -k start -DSSL</code>. We
140 recommend that you use that command explicitly, or you adjust your
141 <code>httpd.conf</code> to remove the <code class="directive"><a href="../mod/core.html#ifdefine"><IfDefine></a></code> section so that SSL will always be
147 <div class="bottomlang">
148 <p><span>Available Languages: </span><a href="../en/programs/apachectl.html" title="English"> en </a> |
149 <a href="../ko/programs/apachectl.html" hreflang="ko" rel="alternate" title="Korean"> ko </a> |
150 <a href="../tr/programs/apachectl.html" hreflang="tr" rel="alternate" title="Türkçe"> tr </a></p>
151 </div><div id="footer">
152 <p class="apache">Copyright 2009 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p>
153 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p></div>