有没有一种方法可以为我的域上的所有机器设置时区(也许使用组策略?)。 所有的Windows机器都是Server 2008 R2。
命令tzutil.exe在Windows 7/2008上可用
TZUTIL </? | /g | /s TimeZoneID[_dstoff] | /l> Parameters: /? Displays usage information. /g Displays the current time zone ID. /s TimeZoneID[_dstoff] Sets the current time zone using the specified time zone ID. The _dstoff suffix disables Daylight Saving Time adjustments for the time zone (where applicable). /l Lists all valid time zone IDs and display names. The output will be: <display name> <time zone ID> Examples: TZUTIL /g TZUTIL /s "Pacific Standard Time" TZUTIL /s "Pacific Standard Time_dstoff"
要设置为UTC,请使用类似TZUTIL /s "UTC"的命令。
有几个办法可能会工作,导出一个“正确的”registry片段,并通过脚本导入,这是有点hacky,但可行。 或者, 这里有一篇文章讨论了如何使用powershell脚本来做一些例子。