Enabling And Disabling Timestamps On Log Messages - Cisco Catalyst 4500 series Administration Manual

Hide thumbs Also See for Catalyst 4500 series:
Table of Contents

Advertisement

Chapter 61
Configuring System Message Logging
Command
Step 5
Switch# show running-config
Step 6
Switch# copy running-config
startup-config
To disable synchronization of unsolicited messages and debug output, use the
no logging synchronous [level severity-level | all] [limit number-of-buffers] line configuration
command.

Enabling and Disabling Timestamps on Log Messages

By default, log messages are not time-stamped.
Note
To enable time-stamping of log messages, perform this task:
Command
Step 1
Switch# configure terminal
Step 2
Switch(config)# service timestamps log uptime
or
Switch(config)# service timestamps log
[
] [
datetime
msec
Step 3
Switch(config)# end
Step 4
Switch# show running-config
Step 5
Switch# copy running-config startup-config
To disable time-stamps for both debug and log messages, use the no service timestamps global
configuration command.
This example shows part of a logging display with the service timestamps log datetime global
configuration command enabled:
*Mar
This example shows part of a logging display with the service timestamps log uptime global
configuration command enabled:
00:00:46: %LINK-3-UPDOWN: Interface Port-channel1, changed state to up
Enabling and Disabling Sequence Numbers in Log Messages (Optional)
Because more than one log message can have the same timestamp, you can display messages with
sequence numbers so that you can unambiguously refer to a single message. By default, sequence
numbers in log messages are not displayed.
OL_28731-01
] [
localtime
show-timezone
1 18:46:11: %SYS-5-CONFIG_I: Configured from console by vty2 (10.34.195.36)
Purpose
Verifies your entries.
(Optional) Saves your entries in the configuration file.
Purpose
Enters global configuration mode.
Enables log time-stamps.
The first command enables time-stamps on log messages,
]
showing the time since the system was rebooted.
The second command enables time-stamps on log messages.
Depending on the options selected, the timestamp can
include the date, time in milliseconds relative to the local
time zone, and the time zone name.
Returns to privileged EXEC mode.
Verifies your entries.
(Optional) Saves your entries in the configuration file.
Software Configuration Guide—Release IOS XE 3.6.0E and IOS 15.2(2)E
Configuring System Message Logging
61-7

Advertisement

Table of Contents
loading

Table of Contents