Archiving

we are trying to set up Archiving on a shared host. we have shell access and have set up a cron job but the archive.sh script does not run. we get a copy of the script in an e-mail.

[size=x-small]edit[/size] copy of the cron
MAILTO="mail@example.com"
5 * * * * /usr/bin/php5 /kunden/homepages/XX/XXXXXXXXXX/htdocs/example/analytics/piwik/misc/cron/archive.sh

if we try testing the script, as in the help, the script does not run.

file permissions are set to 755 where necessary
we are using php 5.2.17

we spoke to our host but they we not much help, their answer…

“To execute php files from the shell, just run php or php5 . It would seem archive.sh is not a valid php file if you are getting that error.”

see How to Set up Auto-Archiving of Your Reports - Analytics Platform - Matomo your cron entry is not correct (shouldn’t have php5 execute it)

Matt

i have set up the cron again (removed the php5 bit)

MAILTO="mail@example.com"
5 * * * * /kunden/homepages/XX/XXXXXXXXXX/htdocs/example/analytics/piwik/misc/cron/archive.sh

but now we are getting a mail with

/bin/sh: -
: invalid option