第一步,判断Windows Time服务是否正在运行,如果没有,则开启它。

第二步,强制同步,不知为何,往往第一次会失败,那么就多运行几次好了。

SRE实战 互联网时代守护先锋,助力企业售后服务体系运筹帷幄!一键直达领取阿里云限量特价优惠。


Get-Service w32time | Where {$_.status –eq 'Stopped'} |  Start-Service
W32tm /resync /force
W32tm /resync /force


参考资料

==========

https://devblogs.microsoft.com/scripting/powertip-force-time-resync-with-powershell/

https://redmondmag.com/articles/2016/01/22/powershell-to-manage-system-services.aspx

扫码关注我们
微信号:SRE实战
拒绝背锅 运筹帷幄