Can't run archive cronjob without login plugin

Well, I’ve overrided Login core plugin writing a custom authentication by following HttpAuthLogin plugin example.

Now I’ve discovered console core:archive command and misc/cron/archive.php script are failing because of an error:

INFO CoreConsole[2014-04-16 11:05:26] [582c7] ERROR: Got invalid response from API request: Response was 'a:2:{s:6:"result";s:5:"error";s:7:"message";s:126:"Non puoi accedere alla risorsa richiesta perché è necessario essere autorizzati per l'accesso 'view' per il sito con id = 1.";}'

In the Login plugin’s description cell (in plugins page) i can read: “Login Authentication plugin, reading the credentials from the config/config.ini.php file for the initial Super User, and from the Database for the other users. Can be easily replaced to introduce a new Authentication mechanism (OpenID, htaccess, custom Auth, etc.).”

Well, looks like my new authentication plugin can’t read superuser credentials from the config.ini.php and looks for first superuser into db but when it’s found, this user have any ‘view’ right on sites profiles because he’s superuser status.

Did you tested crontabbing using HttpAuthLogin? How can I run crontab using first installed superuser instead of DB superusers?

This is possibly a bug. If you can please create a ticket at:

No problem, I’ve filed a detailed bug report: #5012

No problem, I’ve filed a bug ticket in Development website.

#5012 Archive cronjob core:archive should run when Piwik is using a different Login plugin (eg LoginHttpAuth) · Issue #5012 · matomo-org/matomo · GitHub