Summary: | periodic daily sleeps even when invoked from a terminal | ||
---|---|---|---|
Product: | Base System | Reporter: | Martin S. Weber <freebsd-bugzilla> |
Component: | bin | Assignee: | Alan Somers <asomers> |
Status: | Closed FIXED | ||
Severity: | Affects Only Me | CC: | asomers |
Priority: | --- | Flags: | asomers:
mfc-stable11+
|
Version: | 10.3-RELEASE | ||
Hardware: | Any | ||
OS: | Any |
Description
Martin S. Weber
2016-06-10 10:07:22 UTC
Looks like this behavior was added back in 2000 by revision 65843, probably unintentionally. A commit references this bug: Author: asomers Date: Sat Apr 1 04:42:35 UTC 2017 New revision: 316342 URL: https://svnweb.freebsd.org/changeset/base/316342 Log: Consolidate random sleeps in periodic scripts Multiple periodic scripts sleep for a random amount of time in order to mitigate the thundering herd problem. This is bad, because the sum of multiple uniformly distributed random variables approaches a normal distribution, so the problem isn't mitigated as effectively as it would be with a single sleep. This change creates a single configurable anticongestion sleep. periodic will only sleep if at least one script requires it, and it will never sleep more than once per invocation. It also won't sleep if periodic was run interactively, fixing an unrelated longstanding bug. PR: 217055 PR: 210188 Reviewed by: cy MFC after: 3 weeks Differential Revision: https://reviews.freebsd.org/D10211 Changes: head/etc/defaults/periodic.conf head/etc/periodic/daily/480.leapfile-ntpd head/share/man/man5/periodic.conf.5 head/usr.sbin/periodic/periodic.sh A commit references this bug: Author: asomers Date: Mon Apr 24 15:29:18 UTC 2017 New revision: 317373 URL: https://svnweb.freebsd.org/changeset/base/317373 Log: MFC r316342, r316358 r316342: Consolidate random sleeps in periodic scripts Multiple periodic scripts sleep for a random amount of time in order to mitigate the thundering herd problem. This is bad, because the sum of multiple uniformly distributed random variables approaches a normal distribution, so the problem isn't mitigated as effectively as it would be with a single sleep. This change creates a single configurable anticongestion sleep. periodic will only sleep if at least one script requires it, and it will never sleep more than once per invocation. It also won't sleep if periodic was run interactively, fixing an unrelated longstanding bug. PR: 217055 PR: 210188 Reviewed by: cy MFC after: 3 weeks Differential Revision: https://reviews.freebsd.org/D10211 r316358: Fix man page typo from r316342 Reported by: rgrimes MFC after: 20 days X-MFC-With: 316342 Changes: _U stable/11/ stable/11/etc/defaults/periodic.conf stable/11/etc/periodic/daily/480.leapfile-ntpd stable/11/share/man/man5/periodic.conf.5 stable/11/usr.sbin/periodic/periodic.sh |