Bug #4882
Updated by Tom Clegg over 9 years ago
h3. Background
source:services/crunchstat/crunchstat.go has a list of locations where cgroup accounting files are likely to be found. Historically this was needed because the location varies from one kernel/system to another. Each time crunchstat reads stats, it tries each location in turn until it finds one that exists. When the target container is up, this works fine, but the last two locations give accounting information for the host instead of the container. Often, crunchstat tries to read accounting data before the container has come up or after the container has been destroyed (in the interval before it gets notified that the docker process has exited). Naturally, the transition between host stats and container stats results in reporting wild deltas.
The transition from one stat file to another causes an "error" log message which is easy to misinterpret as an error affecting the job, or explaining some later job failure -- see #5523.
h3. Proposed fix
One or more of:
* Don't report host-level stats if container-level stats have ever been reported.
* Don't report host-level stats ever.
* When the previous sample point and the current sample point come from different accounting files, don't print a delta.
h3. Bug report
Originally reported as "Log graph goes out of bounds":
!log_graph_oob.png!
about 5/6th of the way through, you can see the yellow point go off the screen. Suggestion: maybe the graph should scale in real time... Hmm, I'm not sure because then the graph would keep scaling and would probably get annoying. It would still be useful to at least see that point though.