FAQ: DST Time Changing

Solution Verified - Updated

Environment

  • Red Hat Enterprise Linux
  • tzdata
  • DST (Daylight Saving Time)
  • NTP (Network Time Protocol)

Issue

  • This FAQ (Frequently Asked Questions) is a list of questions and answers related to DST time changes.

Resolution

What should I do before DST time change?

  • Our recommendation is to use the latest available tzdata package. The tzdata package contains data files with rules for various time zones around the world.
  • Execute the below command to update it:
[root@localhost ~]# yum update tzdata

What changes need to be done on my NTP environment?

  • NTP works internally entirely in UTC (Universal Time Coordinated), timezones and DST changes are applied locally by the system. There is no need to do any changes to the NTP configuration.

How can I check when DST will be applied?

  • You can use timedatectl command in RHEL7:
[root@localhost ~]# timedatectl 
      Local time: Tue 2021-11-02 13:39:05 EDT
  Universal time: Tue 2021-11-02 17:39:05 UTC
        RTC time: Tue 2021-11-02 17:39:04
       Time zone: America/New_York (EDT, -0400)
     NTP enabled: yes
NTP synchronized: yes
 RTC in local TZ: no
      DST active: yes
 Last DST change: DST began at
                  Sun 2021-03-14 01:59:59 EST
                  Sun 2021-03-14 03:00:00 EDT
 Next DST change: DST ends (the clock jumps one hour backwards) at
                  Sun 2021-11-07 01:59:59 EDT
                  Sun 2021-11-07 01:00:00 EST
  • For RHEL6, RHEL8, and RHEL9 use zdump command:
[root@localhost ~]# zdump -v /etc/localtime | grep 2021
/etc/localtime  Sun Mar 14 06:59:59 2021 UTC = Sun Mar 14 01:59:59 2021 EST isdst=0 gmtoff=-18000
/etc/localtime  Sun Mar 14 07:00:00 2021 UTC = Sun Mar 14 03:00:00 2021 EDT isdst=1 gmtoff=-14400
/etc/localtime  Sun Nov  7 05:59:59 2021 UTC = Sun Nov  7 01:59:59 2021 EDT isdst=1 gmtoff=-14400
/etc/localtime  Sun Nov  7 06:00:00 2021 UTC = Sun Nov  7 01:00:00 2021 EST isdst=0 gmtoff=-18000

Note: The upstream community decided to remove DST information from timedatectl output.
For more information see: Content from github.com is not included.timedate: remove daylight saving time handling and tzfile parser

How can I change the timezone of my system?

Should I configure the RTC (hardware clock) in the local timezone or UTC?

I do not want a time change on systems during DST time change, what can I do?

  • To avoid DST changes, you should use UTC or GMT timezones in your system since they don't include DST information.
  • These timezones files are in /usr/share/zoneinfo/Etc directory. For example, if you want to configure GMT+5, use this command:
[root@localhost ~]# timedatectl set-timezone Etc/GMT+5

[root@localhost ~]# timedatectl 
      Local time: Tue 2021-11-02 12:51:57 -05
  Universal time: Tue 2021-11-02 17:51:57 UTC
        RTC time: Tue 2021-11-02 17:51:56
       Time zone: Etc/GMT+5 (-05, -0500)
     NTP enabled: yes
NTP synchronized: yes
 RTC in local TZ: no
      DST active: n/a
SBR
Components
Category
Tags

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.