Modifying the Format of Time Stamps
SUMMARY STEPS
1. configure
2. Do one of the following:
3. Do one of the following:
4. commit
DETAILED STEPS
Command or Action
Step 1
configure
Step 2
Do one of the following:
• service timestamps log datetime
[localtime] [msec] [show-timezone]
• service timestamps log uptime
Example:
RP/0/RSP0/CPU0:router(config)# service
timestamps log datetime localtime
msec
or
RP/0/RSP0/CPU0:router(config)# service
timestamps log uptime
Step 3
Do one of the following:
• service timestamps debug datetime
[localtime] [msec] [show-timezone]
Cisco ASR 9000 Series Aggregation Services Router System Monitoring Configuration Guide, Release 4.2.x
300
• service timestamps log datetime [localtime] [msec] [show-timezone]
• service timestamps log uptime
• service timestamps debug datetime [localtime] [msec] [show-timezone]
• service timestamps debug uptime
Purpose
Modifies the time-stamp format for syslog messages.
Modifies the time-stamp format for debugging messages.
• By default, time stamps are enabled. The default time-stamp format is
month day HH:MM:SS.
• Issuing the service timestamps log datetime command configures
syslog messages to be time-stamped with the date and time.
◦ The optional localtime keyword includes the local time zone in
time stamps.
◦ The optional msec keyword includes milliseconds in time stamps.
◦ The optional show-timezone keyword includes time zone
information in time stamps.
• Issuing the service timestamps log uptime command configures syslog
messages to be time-stamped with the time that has elapsed since the
router last rebooted.
◦ The service timestamps log uptime command configures
time-stamps to be configured in HHHH:MM:SS, indicating the
time since the router last rebooted.
• By default, time-stamps are enabled. The default time stamp format is
month day HH:MM:SS.
Implementing Logging Services