I was wondering why my google compute engine virtual machine (Red Hat Enterprise Linux 7) located in the us-central1-a zone uses the Greenwich time zone. NTP server does not work?
Have a look at the documentation CHAPTER 3. CONFIGURING THE DATE AND TIME:
By default, the system is configured to use UTC.
and accordinly to Coordinated Universal Time:
Coordinated Universal Time (or UTC) is the primary time standard by which the world regulates clocks and time. It is within about 1 second of mean solar time at 0° longitude, and is not adjusted for daylight saving time. It is effectively a successor to Greenwich Mean Time (GMT).
I've created test VM at us-central1-a
and checked time and NTP status:
$ timedatectl
Local time: Mon 2020-05-11 08:50:18 UTC
Universal time: Mon 2020-05-11 08:50:18 UTC
RTC time: Mon 2020-05-11 08:50:18
Time zone: UTC (UTC, +0000)
NTP enabled: yes
NTP synchronized: yes
RTC in local TZ: no
DST active: n/a
$ ntpstat
synchronised to NTP server (169.254.169.254) at stratum 3
time correct to within 1 ms
polling server every 64 s
everything looks like expected. In addition, I've checked at VMs in other zones and found same default settings.
You're able to change time zone by following instructions 3.1.4. Changing the Time Zone:
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.