Apache Config File Location in Raspberry Pi


apache config file location in raspberry pi

Raspberry Pi is a simple yet powerful computer that is widely used in robotics and automation. While you can install Apache web server on Raspberry Pi, it will be difficult to customize it if you don’t know the location of Apache’s config file. Here’s how to find out Apache config file location in Raspberry Pi.

 

Apache Config File Location in Raspberry Pi

Here’s how to find Apache config file location in Raspberry Pi.

 

The first thing to note is that the Apache config file on Raspberry Pi is called apache2.conf and not httpd.conf if you are using a Debian flavor of Linux such as Ubuntu. If you are using CentOS/RHEL/Fedora Linux then it is called httpd.conf.

 

If Apache came pre-installed, or you installed it with a package manager, then you will find Apache config file at one of the following locations:

  • /etc/apache2/httpd.conf
  • /etc/apache2/apache2.conf
  • /etc/httpd/httpd.conf
  • /etc/httpd/conf/httpd.conf

 

If you have installed Apache from source, then you will find the config file at one of the following locations.

  • /usr/local
  • /opt

You can also include a different file (e.g /etc/apache_config.conf) for your configuration. To do that, simply use the Include directive to include its path in Apache’s main config file.

 

That’s it! Once you edit, save and close the config file, please ensure to restart Apache web server to apply changes.

 

About Sreeram Sreenivasan

Sreeram Sreenivasan is the Founder of Ubiq, a business dashboard & reporting platform for small & medium businesses. Ubiq makes it easy to build business dashboards & reports for your business. Try it for free today!