No new data transferred since auto-archiving by activating cronjob
-
I set up a webcron as cronjob (every hour) and changed the archiving settings on piwik’s site as it is documentated there. Webcron has been tested and works, also Piwik itself still records data.
This new data just does not appear within this plugin since then. Did I miss any settings?
Thanks for any help!
-
Did you check if the connection still works? Have a look at your auth token and its permissions… maybe something changed?
Changes related to Piwik’s archiving should not affect WP-Piwik in any way. But of course data in WP-Piwik may be shown with a delay?
Thanks for your reply!
No settings in piwik changed to my knowledge. Cronjob works with the correct auth token.When switching back the archiving of reports when viewed from browser to “yes”, past and new data is displayed again.
When set to “no” with 3600seconds there is permanently no data is there except “visitors in real-time”. No delay of data.How/where do I check permissions of my auth token?
Ok, does not sound like an permission problem.
Can you please check if the Piwik API works as expected?
Login to Piwik, go to Help -> API. There you find several API categories like Actions or VisitsSummary and their methods. Behind each method you can see example links in several formats. Can you please try some of these examples (the format does not matter) while archiving is activated… does the API methods deliver the expected current results?
If so, please try WP-Piwik’s test script next, see in WordPress: Settings -> WP-Piwik -> Support -> Run test script, and check its results.
Thanks!
Piwik API delivers current results when archiving reports is set to “Yes”.
I do not see any salience at the test script. If I know how/where it’s the best to post the result, I’d be happy to have another check.But it came to my mind that I changed something after all. It’s the website’s admin user I had to change in the meantime (created a new one & deleted the old). Could this be causing it?
Just have a look at the test script’s result – e.g., do you see a list of your websites? In this case everything seems to be ok. If you like, you can post the results here (replace your domain name if you don’t want to show it here)… just post it between code tags so it won’t break this page. ??
Changes related to the website users inside Piwik may cause a changing auth token… but in this case, you also won’t get results if archiving is disabled. (Changes to your WordPress’ admin user should not affect the Piwik connection.)
Two more ideas:
- Can you try to disable WP-Piwik’s caching (see expert settings) and then access your statistics again with archiving activated?
- Can you try to increase WP-Piwik’s timeout (see expert settings)? Activating the archiving will cause Piwik performing the archiving with every access… maybe this just takes too long? If so, did you try to enable archiving via cronjob? I’m archiving this way and it works great.
This weekend, I will also try to do some testing with activated archiving.
thanks,
here is the test script: https://pastebin.com/ASzLdY9J
increased timeout in expert settings from 5 to 15seconds and
disabled caching -> statistics still there (also at help->API links)
I’ve got a webcron running only as my host does not support cronjob by default so I cannot test it with an usual cronjob.Hm, everything looks like expected.
Just to collect our findings:
- If you disable browser-triggered archiving, no results are shown inside WP-Piwik.
- Inside Piwik itself, all data are shown as expected.
- If you re-enable browser-triggered archiving, WP-Piwik starts working again (= shows data).
- If you try the API example links shown by Piwik, everything looks like expected (no matter if browser-archiving is activated or not).
- Your test script output (created with disabled browser archiving?) also looks like expected.
I tried to configure several archiving scenarios, but none of them affected the data shown in WP-Piwik… what’s shown in Piwik is also shown in WP-Piwik. Really strange issue, especially if the API output continues working. Can you please also post an example API output (generated while WP-Piwik is not working)? Maybe I can find a difference.
One more question: You write “visitors in real-time” keeps working, but WP-Piwik does not show a “visitors in real-time” statistic… can you explain what you mean with this? Thanks!
ok, just made a new test.
If you disable browser-triggered archiving, no results are shown inside WP-Piwik.
yes, plugin shows no data.
Inside Piwik itself, all data are shown as expected.
no, the only data shown in Piwik itself is “visitors in real-time”. all other modules seen in dashboard stop showing data when disabling browser-triggered archiving. With these modules I mean “visits over time” (the graph), “visits by server time”, “visitor map”, “visitor browser”, “referrer websites”, “search engines” and “length of visits”)
If you re-enable browser-triggered archiving, WP-Piwik starts working again (= shows data).
yes, also shows data for the time browser-triggered archiving had been disabled. this happens in piwik itself as well as in wp-piwik.
If you try the API example links shown by Piwik, everything looks like expected (no matter if browser-archiving is activated or not).
no, here I have to correct my findings above saying Piwik API delivers current results when archiving reports is set to “Yes”. Piwik API does not collect new data. It just shows old data up to then I enable browser-triggered archiving. When disabling, Piwik API collects new data.
You write “visitors in real-time” keeps working, but WP-Piwik does not show a “visitors in real-time” statistic…
Sorry, with “visitors in real-time statistic” I meant all data except “visitors in real-time” which on the dashboard is seen as: visits over time (the graph), by server time, map, browser, referrer websites, search engines and length of visits. All of these deliver no new data when browser-triggered archiving is enabled.
Thanks for helping!
no, the only data shown in Piwik itself is “visitors in real-time”. all other modules seen in dashboard stop showing data when disabling browser-triggered archiving
So there seems to be something wrong with your cronjob to trigger the archiving. WP-Piwk can’t show data as long as it does not appear in Piwik itself.
Sadly, I can only give support related to the WP-Piwik plugin and not to Piwik’s own archiving process. Please ask the Piwik community about this: https://forum.piwik.org
(Btw I’m quite sure Piwik is still collecting data; just the processing is not triggered and so the data is not shown.)
Thanks a lot for your helpful support anyway!
I’ll report it as soon as possible at the piwik forum.
- The topic ‘No new data transferred since auto-archiving by activating cronjob’ is closed to new replies.