1

The AWStats setup instructions I have seen specifiy how to set up apache so you can view the statistics for each site by going to something like:

http://www.mydomain.com/awstats

Does anyone know how I could configure it to work with another domain for the "mydomain.com" stats. For example something like:

http://www.someotherdomain.com/awstats/www.mydomain.com/

Kyle Brandt
  • 83,619
  • 74
  • 305
  • 448

2 Answers2

2

AWStats is normally configured to run as a cron job. There are two parts to it.

1.) Run an update of the database. This ingests the log files. 2.) Generate the output. This is the part you need to look at.

Here's an example of what I do for some of the sites on my server:

00 7 * * *      perl /usr/lib/cgi-bin/awstats.pl -config=blackbirds.tv -output -staticlinks >/var/www/manticore/stats/awstats.blackbirds.html

The /var/www/manticore folder is the home folder for the server's main domain (www.manticore-uk.com, this is live so go and have a look, the default site is actually empty and you'll get an error, but the awstats files are all there).

As you can see this is done with a simple output redirection. And, sorry, yes, this only really works this way under Linux. I haven't got an idea how to do this under Windows.

wolfgangsz
  • 8,847
  • 3
  • 30
  • 34
0

Out of the box, awstats is able to do this for you:

http://www.someotherdomain.com/awstats/awstats.pl?config=www.mydomain.com

This will show you the stats for www.mydomain.com

This assumes that someotherdomain.com is hosted on the same server as mydomain.com

You should be able to use this approach for any virtual host you are monitoring via awstats on the same server.

user12345
  • 173
  • 1
  • 6