cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2829
Views
0
Helpful
3
Replies

Clock in Logs

snarayanaraju
Level 4
Level 4

Hello Friends - I am seeking your help in understanding why the timestamp shown in Logs differ from Router Clock set thru NTP. Here is my observation

Note: both the routers are SYNC with NTP server at Strarum 3

Router-1 Configuration

service timestamps log datetime msec localtime

     here log messages (show log output) matches with Clock (show clock)

Router-2 Configuration

service timestamps log datetime msec

     here log messages (show log output) doesn't matches with Clock (show clock). There is some difference of +3hrs 20 minutes (additional in Log message timestamp)

May i know from where the logs assumes the time in Router-2 ? I am not seeing this time in NTP

Thanks in advance

SAIRAM                  

1 Accepted Solution

Accepted Solutions

Hello.

If you enter "service timestamps log datetime localtime", then you see local time (that is CDT).

If you omit "localtime", then time is shown for UTC (5 hours later than CDT); so the event happend at 15:44:31 UTC = 10:44:31 CDT.

PS: for multinational companies it's a best practice to keep routers' clock in UTC (and timestamps as well).

View solution in original post

3 Replies 3

snarayanaraju
Level 4
Level 4

Friends - To add more to get more visibility here is the output

Router-2

rtr2# show clock
12:17:16.860 CDT Thu Oct 17 2013

rtr2#show ntp assoc

  address         ref clock       st   when   poll reach  delay  offset   disp
*~165.130.1.7     65.49.70.244     3    347   1024   377 27.565 -10.826 14.835

rtr2-st0564# show log | in Oct 17

033016: Oct 17 15:44:31.420: %IPPHONE-6-UNREGISTER_ABNORMAL

Hello.

If you enter "service timestamps log datetime localtime", then you see local time (that is CDT).

If you omit "localtime", then time is shown for UTC (5 hours later than CDT); so the event happend at 15:44:31 UTC = 10:44:31 CDT.

PS: for multinational companies it's a best practice to keep routers' clock in UTC (and timestamps as well).

Thank you Mikhailovsky - Sounds logic. Here is the observation

rtr1#show clock

13:04:36.973 CDT Thu Oct 17 2013

rtr1#show log | in Oct 17

502468: Oct 17 18:03:46.133: %SEC-6-IPACCESSLOGP:

Excellent.. Thanks again

SAIRAM

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card