【RouterOS】——SNTP (NTP) Time Client
本帖最後由 角色 於 2013-3-9 21:36 編輯
How to configure the MT built-in SNTP client:
Ref: http://wiki.mikrotik.com/wiki/Ma ... _zone_configuration
member link: http://www.hkepc.com/forum/redir ... 69&pid=28922482
1. print the current clock- [admin@MikroTik] > /system clock print
- time: 13:03:54
- date: jan/02/1970
- time-zone-name: manual
- gmt-offset: +00:00
複製代碼 2. Add the NTP servers for MT SNTP- /system ntp client
- set enabled=yes primary-ntp=210.0.235.14 secondary-ntp=203.129.68.14
複製代碼 3. Check the system ntp client- [admin@MikroTik] > /system ntp client print
- enabled: yes
- mode: broadcast
- primary-ntp: 210.0.235.14
- secondary-ntp: 203.129.68.14
複製代碼 4. When mode: broadcast, it waits for the ntp server to send the time information to RouterBoard. We need to set mode=unicast that means that we send a request to NTP server.- [admin@MikroTik] /system ntp client set mode=unicast
複製代碼 5. Print the time again, which shows more environment variables- [admin@MikroTik] /system ntp client print
- enabled: yes
- mode: unicast
- primary-ntp: 210.0.235.14
- secondary-ntp: 203.129.68.14
- poll-interval: 32s
- active-server: 203.129.68.14
- last-update-from: 203.129.68.14
- last-update-before: 5s640ms
- last-adjustment: 2239w16h52m53s407ms960us
複製代碼 6. Show the time again, it indicates that the time is revised but the time-zone if incorrect.- [admin@MikroTik] /system ntp client> /system clock print
- time: 13:26:30
- date: jan/01/2013
- time-zone-name: manual
- gmt-offset: +00:00
複製代碼 7. Change the time-zone of Hong Kong- [admin@MikroTik] /system clock manual set time-zone=+08:00
複製代碼 8. Check the time again.- [admin@MikroTik] /system ntp client> /system clock print
- time: 21:28:27
- date: jan/01/2013
- time-zone-name: manual
- gmt-offset: +08:00
複製代碼 |