Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have an Ubuntu 13.04 server that had normal, stock Apache 2.2 with SSI working. I got a bug in my ear, and installed the ppa:rhardy/apache24x PPA to get my server upgraded Apache 2.4.

While it wasn't a clean upgrade, I have gotten most of the kinks worked out.

However, I still can't figure out how to get Server-Side Includes working. Everything looks ok, but when I hit one of my sites served from this server that uses SSI, it doesn't work.

I have /etc/apache2/mods-enabled/include.load symlinked to /etc/apache2/mods-available/include.load

My site's config file looks like:

<VirtualHost *>

    DocumentRoot /var/www/myserver
    <Directory />
        Options +Indexes +FollowSymLinks +IncludesNOEXEC
        AllowOverride None
        XBitHack On
        AddType text/html .shtml
        AddOutputFilter INCLUDES .shtml

Inside /var/www/myserver:

-rwxr-xr-x 1 mike mike  776 Feb 20  2012 index.shtml*

And the contents of the file start with an SSI:

<!--#include virtual="/include/header.html"-->

I have restarted the server after all configuration changes, and still don't have SSI working. What am I missing?


share|improve this question
up vote 0 down vote accepted

It appears that there is a difference in how Apache 2.2 handles <Directory> entries that align with DocumentRoot vs. how 2.4 does.

In 2.2, the following code:

DocumentRoot /var/www/myserver
<Directory />

would apply any of the directives (such as Options and XBitHack) to the /var/www/myserver directory and files therein.

In 2.4, the configuration needs to change to this:

DocumentRoot /var/www/myserver
<Directory /var/www/myserver>

and then apache2ctl restart, and then SSIs will work again.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.