Piwik.php first visit logging call taking 4 seconds or more


(Saqib Ali) #1

Hi,

Can anyone suggest solution to following problem:

Piwik is working great but now we have been noticing that first piwik.php visit logging call taking 4 seconds and above but after the first visit it is taking time in milliseconds.

Why is this difference and how it can be minimized.
we are noticing this by using firfox firbug.

Kind Regards
Saqib Ali


(Matthieu Aubry) #2

See 301 Moved Permanently


(Faisal Iqbal) #3

Hi matt,

I am facing the same issue. First logging request taking about 5 seconds and next time 50 millisecond. Can you help how to improve this performance. I have tried by disabling the report archiving but same delay.
Is there any other scheduled task that I can disable.

Regards,
Faisal


(Faisal Iqbal) #4

Hello,

I have disabled report archiving but still getting 5 seconds response time on first request. any idea?

Regards,
Faisal


(Matthieu Aubry) #5

It should take 5 seconds only in the first request of the day or the hour.
Also see: Optimize and Scale Piwik - Analytics Platform - Matomo

also enabel PHP cache


(Faisal Iqbal) #6

Hi Matt,

I have debugged the code and found Provider plugin is taking 4.5 seconds to get the ISP name. Is there any performance issue with this plugin?

Regards,
Faisal


(Matthieu Aubry) #7

Yes it does a reverse DNS lookup which can be slow if your DNS server is slow. you may disable the Provider plugin.


(Saqib Ali) #8

Thanks Matt.

This helped me a lot.


(Matthieu Aubry) #9

Cool, i also update the user guide: How to configure Piwik for speed - Analytics Platform - Matomo

and noted: [quote=“user guide”]
Alternatively, for optimal performance you may disable the Provider plugin and skip the potentially slow reverse DNS lookup.
[/quote]


#10

Hi Matt,

Piwik.php request first logging is taking some 10sec, as per the discussion , disabled Provider plugin but still the same issue, kindly suggest.

Thanks,


(Matthieu Aubry) #11

can you enable debug messages: Tracking HTTP API: API Reference - Matomo Analytics (formerly Piwik Analytics) - Developer Docs - v3

and paste here the output?


(Saqib Ali) #12

Hi kkbtech ,

Have you enabled php cache…?

Regards,
Saqib