Webalizer, Awstats, GoAccess all not working

Discussion in 'General' started by DivideByZer000, Dec 9, 2020.

  1. DivideByZer000

    DivideByZer000 New Member

    Hello,
    I've been running ISPConfig for some time. I am on the latest version on Deb 10. Awstats used to work on my server, but quit working several months ago. I'm not sure what would have happened then, but it is too long ago to look at logs or anything like that to see if I updated ISPConfig or did an OS update at that point. It would not have been a major upgrade.
    I have tried to re-enable stats for my sites and seem to be having an issue. I have disabled stats for all sites and re-enabled them. I orginally tried awstats, but after failing with that also enabled (and installed) webalizer and GoAccess. Enabling any of those options in the stats section of a site does not seem to make the stats appear.
    I can see the log files in the /log folder for each site but in the /web/stats/ folder I have only .htpasswd_stats and index.php. I can see that server.php is being run every minute in the /var/log/ispconfig/cron.log file and no errors appear. I have searched all the log files for instances of cron or awstats or webalizer or goaccess failing, but do not seem to see anything obviously wrong.

    It almost seems as if they are not even trying to run. Where else can I look to diagnose this? I originally set this up using the The Perfect Server - Debian 10 (Nginx, BIND, Dovecot, ISPConfig 3.1) guide. Any help would be greatly appreciated.
     
  2. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    Verify using Perfect Server Guide the stats applications are installed and configured as per that Guide.
     
  3. DivideByZer000

    DivideByZer000 New Member

    Yes, the applications are installed and I commented out the cron file.

    Code:
    bill@server:~$ sudo apt-get install webalizer awstats geoip-database libtimedate-perl libclass-dbi-mysql-perl
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    awstats is already the newest version (7.6+dfsg-2).
    geoip-database is already the newest version (20181108-1).
    libclass-dbi-mysql-perl is already the newest version (1.00-4).
    libtimedate-perl is already the newest version (2.3000-2+deb10u1).
    webalizer is already the newest version (2.23.08-3.1).
    0 upgraded, 0 newly installed, 0 to remove and 9 not upgraded.
    bill@server:~$ cat /etc/cron.d/awstats
    #MAILTO=root
    
    #*/10 * * * * www-data [ -x /usr/share/awstats/tools/update.sh ] && /usr/share/awstats/tools/update.sh
    
    # Generate static reports:
    #10 03 * * * www-data [ -x /usr/share/awstats/tools/buildstatic.sh ] && /usr/share/awstats/tools/buildstatic.sh
    
     
  4. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Try goaccess / webalizer and wait 24 hours so the stats are generated (this happens every night). Then see if it works or not. This way we can pinpoint if it's just AWStats or really all of them.
     
  5. DivideByZer000

    DivideByZer000 New Member

    Th0m, thanks for the reply. I have multiple sites and I have one with awstats, one with webalizer, and one with goaccess. It has been multiple days with them each set, each with no generated stats.
     
  6. DivideByZer000

    DivideByZer000 New Member

    Hello,

    Just curios if anyone has any thoughts on this?
     
  7. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Are the ISPConfig cronjobs enabled?
     
  8. DivideByZer000

    DivideByZer000 New Member

    Yes, I can see the log entry of "finished server.php." every minute which suggests that the isp cron program is firing. I have set other cron jobs that are also working.
     
  9. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Can you share the content of your crontab?
     
  10. DivideByZer000

    DivideByZer000 New Member

    Code:
    bill@server:~$ sudo crontab -l
    * * * * * /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
    0 0 * * * /usr/local/ispconfig/server/scripts/create_daily_nginx_access_logs.sh &> /dev/null
     
  11. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    And no errors in /var/log/ispconfig/cron.log?
    Can you run this and share the output:
    Code:
    php /usr/local/ispconfig/server/cron_debug.php --cronjob=150-awstats.inc.php
     
  12. DivideByZer000

    DivideByZer000 New Member

    Code:
    billi@server:~$ sudo php /usr/local/ispconfig/server/cron_debug.php --cronjob=150-awstats.inc.php
    finished cron debug.
    bill@server:~$ sudo php /usr/local/ispconfig/server/cron_debug.php --cronjob=150-webalizer.inc.php
    finished cron debug.
    bill@server:~$ sudo php /usr/local/ispconfig/server/cron_debug.php --cronjob=150-goaccess.inc.php
    finished cron debug.
    
    And nothing anomalous in the ispconfig/cron.log
     
  13. DivideByZer000

    DivideByZer000 New Member

    Actually, it would seem that running those commands generated some stat pages for all 3 software packages. So the code seems like it is running properly (at least with root access), it just isn't running automatically at night.

    I am tempted to just create a cron job using those commands if all else fails.
     
  14. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Can you share the whole cron.log?
     
  15. DivideByZer000

    DivideByZer000 New Member

    Attached. I truncated part of it as the file was too big. Some of the extra stuff you see in there is a MOTD script that shows a fortune and some other stuff with cowsays...
     

    Attached Files:

  16. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    You might try upgrading and reconfiguring services.
     
  17. SamTzu

    SamTzu Active Member

    Sounds like you have a modified Apache config that superseeds ISPconfig site settings.
    Do you have a proxy or reverse proxy running on that server?
    Try this...
    Code:
    grep -r 'Proxy' /etc/apache2/sites-available/ |more
    See if you see any "localhost" entries there?
     
  18. DivideByZer000

    DivideByZer000 New Member

    I'm using nginx, but I have not changed the config beyond what ispconfig creates, except for a few https options and options for wordpress.
     
  19. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Did you update to 3.2.1? Can you share those options?
     

Share This Page