[collectd] long sleeps when using collectd and ntpd
mertelo1 at axsguard.net
Tue Sep 24 10:53:02 CEST 2013
We have some problems using collectd and ntpd.
Whenever ntpd sets the clock in the past (because of a clock drift),
collectd sleeps until it is back at it's 'normal' time.
To give an example:
- Suppose it's 10:00am,
- ntpd sees a large clock drift and set the clock to 09:45am
- collectd will sleep till 10:00am
When trying to debug the problem, we found that the do_loop function in
collectd.c determines the amount of time to sleep based on times
abtained from the "gettimeofday" function. Was this a design choice?
Wouldn't it be better to use a monotonic clock?
More information about the collectd