windows 服务器同步互联网时间

@echo off
::netsh ipsec static set policy name=7road assign=n
net time /setsntp:pool.ntp.org
net stop w32time
net start w32time
w32tm /resync
w32tm /resync
w32tm /resync
::netsh ipsec static set policy name=7road assign=y
exit

Linux自动同步时间:

*/8 * * * * /usr/sbin/ntpdate asia.pool.ntp.org >>/root/web.time
 

systemctl stop ntpd
ntpdate ntp1.aliyun.com

上一篇:linux部署solr服务--小记


下一篇:CF 859E Desk Disorder