Hello... So i had a client ask why his awstats are not working. I went to the domain in question in ispconfig. I set a password, as i thought maybe it was not enabled. I then wait 5 mins went to domain /awstats i log in and only see this month in drop down and the page says "domain refused to connect" What should i be looking for? All awstats files exist in their proper places and the ispconfig crons run fine... When i look in /var/lib/awstats i do not see any files related to the domain in question. What should i look at? Thanks...
Take a look at the error.log of the website, maybe you find an error there when you try to use awstats.
The command should be: awstats_buildstaticpages.pl -month=11 -year=2018 -update -config=mydomain.com -lang=en -dir=/var/www/domain.com/web/stats -awstatsprog=/path/to/awstats.pl
So after i ran that i checked the stats dir and there were files in it, but i get same error owhen trying to get to domain.com/stats however if it go to domain.com/stats/awstats.domain.com.html i see some stats but all the graphics/icons are broken..
There seems to be a missing directory http://www.domain.com/awstats-icon/other/vv.png or a bad redirect i guess.... i canno tfind a dir named awstats-icon anywhere on the server
I manually put the link in on my CentOS servers in the web directory for the icons awstatsicons -> /usr/share/awstats/wwwroot/icon
Ok so linking.... ln -s /usr/share/awstats/icon awstats-icon within the webroot fixed, but now i have to do for all domains????? And he only has Nov stats...
So the stats are not running automatically everyday.... I need to resolve this... Please provide the steps to troubleshoot this issue form the beginning again. Thanks..
Check in the ISPConfig interface that the path to the buildstaticpages script under system > server config matches the location of that script on the hard disk of the server. Then check the root crontab to ensure that the ispconfig cron.sh script is not disabled.
cron: * * * * * /usr/local/ispconfig/server/server.sh 2>&1 | while read line; do echo `/bin/date` "$line" >> /var/log/ispconfig/cron.log; done * * * * * /usr/local/ispconfig/server/cron.sh 2>&1 | while read line; do echo `/bin/date` "$line" >> /var/log/ispconfig/cron.log; done awstats: /usr/share/awstats/tools/awstats_buildstaticpages.pl is in place: root@web2:/home/rob# /usr/share/awstats/tools/awstats_buildstaticpages.pl ----- awstats_buildstaticpages 1.2 (build 20140126) (c) Laurent Destailleur ----- awstats_buildstaticpages allows you to launch AWStats with -staticlinks option to build all possible pages allowed by AWStats -output option. Usage: awstats_buildstaticpages.pl (awstats_options) [awstatsbuildstaticpages_options] where awstats_options are any option known by AWStats -config=configvalue is value for -config parameter (REQUIRED) -update option used to update statistics before to generate pages -lang=LL to output a HTML report in language LL (en,de,es,fr,...) -month=MM to output a HTML report for an old month=MM -year=YYYY to output a HTML report for an old year=YYYY and awstatsbuildstaticpages_options can be -awstatsprog=pathtoawstatspl AWStats software (awstats.pl) path -dir=outputdir Output directory for generated pages -diricons=icondir Relative path to use as icon dir in <img> links -builddate=%YY%MM%DD Used to add build date in built pages filenames -staticlinksext=xxx Build pages with .xxx extension (default .html) -buildpdf[=pathtohtmldoc] Build a PDF file after building HTML pages. Output directory must contains icon directory when this option is used (need 'htmldoc') New versions and FAQ at http://www.awstats.org
Next you can try to run the awstats cron plugin directly from shell as root: php cron_debug.php --cronjob=150-awstats.inc.php to check if the stats get generated then or if there are any errors on the shell when you execute it.
So i run that and this is output and stats are NOT updated..... root@web2:/usr/local/ispconfig/server# php cron_debug.php --cronjob=150-awstats.inc.php PHP Warning: Declaration of db::query($sQuery = '') should be compatible with mysqli::query($query, $resultmode = NULL) in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 961 finished.