Embedded Packet Capture Overview: Finding Feature Information
Embedded Packet Capture Overview: Finding Feature Information
Embedded Packet Capture Overview: Finding Feature Information
Embedded Packet Capture (EPC) provides an embedded systems management facility that helps in tracing
and troubleshooting packets. This feature allows network administrators to capture data packets flowing
through, to, and from a Cisco device. The network administrator may define the capture buffer size and type
(circular, or linear), the maximum number of bytes of each packet to capture, and the direction of the traffic
flow - ingress or egress, or both. The packet capture rate can be throttled using further administrative controls.
For example, you can use the available options for filtering the packets to be captured using an Access Control
List; and, optionally, further defined by specifying a maximum packet capture rate or by specifying a sampling
interval.
• Finding Feature Information, on page 1
• Prerequisites for Embedded Packet Capture, on page 1
• Restrictions for Embedded Packet Capture, on page 2
• Information About Embedded Packet Capture, on page 2
• How to Implement Embedded Packet Capture, on page 3
• Configuration Examples for Embedded Packet Capture, on page 6
• Additional References, on page 9
• Feature Information for Embedded Packet Capture, on page 9
• Facility to export the packet capture in packet capture file (PCAP) format suitable for analysis using any
external tool.
• Methods to decode data packets captured with varying degrees of detail.
Note Network Based Application Recognition (NBAR) and MAC-style class map is
not supported.
• Destroy captures.
• Specify buffer storage parameters such as size and type. The size ranges from 1 MB to 100 MB. The
default buffer is linear; the other option for the buffer is circular.
• Specify any of the following limit options:
• duration - limit total duration of capture in seconds.
• every - limit capture to one in every nth packet.
• packet-len - limit the packet length to capture.
• packets - limit number of packets to capture.
• pps - limit number of packets per second to capture.
• Specify match criteria that includes information about the protocol, IP address or port address.
DETAILED STEPS
Step 2 monitor capture capture-name access-list Configures a monitor capture specifying an access list as
access-list-name the core filter for the packet capture.
Example:
Device# monitor capture mycap access-list v4acl
Step 3 monitor capture capture-name limit duration seconds Configures monitor capture limits.
Example:
Device# monitor capture mycap limit duration 1000
Step 4 monitor capture capture-name interface interface-name Configures monitor capture specifying an attachment point
both and the packet flow direction.
Example: Note • To change the traffic direction from both
Device# monitor capture mycap interface to in (ingress direction), enter the no
GigabitEthernet 0/0/1 both monitor capture capture-name interface
interface-name out command.
• To change the traffic direction from both
to out (egress direction), enter the no
monitor capture capture-name interface
interface-name in command.
Step 5 monitor capture capture-name buffer circular size Configures a buffer to capture packet data.
bytes
Example:
Device# monitor capture mycap buffer circular size
10
Step 6 monitor capture capture-name start Starts the capture of packet data at a traffic trace point into
a buffer.
Example:
Device# monitor capture mycap start
Step 7 monitor capture capture-name export Exports captured data for analysis.
file-location/file-name
Example:
Step 8 monitor capture capture-name stop Stops the capture of packet data at a traffic trace point.
Example:
Device# monitor capture mycap stop
SUMMARY STEPS
1. enable
2. show monitor capture capture-buffer-name buffer dump
3. show monitor capture capture-buffer-name parameter
4. debug epc capture-point
5. debug epc provision
6. exit
DETAILED STEPS
Step 2 show monitor capture capture-buffer-name buffer (Optional) Displays a hexadecimal dump of captured packet
dump and its metadata.
Example:
Step 3 show monitor capture capture-buffer-name parameter (Optional) Displays a list of commands that were used to
specify the capture.
Example:
Step 4 debug epc capture-point (Optional) Enables packet capture point debugging.
Example:
Step 5 debug epc provision (Optional) Enables packet capture provisioning debugging.
Example:
Device# exit
Device> enable
Device# monitor capture mycap access-list v4acl
Device# monitor capture mycap limit duration 1000
Device# monitor capture mycap interface GigabitEthernet 0/0/1 both
Device# monitor capture mycap buffer circular size 10
Device# monitor capture mycap start
Device# monitor capture mycap export tftp://10.1.88.9/mycap.pcap
Device# monitor capture mycap stop
Device# end
0
0000: 01005E00 00020000 0C07AC1D 080045C0 ..^...........E.
0010: 00300000 00000111 CFDC091D 0002E000 .0..............
0020: 000207C1 07C1001C 802A0000 10030AFA .........*......
0030: 1D006369 73636F00 0000091D 0001 ..example.......
1
0000: 01005E00 0002001B 2BF69280 080046C0 ..^.....+.....F.
0010: 00200000 00000102 44170000 0000E000 . ......D.......
0020: 00019404 00001700 E8FF0000 0000 ..............
2
0000: 01005E00 0002001B 2BF68680 080045C0 ..^.....+.....E.
0010: 00300000 00000111 CFDB091D 0003E000 .0..............
0020: 000207C1 07C1001C 88B50000 08030A6E ...............n
0030: 1D006369 73636F00 0000091D 0001 ..example.......
3
0000: 01005E00 000A001C 0F2EDC00 080045C0 ..^...........E.
0010: 003C0000 00000258 CE7F091D 0004E000 .<.....X........
0020: 000A0205 F3000000 00000000 00000000 ................
0030: 00000000 00D10001 000C0100 01000000 ................
0040: 000F0004 00080501 0300 ................
The following example shows how to display the list of commands used to configure the capture
named mycap:
Device# show monitor capture mycap parameter
The following example shows how to debug the Embedded Packet Capture (EPC) provisioning:
Device# debug epc provision
*Jun 4 14:17:54.991: EPC PROV: No action found for policy-map epc_policy_cap1 class-map
epc_class_cap1
*Jun 4 14:17:54.991: EPC PROV:
*Jun 4 14:17:54.991: Attempting to install service policy epc_policy_cap1
*Jun 4 14:17:54.992: EPC PROV: Attached service policy to epc idb subblock
*Jun 4 14:17:54.992: EPC PROV: Successful. Create feature object
*Jun 4 14:17:54.992: EPC PROV:
*Jun 4 14:17:54.992: Attempting to install service policy epc_policy_cap1
Additional References
Related Documents
Technical Assistance
Description Link
Embedded Packet Capture Cisco IOS XE Release 3.7S Embedded Packet Capture (EPC)
is an onboard packet capture
facility that allows network
administrators to capture packets
flowing to, through, and from a
device and to analyze them locally
or save and export them for offline
analysis using a tool such as
Wireshark. This feature simplifies
operations by allowing the devices
to become active participants in the
management and operation of the
network. This feature facilitates
better troubleshooting by gathering
information about packet format. It
also facilitates application analysis
and security.
The following commands were
introduced or modified: debug epc,
monitor capture (access list/class
map), monitor capture
(interface/control plane), monitor
capture export, monitor capture
limit, monitor capture start,
monitor capture stop, and show
monitor capture .