Skip to content

The leap second caused a scheduled job to run twice #30

@bdesham

Description

@bdesham

I have a job that is scheduled to run at 0 0 1 * *, i.e. at midnight at the beginning of each month. This worked as expected until this past January 1, when the job ran twice. PostgreSQL reports that the task ran at the following times:

  • 2016-12-31 23:59:59.070603+00
  • 2017-01-01 00:00:00.006794+00

For comparison, the most recent normal run happened at 2016-12-01 00:00:00.006968+00.

I assume that the culprit was the leap second that was inserted at the end of 2016-12-31: there was a 23:59:60 on that day.

This happened under Ubuntu 14.04.5. The machine uses NTP (with, I believe, whatever the default Ubuntu configuration is) to keep its time in sync.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions