[Typo3] awstat statistc update via cron ?

Steffen Müller steffen at mail.kommwiss.fu-berlin.de
Sat Oct 8 12:47:11 CEST 2005


On 08.10.2005 07:49 Christian Grams wrote:
>>Hi.
> 
> 
>>On 06.10.2005 11:36 Christian Leicht wrote:
>>
>>>Hello, is it possible to update the statistk via cron ?
>>>
>>>Whitch "Link" can i use for that ?
>>>
> 
> 
>>This script does the job on my server:
> 
> 
>>#!/bin/sh
>>#
>># Update AWstats via cli, cron, whatever.
>>#
>>export AWS_LANG=default
>>export AWS_DOMAIN=www.example.com
>>export AWS_DOMAINS=www.example.com
>>export AWS_LOGFILE=/path/to/apache_log
>>export GATEWAY_INTERFACE=
>>export AWS_DIR=./
>>export AWS_ICON_DIR=./icon/
>>export
>>AWS_CACHE_DIR=/path/to/typo3_directory/.awstats-data/www.example.com/
>>export AWS_WRAPPER=index.php
>>export AWS_CSS=awstats-11px.css
>>export AWS_BGCOLOR=#FFFFFF
>>export AWS_TBT_BGCOLOR=#ABBBB4
>>export AWS_TB_BGCOLOR=#D9D5C9
>>export AWS_TB_COLOR=#cfcbbf
>>export AWS_TBR_BGCOLOR=#e8e4d8
>>/path/to/typo3_directory/typo3conf/ext/cc_awstats/mod1/awstats.pl
>>-config=www.example.com -output -update=1
> 
> 
> Using this as a sh script i get the following as an error message:
> 
> # ./awstats.cron.sh
> Can't return outside a subroutine at /..../site/typo3conf/ext/cc_awstats/awstats/awstats.pl line 4.
> ./awstats.cron.sh: line 22: -config=www.sitename.de: command not found
> 
> Idea? .. and thanks for sharing your script!!
> 

Yeah, it's a linebreak.
The last two lines are one line:
/path/.../awstats.pl -config=www.example.com -output -update=1

if that still doesn't work, prepend the path to your perl interpreter:
/usr/bin/perl /path/.../awstats.pl -config=www.example.com ...

-- 
cheers,
Steffen



More information about the TYPO3-english mailing list