LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-12-2007, 12:49 PM   #1
ddenton
Member
 
Registered: May 2007
Posts: 114

Rep: Reputation: 15
Awstats not recognizing browsers or operating systems...


Hello forum...

I've had awstats 6.7 up and running for some time, on an RHEL 4 box. It's been analyzing access logs from an apache 2 installation on another server without any major issues.

Due to bureaucratic concerns, I couldn't get User Agent and Referrer logging turned on until recently.

I expected, after enabling the additional logging, to see these stats finally start populating in my summary report, but the product isn't reporting/parsing them somehow.

I then noticed that my LogFormat directive in the awstats conf file was still parsin based on the common log format, which doesn't include referrer or user agent. I changed the LogFormat directive, and it gives me the following:

Create/Update database for config "/etc/awstats/awstats.tb002.conf" by AWStats version 6.7 (build 1.892)
From data in log file "/opt/apache/logs/web100/access_log"...
Phase 1 : First bypass old records, searching new record...
Direct access after last parsed record (after line 68981)
AWStats did not find any valid log lines that match your LogFormat parameter, in the 50th first non commented lines read of your log.
Your log file /opt/apache/logs/web100/access_log must have a bad format or LogFormat parameter setup does not match this format.
Your AWStats LogFormat parameter is:
1
This means each line in your web server log file need to have "combined log format" like this:
<remote ip> - - [10/Jan/2001:02:14:14 +0200] "GET / HTTP/1.1" 200 1234 "http://www.fromserver.com/from.htm" "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)"
And this is an example of records AWStats found in your log file (the record number 50 in your log):
<remote ip> - - [12/Oct/2007:11:56:40 -0500] "POST <name of resource> HTTP/1.1" 200 2229
Setup ('/etc/awstats/awstats.tb002.conf' file, web server or permissions) may be wrong.
Check config file, permissions and AWStats documentation (in 'docs' directory).


I've come to realize that is because some entries in my log file don't have referrer or user agent info, because these entries are made by a custom application of ours. I'm hoping my only recourse isn't to somehow split the logs prior to being read by awstats, and to have two installs that will parse the logs using two different LogFormat's. Is there a way to get awstats to accommodate two different LogFormat directives, and have the info in the same report? Thanks in advance...

Last edited by ddenton; 10-12-2007 at 12:50 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
What other operating systems do you use? General General 17 02-15-2007 08:03 AM
2 operating systems junkano Linux - Newbie 8 01-24-2007 03:18 PM
Web Browsers not recognizing flash plugin lmcilwain Linux - Desktop 7 09-11-2006 11:03 AM
3 Operating Systems James_the_Great Linux - Newbie 10 08-23-2006 06:40 PM
Two Operating Systems PEDRO Linux - Software 1 01-28-2001 10:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:09 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration