Attention: The script must run as the same user as the CGI scripts are running, which is user nobody on many systems. Example crontab entry: 0 0 * * * (cd /path/to/twiki/bin; ./statistics >/dev/null 2>&1)
There is a workaround in case you can't run the script as user nobody : Run the utility twiki/bin/geturl in your cron job and specify the URL of the twiki/bin/statistics script as a parameter. Example: 0 0 * * * (cd /path/to/twiki/bin; ./geturl mydomain.com /urlpath/to/twiki/bin/statistics >/dev/null 2>&1)
Added:
> >
When running from the command line or a cron job, you can pass parameters to the script like this:
./statistics -logdate 200605 -webs TWiki,Sandbox
Generating statistics manually by URL
The twiki/bin/statistics script can also be executed as a CGI script, just enter the URL in your browser. Examples:
Changed:
< <
Update current month for all webs: /wiki/bin/statistics
> >
Update current month for all webs you have access to: /wiki/bin/statistics
Update current month for Main web only: /wiki/bin/statistics/Main
Changed:
< <
Update January 2000 for Main web: /wiki/bin/statistics/Main?logdate=202505
> >
Update May 2025 for Main web: /wiki/bin/statistics/Main?logdate=202505
Update May 2025 for the ProjectX, ProjectY and ProjectZ webs: /wiki/bin/statistics?logdate=202505;webs=ProjectX,ProjectY,ProjectZ