Better HN
topnewbestaskshowjobs
Log inSign up

runpkins

11 karma · joined Oct 27, 2021 (5y ago) · 1 submissions

Submissions

comment 5y ago · link · parent

The manual page is wrong. The UNIX clock is UTC, so DST transitions aren't a clock change, they're a local time discontinuity.

I'm pretty sure the article is wrong, too, because it implies that a DST transition won't cause cron jobs to be skipped or run twice. But it looks like the logic in Better-timeskip-handling.patch doesn't account for the possibility that the computer might be rebooted near a DST transition. Reboot immediately after the time falls back and it'll happily run the cron job a second time. The right way to handle this would have been to internally convert the crontab entries to UTC before scheduling them. It's surprising that OpenBSD (the origin of this patch) blundered this - usually they get the details right.