Httpd.conf’s Location on CentOS, Ubuntu, Red Hat, Mac and Others

Here’s where to find the Apache 2 web server configuration file httpd.conf The httpd.conf directory differs across Linux & Unix variants like CentOS, Mac OS X, Red Hat, Ubuntu and XAMPP Mac.

This table lists the httpd.conf location for each operating system:

Operating System / Linux Distrohttpd.conf Location
CentOS 5.2/etc/httpd/conf/httpd.conf
CentOS 5.3/etc/httpd/conf/httpd.conf
Mac OSX 10.6 Snow Leopard/etc/apache2/httpd.conf
Mac OSX 10.7 Lion/etc/apache2/httpd.conf
Red Hat Enterprise Linux Server 5.6 Tikanga (RHEL)/etc/httpd/conf/httpd.conf
Ubuntu 7.04 Feisty Fawn/etc/apache2/httpd.conf
Ubuntu 8.10 Intrepid Ibex/etc/apache2/httpd.conf
Ubuntu 10.10 Maverick Meerkat/etc/apache2/httpd.conf
XAMPP on Mac/Applications/XAMPP/etc/httpd.conf

For more specific information on Ubuntu, see httpd.conf location on Ubuntu.

The location for Fedora will likely be the same as CentOS (same distro family).

The location for Debian will likely be the same as Ubuntu (same distro family).

If your operating system or Apache package isn’t mentioned here, you can use the find command on Linux, Unix or Mac to find httpd.conf, e.g.:

find / -name httpd.conf 2>/dev/null

On Windows, you can use the search facility of Windows Explorer to find httpd.conf.

Additions & refinements welcome!

Tagged , , , , , . Bookmark the permalink.

One Response to Httpd.conf’s Location on CentOS, Ubuntu, Red Hat, Mac and Others

  1. Pingback: .htaccess Not Working / Ignored? « Smart Web Developer

Leave a Reply

Your email address will not be published. Required fields are marked *