Collection3 and nginx

Following up, on my previous post about using services with the nginx webserver - I've decided to publish the configuration sniplet from getting Collection3, which is used in conjunction with Collectd to give a simple peak into your machines performance. It's quite simple really, but as it's not to be found anywhere else - I'll just publish it here, so Google will pick it up, and circulate it for me.

As with the last sniplet I published - you need to have fastcgi working on your nginx, and feel free to either leave out the basic authentication part, or modify it to suit your own needs.

location ~ .cgi$ {
    root /usr/share/collectd/collection3;
    if (!-e $request_filename) { rewrite / /bin/index.cgi last; }
    expires off;
    fastcgi_pass unix:/var/run/fcgiwrap.socket;
    fastcgi_index index.cgi;
    fastcgi_param SCRIPT_NAME $fastcgi_script_name;
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    include /etc/nginx/fastcgi_params;

location /share {
    alias /usr/share/collectd/collection3/share;

location / {
    auth_basic      "Happy Collectd server";
    auth_basic_user_file   /etc/nginx/users.htpasswd;
    root   /usr/share/collectd/collection3;
    index  bin/index.cgi;
Show Comments