Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
[dev.icinga.com #2951] fix deleting too old check result files #1066
This issue has been migrated from Redmine: https://dev.icinga.com/issues/2951
Created by mfriedrich on 2012-08-05 11:20:01 +00:00
this is a rather common issue - the checkresult dir does not get cleaned after the core reaps the files, and leaves files there, slowing down the overall processing.
as the original diff describes, the initial problem are the "write the checkresult to tmp dir, then move it to checkresult queue, and put a .ok file there as well, telling the core checkresult reaper that files are totally fine to be read". on frequent reloads, this will cause a lot of "not yet finished" checks to stay within the queue, but not having the .ok file there.
the core algorithm on checking if a file is ok, requires to loop all files and stat() if the .ok file is there - which is normally a lot of misses because those old checkresult files won't even be processed anymore. and who got a manual cronjob cleaning that, when the core should do?
that patch should be cherry-picked into 1.8.x trees as well, when done testing.
2012-08-05 11:24:55 +00:00 by mfriedrich 13b11a984d715516414dde3bb706b8e4a6535972
2012-08-07 13:30:33 +00:00 by mfriedrich f63541d
2012-08-19 17:42:11 +00:00 by mfriedrich e06dadc