2-362
Catalyst 3750-X and 3560-X Switch Command Reference
OL-29704-01
Chapter 2 Catalyst 3750-X and 3560-X Switch Cisco IOS Commands
logging smartlog
logging smartlog
To enable smart logging on the switch, use the logging smartlog command in global configuration
mode. Smart logging sends the contents of specified dropped packets to a Cisco IOS Flexible NetFlow
collector. To disable smart logging or return to the default setting, use the no form of this command.
logging smartlog [exporter name | packet capture size bytes]
no logging smartlog [exporter name | packet capture size bytes]
Syntax Description
Defaults Smart logging is not enabled.
Command Modes Global configuration
Command History
Usage Guidelines You must configure a NetFlow collector before you enable smart logging. For information on
configuring Cisco Flexible NetFlow, see the Cisco IOS Flexible NetFlow Configuration Guide, Release
12.4T:
http://www.cisco.com.do/en/US/docs/ios/fnetflow/configuration/guide/12_4t/fnf_12_4t_book.html
You can configure smart logging of packets dropped because of DHCP snooping violations, Dynamic
ARP inspection violations, IP source guard denied traffic, or ACL permitted or denied traffic for smart
logging to take place.
You can verify the configuration by entering the show logging smartlog privileged EXEC command.
Examples This example shows a typical smart logging configuration. It assumes that you have already used the
Flexible NetFlow CLI to configure the NetFlow exporter cisco, and configures smart logging to capture
the first 128 bytes of the packets.
Switch(config)# logging smartlog
Switch(config)# logging smartlog cisco
Switch(config)# logging smartlog packet capture size 128
exporter name (Optional) Identifies the Cisco IOS NetFlow exporter (collector) to which contents
of dropped packets are sent. You must have already configured the exporter by
using the flexible NetFlow CLI. If the exporter name does not exist, you receive an
error message.
packet capture
size size
(Optional) Specifies the size of the smart log packet sent to the collector in the
number of bytes. The range is from 64 to 1024 bytes in 4-byte increments. The
default size is 64 bytes. Increasing the packet capture size decreases the number of
flow records per packet.
Release Modification
12.2(58)SE This command was introduced.