Setting Time Manually
This method is very tedious, error prone as the initial time source may be wrong.
Configuring NTP
For a Cisco router to participate in an NTP network, we must set the NTP source interface and then designate one or more NTP servers. The source interface is the same interface on the same network as the designated server. We can use access lists to control NTP transactions between the client and server.
Disabling NTP
This method is very tedious, error prone as the initial time source may be wrong.
router1# show clock detail
router1# config t
router1(config)# clock timezone IST +5.30
router1(config)# exit
router1# clock set 05:11:00 01 January 2012
router1# show clock
Configuring NTP
For a Cisco router to participate in an NTP network, we must set the NTP source interface and then designate one or more NTP servers. The source interface is the same interface on the same network as the designated server. We can use access lists to control NTP transactions between the client and server.
router1# config t
router1(config)# interface eth 0
router1(config-if)# ntp enable
router1(config-if)# exit
router1(config)# ntp server 192.168.1.15 source eth 0
router1(config)# access-list 2 permit host 192.168.1.15
router1(config)# access-list 2 deny any log
router1(config)# ntp access-group peer 21
router1(config)# exit
router1# show ntp associationsDisabling NTP
router1# config t
router1(config)# interface eth 0
router1(config-if)# ntp disable
router1(config-if)# end
NTP Authentication
router1# config t
router1(config)# ntp authenticate
router1(config)# ntp authentication-key 1 md5 router
router1(config)# ntp trusted-key 1
router1(config)# ntp server 192.168.1.15 key 1 source eth 0
router1(config)# exit
No comments:
Post a Comment