On 2015-03-25 08:44, Morten Brekkevold wrote:
Any ideas appreciated!
I immediately have one:
Spot on!
Load down from 60 to less than 1, number of timeouts for the last 20 minutes are down to 10, most of them similar to this one:
2015-03-25 17:19:01 CET LOG: duration: 7756.695 ms statement: SELECT ijl.* FROM ipdevpoll_job_log AS ijl JOIN ( SELECT netboxid, job_name, MAX(end_time) AS end_time FROM ipdevpoll_job_log GROUP BY netboxid, job_name ) AS foo USING (netboxid, job_name, end_time) JOIN netbox ON (ijl.netboxid = netbox.netboxid) WHERE success = 'f' ORDER BY netboxid;
Removing the trigger will cause your ipdevpoll_job_log table to grow indefinitely, however. If this alleviates your problem, it's a strong indicator that we shall have to find another way to prune this table.
I'm quite found of cron for tasks like that, but I'm not a database person so the preferred solution from that point of view might be a bit different ;)
The table seems to be growing quite fast, not that it's a big issue with 43GB to spare on the postgres-partition, but I can see a need for cleaning the table on a regular basis.
Thanks for helping out, most appreciated. We only do electronic postcards, and at Christmas, but I'll drop one in your direction in a few minutes since the generator is still available on your intranet for last Christmas :)
Cheers!
-Sigurd