Piwik just stopped logging


#1

Hi,

I wonder if anyone can help me please?

I have been running Piwik successfully for a while, but noticed recently that all logging had stopped. It would seem that after a recent upgrade, there was a change required for the tracking code…

Anyway, I have now modified the tracking code and uploaded both Java and image variants to the website and can confirm this is appearing in the page content.

Now the only visits being logged are my own, and most strangely the IP recorded is my internal one [192.168.1.127], not the external IP as appearing from my ISP.
Fortunately I have been running another logging service on the remote site so I can see that visitors haven’t stopped! I have tried going through a proxy but that wasn’t recorded by Piwik either but it was logged by the other service.

Help!


(Matthieu Aubry) #2

check in your tracking that it references the right Domain / URL for your piwik


#3

Yes, I have done that already.

Incidentally, I checked another one of my sites that isn’t being tracked and which still has the earlier tracking code - they all point to the same correct URL as does the upgraded code.

BTW I performed a Systems Check to see if a recent update has mysteriously disabled write access to any folders and all checks are showing as green and OK.

All my sites are flat-lined around 15th Feb when I performed the previous upgrade. The automated emails stopped a few days after this.

i should add, that there have been no changes to the server here, nor any of the remote website installations for many months.


(Matthieu Aubry) #4

Maybe you can try to load the website from a different computer (where it won’t be tracked by piwik) and use firebug (in firefox) to debug the request ? And maybe you will find some info about the problem. See also Tracking HTTP API: API Reference - Matomo Analytics (formerly Piwik Analytics) - Developer Docs - v3


#5

Sorry, I don’t understand "Maybe you can try to load the website from a different computer (where it won’t be tracked by piwik) "

I’m calling the remote website from different computers, which route from here via my ISP to the site. I also have tried routing to a proxy and then on to the same site, thus appearing to arrive from the other side of the World, and the alternative logging shows accurately all visits.

I should explain that Piwik is on a separate server here, and not on the PCs used to access the internet, possibly that is what you mean by “…where it won’t be tracked by piwik” ?

What I dont understand is why suddenly everything stops, when I have done absolutely nothing to the server setup, nor the remote sites - everything was just humming along quietly.

Were there any warnings to upgrade the tracking code during the last two updats? If so I must have missed it!

I already have debugging services loaded into Firefox, so will look into the situation and get back.

Cheers.


#6

Sorry, getting absolutely nowhere.

I really would appreciate a response to my comment that nothing has changed, other than an upgrade and that all 15 sites have flat-lined.

Also I followed the steps in “Debugging the Tracker” but where does the output appear? Is it a file or what?

All I’m getting is logging of my own internal IP address of 192.168.1.127 when I visit the site, and not my ISP’s ‘outside’ IP. I not getting any of the other the legit IPs from other visitors, both human and robot [Googlebot] etc.

Am I the only who has lost all communications? All I did was upgrade to the latest version!


#7

More info:

I remembered that one of my sites runs Wordpress and uses the WP-Piwik plug in. This site also doesn’t show anything other than the occasional internal IP [192.168.1.127] The plug-in had been updated a little while ago.

So I visited said plug-in and it gave me a warning “An error occured: Piwik did not answer. Please check your entered Piwik URL”

This I did and it was fine. However I manually entered the URL into the browser

http://my.domain/piwikanalytics/piwik.php?idsite=2

Which produced the following:


INFO Piwik\Tracker[2014-03-16 10:00:04] [4e81a] ---------------------------

INFO Piwik\Tracker[2014-03-16 10:00:04] [4e81a] INIT

INFO Piwik\Tracker[2014-03-16 10:00:04] [4e81a] Querying Piwik API at: http://my.domain/piwikanalytics/index.php

INFO Piwik\Tracker[2014-03-16 10:00:04] [4e81a] Running Piwik 2.1.0 as Super User: supervisor

INFO Piwik\Tracker[2014-03-16 10:00:04] [4e81a] ERROR: Got invalid response from API request: http://my.domain/piwikanalytics/index.php?module=API&method=API.getDefaultMetricTranslations&format=original&serialize=1&trigger=archivephp. Response was ‘Got invalid response from API request: http://my.domain/piwikanalytics/index.php?module=API&method=API.getDefaultMetricTranslations&format=original&serialize=1&trigger=archivephp. The response was empty. This usually means a server error. This solution to this error is generally to increase the value of ‘memory_limit’ in your php.ini file. Please check your Web server Error Log file for more details.’

INFO Piwik\Tracker[2014-03-16 10:00:04] [4e81a] ERROR: The Piwik URL http://my.domain/piwikanalytics/index.php does not seem to be pointing to a Piwik server. Response was ‘’.


I was pretty sure the memory was OK, and checked php.ini to confim it is set to 1Gb

The server log replicated the above message. So a question; after the upgrade of Piwi, is there something I should ‘turn on’ to start the Piwik server?

Hope this helps.


#8

I have a couple suggestions to check into… I ran into some similair problems and to give a brief explanation of my problems. I had piwik installed into a directory that was only accessible to the local network for administration purposes. What I had forgot was when a user accesses my site it should load piwik.js and piwik.php from the location that was local network only. I have sense made it so those files were accessible to the public users which made my logging work correctly again.

So my questions are,
Have you checked your access log to make sure there are no issues. When a user loads your website do you see those two files load with a 200 response?

The other issue I could see, if you just upgraded Piwik and something went wrong with holding site IDs it’s possible your wordpress plugin is holding the old siteid while your piwik server has a different siteid.
For this check: Wordpress -> settings -> wp-piwik -> tracking and check the tracking code preview window and find the set siteid number
Match this too
Piwik server -> settings -> websites -> ID next to wordpress site
They should match if they don’t then that is your problem.


#9

Red face time!

After much fiddling and fumbling the following has been discovered: On 20th Feb my Virgin ‘Super*’ hub decided to switch from essential ‘modem’ mode to punter-router mode. The result of which effectively added an additional layer bewteen the Real World and my DD-WRT-based router, thus appearing to ‘block Port 80’ and therefore any external access to my server ceased, including the frequent call in from the various websites running Piwik.

This was somewhat confusing because all internet access remained fully working and locally generated HTTP calls to the server were routed locally and not out via my ISP then back in. This meant I believed the service was working and also why Piwik was recording my local IP address.

Thanks to jwhostet whose comments really helped me focus both brain-cells!

N


#10

They seem pretty sneaking but I’m glad I was able to help in some form or another. I myself just ran into another problem with loggin issues. I haven’t had much time to look into it but I may have to create another post! Anyways happy loggin!