Awstats Cron job not executing
I am using Debian Lenny and installed awstats. Now by default the awstats creates a the following file:
debian:~# cat /etc/cron.d/awstats
0,10,20,30,40,50 * * * * www-data [ -x /usr/lib/cgi-bin/awstats.pl -a -f /etc/awstats/awstats.conf -a -r /var/log/apache2/access.log ] && /usr/lib/cgi-bin/awstats.pl -config=mydomain -update>/dev/null
The Syslog shows that the above job is being executed but my webpage stats (http://mydomain/awstats/awstats.pl) do NOT get updated.
However if I change the awstats cron job to be executed by "root" like this:
0,10,20,30,40,50 * * * * root [ -x /usr/lib/cgi-bin/awstats.pl -a
-f /etc/awstats/awstats.conf -a -r /var/log/apache2/access.log ]
&& /usr/lib/cgi-bin/awstats.pl -config=mydomain -update
>/dev/null
it gets executed every 10 mins and the webpage stats gets updated.
Based on /usr/share/doc/awstats/README.Debian, I have already given read permission for "others" user to access.log:
debian:~# ls -l /var/log/apache2/access.log
-rwr-r- 1 root adm 6671031 2009-10-26 18:00 /var/log/apache2/access.log
Not sure what am I missing?
Kushal Koolwal
I do blog at http://blogs.koolwal.net/
_________________________________________________________________
Windows 7: It helps you do more. Explore Windows 7.
http://www.microsoft.com/Windows/windows-7/default.aspx?ocid=PID24727::T:WLMTAGL:ON:WL:en-US:WWL_WIN_evergreen3:102009
Reply to: