Test the Apache configuration file httpd.conf

Home -> Internet -> HTTP -> Apache

16951 views

From the computer of: qmchenry (335 recipes)
Created: Sep 24, 2003     Updated: Jul 19, 2004


Add a comment

Add to:
Add to stumbleuponAdd to del.icio.usDigg itAdd to FURL

After making changes to the Apache configuration file, it is a good practice to test the configuration before implementing it.

To test the Apache configuration file for errors:

apachectl configtest


If the configuration file is fine, this command will return Syntax Ok. Otherwise, it will return detailed information about the error discovered.

If apachectl is not in your PATH and you don't know where it is, refer to the recipe Find a file by name to find the location of apachectl, then run it with the fully qualified path, for example:

/usr/local/apache/bin/apachectl configtest

Subscribe to the Tech-Recipes Newsletter

You can get tips like this delivered in your email every week!

Enter your Email

We will never, ever sell your email address or spam you.





Related recipes:

  Restart Apache without closing open connections
  HowTo: Reboot the Apache Server Safely
  Stop Apache server processes
  Password protect a web directory with .htaccess
  Rewrite domain.com to www.domain.com using htaccess in Apache

 

Sponsored links

 

Login

Nickname

Password

Don't have an account yet? You can create one. As a registered user you have some advantages like theme manager, comments configuration and post comments with your name.