NTP

Two sources of timing.

Hardware clock (sometimes referred to in Cisco documentation as the “calendar”), battery backup for when powered off. Software clock, initialized at boot time from the hardware clock

show clock
show clock detail

Set the time and date in UTC, not your local time zone (http://www.worldtimeserver.com/current_time_in_GB.aspx)
clock set 17:49:00 27 march 2011

Hardware clock has not been updated
show calendar

If we were to reboot the router, the software clock would be resynchronized with the hardware clock.
calendar set !will set the hardware clock
clock update-calendar !synchronize the hardware clock to the software clock
show calendar

Configure local timezone and (if applicable) daylight savings time on the router.

clock timezone DST +1
clock summer-time DST recurring
show clock detail

NTP
===
NTP servers are described in terms of strata; the lower a server’s stratum, the more accurate it is.
Public NTP Servers: http://www.pool.ntp.org/en/
Basic NTP Configuration
Router(config)# ntp server time-a.nist.gov
Router(config)# ntp server nist1-pa.ustiming.org
Router# sh ntp associations

Can take upto 5 min to sync. * is used + is a candidate.

Router# show ntp status

Update the hardware clock from the NTP
#ntp update-calendar.

Ref: http://packetlife.net/blog/2011/mar/28/cisco-ios-clocks-and-ntp/

Tags:

About Alexis Katsavras

Working as Freelance Cisco Unified Communications Consultant in the UK. www.NetPacket.co.uk