Ammamit - 2011-05-21

Hello,

I need some help on getting awstats process my flash media server logs. No
matter what I try it seems to give some sort of the error.

Here is a snippet of my actual log file

#Version: 1.0

#Start-Date: 2011-05-18 08:08:34

#Date: 2011-05-18

#Fields: x-category,x-event,date,time,x-pid,c-ip,c-client-id,c-proto,c-connect-type,x-sc-qos-bytes,s-uri,cs-bytes,sc-bytes,x-sname,cs-stream-bytes,sc-stream-bytes,x-file-size,x-file-length,x-status,x-cpu-load,x-mem-load,x-comment

server,server-start,2011-05-18,08:08:34,9592,-,-,-,-,-,-,-,-,-,-,-,-,-,-,0,9,-

vhost,vhost-start,2011-05-18,08:08:34,9592,-,-,-,-,-,-,-,-,-,-,-,-,-,-,0,9,-

application,app-start,2011-05-18,08:08:34,9592,-,-,-,-,-,-,0,0,-,-,-,-,-,-,-,-,-

session,connect-pending,2011-05-18,08:08:34,9592,111.93.43.226,4852751105844659010,rtmp,normal,-,"rtmp://117.211.85.227/video_module/NMEICT-AVIEW-TEST",3073,3073,-,-,-,-,-,100,0,9,-

session,connect,2011-05-18,08:08:34,9592,111.93.43.226,4852751105844659010,rtmp,normal,-,"rtmp://117.211.85.227/video_module/NMEICT-AVIEW-TEST",3073,3073,-,-,-,-,-,200,0,9,-

#Date: 2011-05-18

#Fields: x-category,x-event,date,time,x-pid,c-ip,c-client-id,c-proto,c-connect-type,x-sc-qos-bytes,s-uri,cs-bytes,sc-bytes,x-sname,cs-stream-bytes,sc-stream-bytes,x-file-size,x-file-length,x-status,x-cpu-load,x-mem-load,x-comment

server,server-start,2011-05-18,08:08:35,10136,-,-,-,-,-,-,-,-,-,-,-,-,-,-,0,9,-

And here is what I have configured in the awstats.myserver.conf

LogType=S
LogFormat = "x-category,x-event,date,time,x-pid,c-ip,c-client-id,c-proto,c-connect-type,x-sc-qos-bytes,s-uri,cs-bytes,sc-bytes,x-sname,cs-stream-bytes,sc-stream-bytes,x-file-size,x-file-length,x-status,x-cpu-load,x-mem-load,x-comment"
LogSeparator=","

awstats.pl throws an error

Error: Your personalized LogFormat does not include all fields required by AWStats (Add %host in your LogFormat string).

I tried changing the LogFormat to

LogFormat = "x-category,x-event,date,time,x-pid,%host,c-client-id,c-proto,c-connect-type,x-sc-qos-bytes,s-uri,cs-bytes,sc-bytes,x-sname,cs-stream-bytes,sc-stream-bytes,x-file-size,x-file-length,x-status,x-cpu-load,x-mem-load,x-comment"

but still the same error. Looks like the awstats.pl is not parsing properly
when the log is in a CSV format and there are no spaces around the comma. Can
someone please help?