Windows搭建NTP服务器——搭建时间同步服务器
本环境搭建环境是windows2012R2
在Windows 服务器下,按住“ windows+r ”打开“运行”对话框,输入regedit,点击“确定”打开注册表。

依次打开HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32TimeParametersType

鼠标双击Type 文件;
弹出对话框,在数据数值(V)项输入 NTP,单击确定

按照此路径查找文件:
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32TimeConfigAnnounceFlags

双击 AnnounceFlags文件。
在 数值数据 框中键入 5,基数选择16进制,点击确定

按照此路径查找文件
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32TimeTimeProvidersNtpServerEnabled
双击 Enabled文件。在编辑DWORD 值 的 数值数据 框中键入 1,然后单击 确定 按钮


重起WindowsTime服务
打开开始菜单输入“CMD”在命令行模式下输入
net stop w32time
net start w32time
重启一下win32time服务。



按开始->运行,输入"services.msc"进入服务,将windows time服务start方式设置为Auto
设置 Windows 时间服务


设置 Windows 时间服务
输入:gpedit.msc
执行上述命令后,计算机策略对话框打开,按照如下路径计算机配置管理模板系统windows 时间服务时间提供程序 找到服务器设置文件
双击启用 Windows NTP 服务器,显示状态已启用即可;



如果有不成功,请大家留言评论