Hi @danielrunvegan and @noseknowsnonotes,
Thank you for the details – and sorry for the hiccup. This update has proven very hard in terms of the vastly different dataset sizes but also contents people are using the plugin.
I have just pushed version 2.0.6 in which I believe the referrer migration will eventually finish, but it can take a while if you have traffic coming from many different sites.
Let me know please.
@dvankooten I have just upgraded to 2.0.6. Now when I click the “Migrate” button the site seems to reload and nothing happens. FYI, we had 163 different referrers in the last 28 days.
Hi @danielrunvegan – can you try by going to yoursite.com?koko_analytics_action=migrate_referrer_stats_to_v2 while logged in as an administrator, please?
Hi Danny
seems to get same error “Migrate” doesn’t work π
@dvankooten using the link you provided just redirects me to my blogs start page. I made the upgrade to 2.0.7. Now the migration starts after clicking the button, but it aborts with the same error message as before (in 2.0.5):
Error 503 Backend fetch failed
Backend fetch failed
Guru Meditation:
XID: 19576070
Varnish cache server
Hi @danielrunvegan,
That’s really weird. It may be re-assuring to know that the data migration only affects your existing historical data. Going forward, everything should already be in the new format so it’s not like your stat collection is currently being affected because of this.
I still want to fix it though, obviously! Do you have access to your database in some way? If so, could you please share with me the number of records in the wp_koko_analytics_referrer_urls table? And maybe the result of the following database query?
SELECT COUNT(*) FROM wp_koko_analytics_referrer_urls WHERE url LIKE 'http://%' OR url LIKE 'https://%';
(If your table prefix is differently, please replace wp_ with your actual table prefix)
@dvankooten there are 40.336 records in the database. The result of the query is 38.750
@danielrunvegan Thank you. Would you be so kind to give the following version a try please? https://dannyvankooten-3.stack.storage/s/xAbKoPLZXRJJjHyy You can upload the ZIP file via WP Admin > Plugins > Add New.
@dvankooten I did, but the error persists.
@danielrunvegan Do you have access to WP CLI by any chance? I’m working on a version where users with very large datasets can initiate the migration from WP CLI environment, which typically has no time limit and larger memory limits than the web context a normal HTTP request is running in.
@dvankooten a quick research with my hoster says yes. I guess I am gonna learn something new soon π
I’m happy you’re embracing the challenge @danielrunvegan – sorry for the time this is taking. The version I’m sharing below (2.0.8-test2) has two changes that will hopefully help resolve your case.
- The migration will process your existing referrer data in batches of 500 rows instead of 1000.
- Alternatively, there is now a wp koko-analytics migrate_referrer_stats_to_v2 CLI command that you can run from your webhost server from any of the WordPress directories of your site which will run the same scripts as clicking the button does, just with more resources and no timeouts.
Download URL: https://dannyvankooten-3.stack.storage/s/7aNRLq2PNV5fRd5b
Let me know how that works for you please.
Thanks for trying to solve this issue @dvankooten ! I have installed the new test2 version and tried the migration via the button, but still get the same error page after a while. Will try the CLI command next, but have to read up on this (and drink my morning coffee) first, so it may take a while.