Apache Configuration Test

MacBook Pro turned on beside Apple Magic Mouse on top of white surface

When making changes in your httpd-vhost.conf file, make sure to test it before reloading the apache config file or restarting apache.

Mac OSX

apachectl configtest

XAMPP OSX

/Applications/XAMPP/xamppfiles/bin/apachectl configtest

Errors should display, if there are any, otherwise you'll see the Syntax OK to indicate that there are no errors and you can reload the apache config file or restart apache.

Mac OSX

apachectl reload
apachectl restart

XAMPP OSX

/Applications/XAMPP/xamppfiles/bin/apachectl reload
/Applications/XAMPP/xamppfiles/bin/apachectl restart

Troubleshooting

If you have file sharing enabled on your OSX, make sure to disable it before restarting or reloading apache. Also, if you notice other httpd services running and you cannot start your XAMPP's apache, try to unload it using launchctl

sudo launchctl unload -w /System/Library/LaunchDaemons/org.apache.httpd.plist 2>/dev/null

 

Add new comment

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.