我正在运行 CentOS 服务器,但似乎无法正确设置时间。我的问题是我已将时区设置为 UTC,服务器似乎承认这一点,但它仍然指出错误的时间!
真正的 UTC 时间 = 16:56(我当地的时区是 GMT)
# hwclock –show
wed 09 Mar 10:56:48 AM UTC -0.502715 seconds
# date
Wed Mar 9 10:56:51 UTC 2011
Run Code Online (Sandbox Code Playgroud)
即服务器似乎在说它是在 UTC 时间......但 6 小时后!
我已经采取了几个步骤来尝试纠正这个问题,包括:
1. Use setup to manually pick the timezone
# system-config-date (Set to Etc/UTC)
2. Set the timezone in the localtime file
# ln -sf /usr/share/zoneinfo/UTC /etc/localtime
3. Change the UTC value in the /etc/sysconfig/clock file
I have tried both UTC=true and UTC=false
Run Code Online (Sandbox Code Playgroud)
这些解决方案都没有奏效
请帮忙,
大卫