batch-fileloggingawstats

AWStat results in all 0 stats


I am trying to get awstat to build html pages from my log files. My log files are created in 'C:\inetpub\stats\awstats-7.3\wwwroot\sites\itsMe_LOGS'. When I run AWStat, I get no errors, it creats a combined.log and it creates about 22 html files that look like this:

enter image description here

I'm not sure what is going wrong but i know that there are proper logs, and the site is active. If there is any other details that would help solve this problem, please let me know so I can add it. Any point in the right direction would be helpful. Thank you.

Batch file

::set up base configurations for itsMe
SET HOST_CONFIG=itsMe
SET BASE_DIR="C:\inetpub\stats\awstats-7.3\wwwroot"

echo Combining log files for .%HOST_CONFIG%
call perl %BASE_DIR%\tools\logresolvemerge.pl -showsteps %BASE_DIR%\sites\%HOST_CONFIG%\*.log > %BASE_DIR%\sites\%HOST_CONFIG%\combined.log

echo Updating statistics for .%HOST_CONFIG% 
call perl %BASE_DIR%\cgi-bin\awstats.pl -config=%HOST_CONFIG% -update

echo Generating reports for .%HOST_CONFIG%
call perl %BASE_DIR%\cgi-bin\awstats.pl -config=%HOST_CONFIG% -output -staticlink > wwwroot\sites\%HOST_CONFIG%\awstats.%HOST_CONFIG%.MAIN_SUMMARY.html
call perl %BASE_DIR%\tools\awstats_buildstaticpages.pl -awstatsprog=%BASE_DIR%\cgi-bin\awstats.pl -config=%HOST_CONFIG% -update -dir=wwwroot\sites\%HOST_CONFIG%

Solution

  • The way that AWStats was running, It was producing html pages with a broken directory to the combined.log file. The way I tracked it down was i tried moving my combined.log file into my html page directory and ran my batch file again. In the long run, I needed to change the directory where my combined.log file get's produced.