Web server statistics: JAWStats

Table of Contents

Setup AWStats
Setup JAWStats

Setup JAWStats

by ross at 07:23:20 on October 28, 2011

Install

# cd /usr/ports/www/jawstats
# make install clean
# cd /usr/local/www/jawstats
# cp config.dist.php config.php

Configure

Edit /usr/local/www/jawstats/config.php:

<?php

  // core config parameters
  $sDefaultLanguage      = "en-gb";
  $sConfigDefaultView    = "thismonth.all";
  $bConfigChangeSites    = true;
  $bConfigUpdateSites    = false;
  $sUpdateSiteFilename   = "xml_update.php";

  // individual site configuration
  $aConfig["example.com"] = array(
    "statspath"   => "/home/awstats/",
    "updatepath"  => "/usr/local/www/awstats/cgi-bin/awstats.pl/",
    "siteurl"     => "http://example.com",
    "sitename"    => "Example",
    "theme"       => "default",
    "fadespeed"   => 250,
    "password"    => "secret",
    "includes"    => "",
    "language"    => "en-gb"
  );

?>

Create virtual host for JAWStats:

<VirtualHost *:80>
        ServerName jawstats.example.com
        ServerAdmin [email protected]
        DocumentRoot "/usr/local/www/jawstats"
        ErrorLog "/var/log/httpd-jawstats.example.com-error.log"
        CustomLog "/var/log/httpd-jawstats.example.com-access.log" combined
</VirtualHost>

<Directory "/usr/local/www/jawstats">
        Options FollowSymLinks Indexes MultiViews
        AllowOverride All
        Order Allow,Deny
        Allow from all
</Directory>

Restart Apache.

Comments