For RHEL Based systems you can use the command /usr/sbin/httpd -t
[callisto] (~) >>> /usr/sbin/httpd -t
Syntax OK
For Debian based systems (Ubuntu, et al) you can use the commands /usr/sbin/apache2 -t
, apachectl configtest
, or apachectl -t
[triton] (~) >>> /usr/sbin/apache2 -t
apache2: bad user name ${APACHE_RUN_USER}
[triton] (~) >>> apachectl -t
Syntax OK
[triton] (~) >>> apachectl configtest
Syntax OK