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'm currently trying to install graphite 0.9.9 on a gentoo box using these instructions from the graphite wiki. Essentially, it fronts graphite using apache and mod_wsgi.

Everything seems to have gone well, except that apache / the graphite webapp never seem to return a response to the web browser (the browser continuously waits to load the page). I've turned on the graphite debug info, but the only message in the log files is this, repeated over and over again in info.log (with the pid always changing):

Thu Feb 23 01:59:38 2012 :: graphite.wsgi - pid 4810 - reloading search index

These instructions have worked for me before to set up graphite on an Ubuntu machine. I suspect that mod_wsgi is dying, but I have confirmed that mod_wsgi works fine when not serving the graphite webapp.

This is what my graphite.conf vhost file looks like:

WSGISocketPrefix /etc/httpd/wsgi/ 

<VirtualHost *:80>
    ServerName # Server name
    DocumentRoot "/opt/graphite/webapp"
    ErrorLog /opt/graphite/storage/log/webapp/error.log
    CustomLog /opt/graphite/storage/log/webapp/access.log common

    # I've found that an equal number of processes & threads tends
    # to show the best performance for Graphite (ymmv).
    WSGIDaemonProcess graphite processes=5 threads=5 display-name='%{GROUP}' inactivity-timeout=120
    WSGIProcessGroup graphite
    WSGIApplicationGroup %{GLOBAL}
    WSGIImportScript /opt/graphite/conf/graphite.wsgi process-group=graphite application-group=%{GLOBAL}

    WSGIScriptAlias / /opt/graphite/conf/graphite.wsgi  

    Alias /content/ /opt/graphite/webapp/content/ 
    <Location "/content/"> 
            SetHandler None 

    # XXX In order for the django admin site media to work you 
    # must change @DJANGO_ROOT@ to be the path to your django 
    # installation, which is probably something like: 
    # /usr/lib/python2.6/site-packages/django 
    Alias /media/ "/usr/lib64/python2.6/site-packages/django/contrib/admin/media/" 
    <Location "/media/"> 
            SetHandler None 

    # The graphite.wsgi file has to be accessible by apache. It won't 
    # be visible to clients because of the DocumentRoot though. 
    <Directory /opt/graphite/conf/> 
            Order deny,allow 
            Allow from all 

share|improve this question
what is the contents of your /opt/graphite/conf/graphite.wsgi – Mike Jun 25 at 12:48

Doesn't address your problem, but you don't need:

<Location "/content/"> 
        SetHandler None 

<Location "/media/"> 
        SetHandler None 

Using SetHandler like that was only need in the past when using mod_python. It is not required when using mod_wsgi.

What I would suggest you do is make sure the user your code runs as under Apache actually has appropriate write access to any directories it needs for data files for the application.

share|improve this answer
Thanks. I've double checked that all the data files belong to the appropriate user:group, and that the read write permissions are set. This doesn't seem to have been the problem, though :( – River Feb 23 '12 at 13:47

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.