| Версия для печати темы
Нажмите сюда для просмотра этой темы в оригинальном формате |
| Форум программистов > Администрирование Web серверов и Web служб > Настройка awstats |
| Автор: vintyara 13.1.2007, 17:06 |
| Сабж. ОС - slackware 11. При компиляции, было сказано засунуть в крон /usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=vint.od.ua Вот что появляется, если запустить эту штуку: root@pingvin:/var/lib# /usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=vint.od.ua Create/Update database for config "/etc/awstats/awstats.vint.od.ua.conf" by AWStats version 6.6 (build 1.887) From data in log file "/var/log/apache/access_log"... Phase 1 : First bypass old records, searching new record... Searching new records from beginning of log file... 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 /var/log/apache/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: 111.22.33.44 - - [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): 192.168.0.2 - - [28/Nov/2006:22:15:50 +0200] "GET /COPYRIGHT.php HTTP/1.1" 200 29 Setup ('/etc/awstats/awstats.vint.od.ua.conf' file, web server or permissions) may be wrong. Check config file, permissions and AWStats documentation (in 'docs' directory). Настройки вроде как верны. Вот мой /etc/awstats/awstats.vint.od.ua.conf : LogFile="/var/log/apache/access_log" LogType=W LogFormat=1 LogSeparator=" " SiteDomain="vint.od.ua" HostAliases="vint.od.ua www.vint.od.ua 127.0.0.1 localhost" DNSLookup=2 DirData="/var/lib/awstats" DirCgi="/awstats" DirIcons="/awstatsicons" AllowToUpdateStatsFromBrowser=0 AllowFullYearView=2 EnableLockForUpdate=0 DNSStaticCacheFile="dnscache.txt" DNSLastUpdateCacheFile="dnscachelastupdate.txt" SkipDNSLookupFor="" AllowAccessFromWebToAuthenticatedUsersOnly=0 AllowAccessFromWebToFollowingAuthenticatedUsers="" AllowAccessFromWebToFollowingIPAddresses="" CreateDirDataIfNotExists=0 BuildHistoryFormat=text BuildReportFormat=html SaveDatabaseFilesWithPermissionsForEveryone=0 PurgeLogFile=0 ArchiveLogRecords=0 KeepBackupOfHistoricFiles=0 DefaultFile="index.html" SkipHosts="" SkipUserAgents="" SkipFiles="" SkipReferrersBlackList="" OnlyHosts="" OnlyUserAgents="" OnlyFiles="" NotPageList="css js class gif jpg jpeg png bmp ico swf" ValidHTTPCodes="200 304" ValidSMTPCodes="1 250" AuthenticatedUsersNotCaseSensitive=0 URLNotCaseSensitive=0 URLWithAnchor=0 URLQuerySeparators="?;" URLWithQuery=0 URLWithQueryWithOnlyFollowingParameters="" URLWithQueryWithoutFollowingParameters="" URLReferrerWithQuery=0 WarningMessages=1 ErrorMessages="" DebugMessages=0 NbOfLinesForCorruptedLog=50 WrapperScript="" DecodeUA=0 MiscTrackerUrl="/js/awstats_misc_tracker.js" ... (остальные параметры приводить не буду, ибо ИМХО оно не должно влиять на работу) Что не правильно ? |
| Автор: vintyara 13.1.2007, 17:32 |
| Подправил. Вместо LogFormat=1 поставил LogFormat=4. root@pingvin:/etc/awstats# /usr/local/awstats/wwwroot/cgi-bin/awstats.pl -update -config=vint.od.ua Create/Update database for config "/etc/awstats/awstats.vint.od.ua.conf" by AWStats version 6.6 (build 1.887) From data in log file "/var/log/apache/access_log"... Phase 1 : First bypass old records, searching new record... Searching new records from beginning of log file... Phase 2 : Now process new records (Flush history on disk after 20000 hosts)... Jumped lines in file: 0 Parsed lines in file: 10110 Found 8 dropped records, Found 49 corrupted records, Found 0 old records, Found 10053 new qualified records. oot@pingvin:/etc/awstats# Только в статистике, через веб морду, опять таки везде нули Добавлено @ 17:45 Разобрался. Каюсь, что создал зря топик. Кстате. Вот ответ, почему не работало, а за одно и вопросик - почему так происходит ? В адрессной строке браузера изменил адресс с http://192.168.0.1/cgi-bin/awstats/awstats.pl?month=01&year=2007&output=main&config=www.vint.od.ua&framename=index на http://192.168.0.1/cgi-bin/awstats/awstats.pl?month=01&year=2007&output=main&config=www.vint.od.ua&framename=index т.е. убрал www. Как и где это конфигурируется, чтобы было без www ? Или это от логов зависит ? Если заходили на мой сайт с www перед именем, то нулей бы небыло ? |