906948
906948
906948
  "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd">[
906948
906948
]>
906948
906948
 Copyright 2020 Red Hat, Inc.
906948
906948
 Licensed to the Apache Software Foundation (ASF) under one or more
906948
 contributor license agreements. See the NOTICE file distributed with
906948
 this work for additional information regarding copyright ownership.
906948
 The ASF licenses this file to You under the Apache License, Version 2.0
906948
 (the "License"); you may not use this file except in compliance with
906948
 the License. You may obtain a copy of the License at
906948
906948
     http://www.apache.org/licenses/LICENSE-2.0
906948
906948
 Unless required by applicable law or agreed to in writing, software
906948
 distributed under the License is distributed on an "AS IS" BASIS,
906948
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
906948
 See the License for the specific language governing permissions and
906948
 limitations under the License.
906948
-->
906948
<refentry>
906948
  <refentryinfo>
906948
    <title>apachectl</title>
906948
    <productname>httpd</productname>
906948
    <author><contrib>Apache man page</contrib><othername>Apache Software Foundation contributors</othername></author>
906948
    <author><contrib>Fedora man page</contrib><surname>Dana</surname><firstname>Frank</firstname></author>
906948
  </refentryinfo>
906948
906948
  <refmeta>
906948
    <refentrytitle>apachectl</refentrytitle>
906948
    <manvolnum>8</manvolnum>
906948
  </refmeta>
906948
906948
  <refnamediv>
906948
    <refname>apachectl</refname>
906948
    <refpurpose>Server control interface for httpd</refpurpose>
906948
  </refnamediv>
906948
906948
  <refsynopsisdiv id='synopsis'>
906948
    <cmdsynopsis>
906948
      <command>apachectl</command>
906948
      <arg choice='opt'><replaceable>command</replaceable> </arg>
906948
      <sbr/>
906948
    </cmdsynopsis>
906948
  </refsynopsisdiv>
906948
906948
906948
  <refsect1 id='description'>
906948
    <title>Description</title>
906948
906948
    <para><command>apachectl</command> is a front end to the Apache HyperText
906948
    Transfer Protocol (HTTP) server. It is designed to help the
906948
    administrator control the functioning of the Apache
906948
    <command>httpd</command> daemon.</para>
906948
906948
    <para>The <command>apachectl</command> script takes one-word arguments like
906948
    <option>start</option>,
906948
    <option>restart</option>, and
906948
    <option>stop</option>, and translates them
906948
    into appropriate signals to <command>httpd</command>.</para>
906948
906948
    <para>The <command>apachectl</command> script returns a 0 exit value on
906948
    success, and >0 if an error occurs.</para>
906948
906948
    <refsect2 id="compatibility">
906948
      <title>Compatibility</title>
906948
906948
      <para>The version of <command>apachectl</command> used on this
906948
      system is a replacement script intended to be mostly (but not
906948
      completely) compatible with version provided with
906948
      <emphasis>Apache httpd</emphasis>.  This
906948
      <command>apachectl</command> mostly acts as a wrapper around
906948
      <command>systemctl</command> and manipulates the
906948
      <command>systemd</command> service for <command>httpd</command>.
906948
      The interface to the <emphasis>Apache</emphasis> version of
906948
      <command>apachectl</command> is described at 
906948
      url="https://httpd.apache.org/docs/2.4/programs/apachectl.html"/>.</para>
906948
906948
      <para>The following differences are present in the version of
906948
      <command>apachectl</command> present on this system:
906948
906948
      <itemizedlist>
906948
        <listitem><para>Option arguments passed when starting
906948
        <command>httpd</command> are not allowed.  These should be
906948
        configured in the systemd service directly (see <citerefentry><refentrytitle>httpd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>).</para></listitem>
906948
906948
        <listitem><para>The <command>"fullstatus"</command> option is
906948
        not available.</para></listitem>
906948
906948
        <listitem><para>The <command>"status"</command> option does
906948
        not use or rely on the running server's
