Incorrect Visitor Statistics after upgrade to 3.8.1


(captoula) #1

Hi,
I have a a strange problem. After upgrading from 3.6.0 to 3.8.1, statistics of visitors and unique visitors per hour or day are shown lower that real amount,

I have invalidated and re-archived the reports but no change. The data still about half of the amount it should be.

I know the data is invalid because:

  • The amount dropped abruptly after the upgrade
  • This happened for all of my sites
  • Real-time visitor count data is inconsistent with overall data
  • Page counts are still like before but visitor count shows about 40 percent decrease

Thanks


(captoula) #2

I see about 50 visits in real time visitor widget per minute in average for one of my sites which is consistent with about 80,000 visitor per day that I used to have before the upgrade.

Any Ideas about what might be the problem?


(captoula) #3

“Real Time Visitor Count” Widget is about 50 per minute in average but “Visits Over Time” Widget

“Real Time Visitor Count” Widget should be correct but even “matomo_log_visit” is consistent with “Visits Over Time” Widget.

This happened exactly after upgrade

No changes in “Page Views”
“actions per returning visit” suddenly changed from 5.4 to 20.1
“average visit duration for returning visitors” abruptly risen to 20 min from about 5 min

After upgrade, my visit per day reduced to a third but page views and other statistics remained the same.

Any ideas?


(captoula) #4

Apparently problem was that several visitors were aggregated “under the same visit mistakenly”. All visitors, except some of the “returning visitors” had the same IP Address (my HAProxy address).

This can be fixed by setting trust_visitors_cookies = 1 in config.ini.php

For my case it was solved by setting proxy_client_headers[] = HTTP_X_FORWARDED_FOR for matomo to detect the correct IP Address of the visitors from HAProxy after the upgrade, you can refer to: How do I configure Piwik when the server is installed behind a proxy? FAQ - Analytics Platform - Matomo