https://bz.apache.org/bugzilla/show_bug.cgi?id=63253

            Bug ID: 63253
           Summary: Rotatelogs using yesterday's date in file name on day
                    of daylight savings change
           Product: Apache httpd-2
           Version: 2.4.38
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: support
          Assignee: [email protected]
          Reporter: [email protected]
  Target Milestone: ---

Hi,

I restarted my apache instance today (3/10/2019) and the log file name being
generated is from yesterday (3/9/2019). I am using local time and rotatelogs is
being started like this:

    rotatelogs -l access_log.%Y-%m-%d 86400

The file name at 11:AM on Sunday March 10, 2019 (Eastern time) is:

    access_log.2019-03-09

I suspect the problem originates on line 392 of rotatelogs.c:

    tLogStart = (now / config->tRotation) * config->tRotation;

I think this results in the start time being 11:00PM from yesterday instead of
midnight, today.

tLogStart is used to format the log file name and today (3/10/2019), the clocks
were moved forward, so there is one less hour in the day. I am hoping the
problem will fix itself tomorrow when there will have been 24 hours in the day.

Thanks for your contributions to this project.

Geoff

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to