Controlling the Apache web service

When we are ready to test the changes made, we can perform a pre-flight check with the following command:

# apachectl configtest

You may receive an error message reporting that the hostname could not be resolved. This is a warning and is okay for the moment. The warning is shown in the following screenshot:

Controlling the Apache web service

The Syntax Ok message at the end is what we want to see; with this, we know that we can restart the web server. Issuing a reload command to the service will force a graceful restart; wait for the active connections to complete before the restart is initiated:

$ sudo systemctl reload httpd

The effect of the change ...

Get Learning RHEL Networking now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.