Scroll to navigation

APACHECTL(8) apachectl APACHECTL(8)

NAME

apachectl - Server control interface for httpd

SYNOPSIS

apachectl [command]

DESCRIPTION

apachectl 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 httpd daemon.

The apachectl script takes one-word arguments like start, restart, and stop, and translates them into appropriate signals to httpd.

The apachectl script returns a 0 exit value on success, and >0 if an error occurs.

Compatibility

The version of apachectl used on this system is a replacement script intended to be mostly (but not completely) compatible with version provided with Apache httpd. This apachectl mostly acts as a wrapper around systemctl and manipulates the systemd service for httpd. The interface to the Apache version of apachectl is described at https://httpd.apache.org/docs/2.4/programs/apachectl.html.

The following differences are present in the version of apachectl present on this system:

•Option arguments passed when starting httpd are not allowed. These should be configured in the systemd service directly (see httpd.service(8)).

•The "fullstatus" option is not available.

•The "status" option does not use or rely on the running server's server-status output.

OPTIONS

start

Start the Apache httpd daemon. Gives an error if it is already running. This is equivalent to systemctl start httpd.service.

stop

Stops the Apache httpd daemon. This is equivalent to systemctl stop httpd.service.

restart

Restarts the Apache httpd daemon. If the daemon is not running, it is started. This is equivalent to systemctl restart httpd.service.

status

Displays a brief status report. This is equivalent to systemctl status httpd.service.

graceful

Gracefully restarts the Apache httpd 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 is equivalent to systemctl kill --signal=SIGUSR1 --kill-who=main httpd.service.

graceful-stop

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. This is equivalent to systemctl kill --signal=SIGWINCH --kill-who=main httpd.service.

configtest

Run a configuration file syntax test. It parses the configuration files and either reports Syntax OK or detailed information about the particular syntax error. This is equivalent to httpd -t.

BUGS

Please report bugs by filing an issue in Bugzilla via https://bugzilla.redhat.com/.

SEE ALSO

httpd(8), httpd.conf(5), systemd(1), systemctl(1), httpd.service(8)

AUTHORS

Apache Software Foundation contributors

Apache man page

Frank Dana

Fedora man page
02/07/2024 httpd