Piwik 1.7.1 --url / archive.sh?


I start “archive.sh” in my site. Now that there’s that fix for “archive.php” I wonder why the updated docs do not mention the shell script any more.

Because we now recommend to use archive.php, archive.sh is deprecated but will still work probably forever


just found the french page about archive is always relating to archive.sh



What are the advantages of archive.php over archive.sh?

thanks for your help…

I am very interested in an answer to this last question, too.

I just tried to use archive.php but got this error message:

ERROR: this script requires curl extension php_curl enabled in your CLI php.ini

So I googled curl extension and found this

So my question is this: When I use archive.php, do I have a big fat security issue???

thanks for your answer

Enable CURL in your php.ini and try again

hey matt,
the question was: isn’t using curl a security problem?

Not an issue

Due to the configuration with my hosting provider I am forced to use archive.sh, if I use archive.php the requests take too long and timeout with a 503 error.

The server runs apache 2.4.x + mod_proxy + php-fpm 5.4.x

I have increased the timeouts for apache, mod_proxy, and php-fpm and still encounter this issue so my only option is to use archive.sh which doesn’t appear to throw any errors.

Any chance we’ll see updates/improves to archive.sh for those of us that are forced to use it?

Some additional information regarding my piwik setup, I have 10 websites with a combined daily total of 24,954 visits, 31,200 pageviews.

When it times out with 503 errors, what are the errors logged in the server error log file?

Okay so I finally I found the problem with running archive.php.

The 503 error is a result of mod_proxy timing out after 30 seconds. (the default timeout for proxy requests)

The problem is that the ProxyTimeout setting used by mod_proxy appears to have no effect in apache 2.4.4
(Either the apache documentation is misleading or perhaps this is a bug)

The solution is to set the mod_proxy timeout using the following method.

<Proxy fcgi://>
ProxySet timeout=300

Now I can run the archive.php script via cron again.

Interesting find thanks for reporting this problem and solution for apache 2.4.4 !


Is there a special reason why the Piwik archive function uses Curl, and do not process the data on the CLI / from archive.php directly?

Setting a timeout value of 5min (30s is pretty high already) on production systems can cause security risks.

The reason is in case the script is run from a different server