Yup, I'm having trouble configuring BAWstats for Drupal-6.1; Apache2; mysql5; awstats 6.5x.
awstats generates useful stats already. It's installed and works. However, since this is Debian, bits of the distribution are installed all over the filesystem. I suspect this is - at core - what's going wrong... probably either permissions or php being unable to access the requisite files.
statsdir = /var/lib/awstats/dbfile.txt
statslibs = /usr/share/awstats/lib
lang = /usr/share/awstats/lang
icons =/awstatsicons (apache alias to /usr/share/doc/awstats/icons)
This is configured in docroot/modules/bawstats/config.php as well as in the drupal module admin config.
The primary awstats.pl lives down /usr/lib/cgi-bin (which is also aliased, though I've removed execute bits from the file name)
As I said, I'm generating stats via cron no problem. But I get absolutely no stat data from the bawstat module.
Regarding filesystem permissions: The web user (www-data) has read access down all awstats paths (verified).
I've read the awstats, bawstats, and bawstats module docs and feel like I'm banging my head against a wall now. I'm guessing: php can't read outside the docroot filesystem, but ....
Ideas? Should I just wipe the debian awstats package and install from source down /usr/local (where everyone expects it to live)?
Comments
Comment #1
maynard commentedoutput from config.php with debug set to true
Trying to read library data (OSHashLib) from file: /usr/share/awstats/lib/operating_systems.pm
Trying to read library data (DomainsHashIDLib) from file: /usr/share/awstats/lib/domains.pm
Trying to read library data (RobotsHashIDLib) from file: /usr/share/awstats/lib/robots.pm
Trying to read library data (Array) from file: /usr/share/awstats/lib/worms.pm
Trying to read library data (Array) from file: /usr/share/awstats/lib/mime.pm
Trying to read library data (Array) from file: /usr/share/awstats/lib/browsers.pm
Trying to read library data (SearchEnginesHashLib) from file: /usr/share/awstats/lib/search_engines.pm
Trying to read library data (httpcodelib) from file: /usr/share/awstats/lib/status_http.pm
trying to detect language
detectd language: en reading language data: /usr/share/awstats/lang/awstats-en.txt
finished reading language dataparsing Directory /var/lib/awstats/
found file dnscachelastupdate.hash
found file awstats032008.txt
finished parsing Directory /var/lib/awstats/
Comment #2
maynard commented# /usr/lib/cgi-bin/awstats.pl -config=daduh.org -upda
Update for config "/etc/awstats/awstats.conf"
With data in log file "/var/log/apache2/daduhorg.access.log"...
Phase 1 : First bypass old records, searching new record...
Direct access after last parsed record (after line 3217)
Jumped lines in file: 3217
Found 3217 already parsed records.
Parsed lines in file: 1090
Found 0 dropped records,
Found 0 corrupted records,
Found 0 old records,
Found 1090 new qualified records.
root@daduh:/usr/lib/cgi-bin#
Comment #3
maynard commentedAnd this is the output when I attempt to viwe bawstats as the drupal admin (yes, the module is turned on and role permissions are set)
View Site Statistics
No statistics found for site daduh.org 03/2008
Comment #4
maynard commentedInstalled awstats 6.8 from a source tarball, configured as directed, and now bawstats works. A few points:
- bawstats pukes on the data if awstats generates its report in xml format. Must be saved as text format or no go.
- the bawstat module does not add a link and text entry in /admin, but it does in the side block menu. If your admin theme is set to the default (Garland) it doesn't show the blocks and you can't get to the reports (without knowing the explicit URL).
- Module does not test for crazy paths listed in config.php. As a result, if the wrong paths are listed a bunch of garbage text is spewed when attempting to load the module config (to - say - change these paths to the new and correct ones).
Hope this helps the next Debian 4 user...
Comment #5
anaru commentedExcellent debugging work, thanks very much. I will amend the documentation regarding text vs XML formats, and will make changes to the module to move the menu paths under the "reports" admin group. I am in the final stages of merging major changes from the upstreamm betterawstats, and once that is done I will submit a new development branch with all the changes.
Comment #6
wiszmaster commentedwhat is the explicit URL of the stats?
I'm running a modded version of the aquasoft theme, I don't have links for the bawstats anywhere.
I enabled the module, but nowhere under the administration section do i show the bawstats module, reports or config.
I manually configured it, and when i give the index.php access, i can view the stats just fine.
--marco
Comment #7
anaru commentedIn the current version it is admin/bawstats
but as others, like you can't find this in certain themes, I will put it under reports in the next release. The next release is almost ready, it has lots of changes from the upstream betterawstats, and I should have it here in about a week.
Comment #8
anaru commentedThis has now been fixed in the latest version.