906948
        <emphasis>server-status</emphasis> output.</para></listitem>
906948
      </itemizedlist>
906948
906948
      </para>
906948
    </refsect2>
906948
  </refsect1>
906948
906948
  <refsect1 id='options'>
906948
    <title>Options</title>
906948
    <variablelist remap='TP'>
906948
      <varlistentry>
906948
        <term><option>start</option></term>
906948
        <listitem>
906948
          <para>Start the Apache <command>httpd</command> daemon. Gives an error if it
906948
          is already running. This is equivalent to <command>systemctl start httpd.service</command>.</para>
906948
        </listitem>
906948
      </varlistentry>
906948
906948
      <varlistentry>
906948
        <term><option>stop</option></term>
906948
        <listitem>
906948
          <para>Stops the Apache <command>httpd</command> daemon. This is equivalent to
906948
          <command>systemctl stop httpd.service</command>.</para>
906948
        </listitem>
906948
      </varlistentry>
906948
906948
      <varlistentry>
906948
        <term><option>restart</option></term>
906948
        <listitem>
906948
          <para>Restarts the Apache <command>httpd</command> daemon. If the daemon is
906948
          not running, it is started. This is equivalent
906948
          to <command>systemctl restart httpd.service</command>.</para>
906948
        </listitem>
906948
      </varlistentry>
906948
906948
      <varlistentry>
906948
        <term><option>status</option></term>
906948
        <listitem>
906948
          <para>Displays a brief status report. This is equivalent to <command>systemctl status httpd.service.</command></para>
906948
        </listitem>
906948
      </varlistentry>
906948
906948
      <varlistentry>
906948
        <term><option>graceful</option></term>
906948
        <listitem>
906948
          <para>Gracefully restarts the Apache <command>httpd</command> daemon. If the
906948
          daemon is not running, it is started. This differs from a normal
906948
          restart in that currently open connections are not aborted. A side
906948
          effect is that old log files will not be closed immediately. This
906948
          means that if used in a log rotation script, a substantial delay may
906948
          be necessary to ensure that the old log files are closed before
906948
          processing them. This is equivalent to
906948
          <command>systemctl kill --signal=SIGUSR1 --kill-who=main httpd.service</command>.</para>
906948
        </listitem>
906948
      </varlistentry>
906948
906948
      <varlistentry>
906948
        <term><option>graceful-stop</option></term>
906948
        <listitem>
906948
          <para>Gracefully stops the Apache <command>httpd</command> daemon.
906948
          This differs from a normal stop in that currently open connections are not
906948
          aborted. A side effect is that old log files will not be closed immediately.
906948
          This is equivalent to
906948
          <command>systemctl kill --signal=SIGWINCH --kill-who=main httpd.service</command>.</para>
906948
        </listitem>
906948
      </varlistentry>
906948
906948
      <varlistentry>
906948
        <term><option>configtest</option></term>
906948
        <listitem>
906948
          <para>Run a configuration file syntax test. It parses the configuration
906948
          files and either reports <literal>Syntax OK</literal>
906948
          or detailed information about the particular syntax error. This is
906948
          equivalent to <command>httpd -t</command>.</para>
906948
        </listitem>
906948
      </varlistentry>
906948
    </variablelist>
906948
  </refsect1>
906948
906948
  <refsect1 id='bugs'>
906948
    <title>Bugs</title>
906948
    <para>Please report bugs by filing an issue in Bugzilla via <ulink url='https://bugzilla.redhat.com/'/>.</para>
906948
  </refsect1>
906948
906948
    <refsect1>
906948
    <title>See also</title>
906948
906948
    <para>
906948
    <citerefentry><refentrytitle>httpd</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
906948
    <citerefentry><refentrytitle>httpd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
906948
    <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
906948
    <citerefentry><refentrytitle>systemctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
906948
    <citerefentry><refentrytitle>httpd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>
906948
    </para>
906948
  </refsect1>
906948
906948
</refentry>