I found this at the plesk forums, some guy had replaced webalizer with AWSTATS. but im kinda n00b, and would love for anyone out there to turn this into a step by step how to. I know a lot of plesk users are sick of webalizer.

------------------------------------------------
Hi,

I did this. Here are my notes (PSA 6.01 - RH 9.0):

1) Create a subdomain called stats.domain.com (domain.com = a domain of your choice).
2) Add this:


ServerName stats.domain.com:80
SuexecUserGroup awstats01 psacln
ServerAdmin "info@domain.com"
DocumentRoot /home/httpd/vhosts/stats.domain.com/httpdocs
CustomLog /home/httpd/vhosts/stats.domain.com/statistics/logs/access_log combined
ErrorLog /home/httpd/vhosts/stats.domain.com/statistics/logs/error_log

UserDir /home/httpd/vhosts/stats.domain.com/web_users

ScriptAlias /cgi-bin/ /home/httpd/vhosts/stats.domain.com/cgi-bin/

SSLEngine off



php_admin_flag engine on
php_admin_value open_basedir "/home/httpd/vhosts/stats.domain.com/httpdocs:/tmp"

Options -Includes +ExecCGI



SuexecUserGroup awstats01 psacln has to be changed according to your ftp user of stats.domain.com offcourse!

to /etc/httpd/conf/httpd.conf, just before the httpd.include include.

3) Check the syntax of your httpd.conf -> apachectl configtest
4) Restart your apache server /etc/init.d/httpd restart
5) Install awstats to /home/httpd/vhosts/stats.domain.com/cgi-bin
6) Add awstats_updateall.pl to your crontab.
7) Put this php file in /home/httpd/stats.domain.com/httpdocs/ :

$vars = split(".",$HTTP_HOST);
if ((sizeof($vars))>2) {
$host = $vars[0];
if ($vars[3]== "") {
$domain = $vars[1];
$toplevel = $vars[2];
$domain = $domain.".".$toplevel;
}
else {
$sub = $vars[1];
$domain = $vars[2];
$toplevel = $vars[3];
$domain = $sub.".".$domain.".".$toplevel;
}}
else {
$domain = $SERVER_NAME;
}
?>



Redirecting to stats...


Getting stats for




icon_cool.gif Put for every domain you want awstats generate some nice logging a config file in the cgi-bin. I prefer to make a global.conf
And for every domain i make a config like this:

LogFile="/data/vhosts/domain.com/statistics/logs/access_log.processed"
SiteDomain="domain.com"
HostAliases="park.domain.com domain.com www.domain.com stats.domain.com"
#include "awstats.global.conf"

In awstats the # has to be before the include directive (as for awstats <= 5.6)!!

9) Add for every domain a cname record in the dns pointing to stats.domain.com, better change the dns-template for this for al your new domains.

stats. domainb. net. CNAME stats. domain. com.

ét voila.

Greetz!

PS: Anybody know how to get rid of the mailman owner problem ???
I've put a bugrepport at plesk, but they never reported back to me