Sunday, 29 January 2017

Changing the Time Zone in RHEL 7

To list all available time zones, type the following at a shell prompt:
~]# timedatectl list-timezones
To change the currently used time zone, type as root:
~]# timedatectl set-timezone time_zone
Replace time_zone with any of the values listed by the timedatectl list-timezones command.
Example Changing the Time Zone
To identify which time zone is closest to your present location, use the timedatectl command with the list-timezones command line option. For example, to list all available time zones in Europe, type:
~]# timedatectl list-timezones | grep Europe
Europe/Amsterdam
Europe/Andorra
Europe/Athens
Europe/Belgrade
Europe/Berlin
Europe/Bratislava
To change the time zone to Europe/Prague, type as root:

~]# timedatectl set-timezone Europe/Prague

No comments:

Post a Comment