Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

archive.php never ends #3664

Closed
anonymous-matomo-user opened this issue Jan 12, 2013 · 2 comments
Closed

archive.php never ends #3664

anonymous-matomo-user opened this issue Jan 12, 2013 · 2 comments
Labels
Bug For errors / faults / flaws / inconsistencies etc. worksforme The issue cannot be reproduced and things work as intended.

Comments

@anonymous-matomo-user
Copy link

I setup things for the first time and imported all my logs and then setup a cronjob to run every day to archive things. I decided to test that before I left it for the night and found that it seemed to run ok, but it never ended, it is not dropping me back to the shell:

platypus# /usr/bin/php5 /var/www/piwik/analytics/misc/cron/archive.php -- url=http://example.com/analytics
21:53:29 [fecdd358] NOTE: if you execute this script at least once per hour (or more often) in a crontab, you may disable 'Browser trigger archiving' in Piwik UI > Settings > General Settings.
21:53:29 [fecdd358] see doc at: http://piwik.org/docs/setup-auto-archiving/
21:53:29 [fecdd358] ---------------------------
21:53:29 [fecdd358] INIT
21:53:29 [fecdd358] Querying Piwik API at: http://example.com/analytics/index.php
21:53:29 [fecdd358] Running as Super User: biella
21:53:30 [fecdd358] Notes
21:53:30 [fecdd358] - Reports for today will be processed at most every 10 seconds. You can change this value in Piwik UI > Settings > General Settings.
21:53:30 [fecdd358] - Reports for the current week/month/year will be refreshed at most every 3600 seconds.
21:53:30 [fecdd358] --force-all-periods was detected: we will process websites with visits in the last 7 days 0 hours
21:53:30 [fecdd358] Will process 1 websites with new visits since 7 days 0 hours , IDs: 1
21:53:30 [fecdd358] Will process 1 other websites because some old data reports have been invalidated (eg. using the Log Import script) , IDs: 1
21:53:30 [fecdd358] ---------------------------
21:53:30 [fecdd358] START
21:53:30 [fecdd358] Starting Piwik reports archiving...
21:55:23 [fecdd358] Archived website id = 1, period = day, Time elapsed: 113.494s

and it never returns to the shell... just continues to run.

I ran strace on the running process, and it seems to just be doing this over and over:

nanosleep({0, 10000000}, NULL) = 0
poll(events=POLLIN|POLLPRI}, 1, 0) = 0 (Timeout)
clock_gettime(CLOCK_MONOTONIC, {6711929, 814589512}) = 0
clock_gettime(CLOCK_MONOTONIC, {6711929, 814682115}) = 0
clock_gettime(CLOCK_MONOTONIC, {6711929, 814784751}) = 0
nanosleep({0, 10000000}, NULL) = 0
poll(events=POLLIN|POLLPRI}, 1, 0) = 0 (Timeout)
clock_gettime(CLOCK_MONOTONIC, {6711929, 825260632}) = 0
clock_gettime(CLOCK_MONOTONIC, {6711929, 825333662}) = 0
clock_gettime(CLOCK_MONOTONIC, {6711929, 825407120}) = 0
Keywords: archive.php

@anonymous-matomo-user
Copy link
Author

Apologies, things did end eventually... it took 1520.263s to run, which is a bit surprising for a site that got 2k hits in the last archive period, but it did finish, so please close this issue.

@mattab
Copy link
Member

mattab commented Jan 18, 2013

2k hits shouldn't take that long that's for sure/. how many page views? how many unique URLs?

if you can replicate the issue with this data, I would be interested to take a look...

Otherwise when it was polling like this, I suppose it was waiting or mysql to reply? have you checked the mysql SHOW FULL PROCESSLIST\g ?

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. worksforme The issue cannot be reproduced and things work as intended.
Projects
None yet
Development

No branches or pull requests

2 participants