Configuring IP Services
Configuring IP Accounting
IPC-109
Cisco IOS IP Configuration Guide
To configure other IP accounting functions, use the following commands in global configuration mode,
as needed:
To display IP access violations for a specific IP accounting database, use the following command in
EXEC mode:
To display IP access violations, include the access-violations keyword in the show ip accounting EXEC
command. If you do not specify the keyword, the command defaults to displaying the number of packets
that have passed access lists and were routed. The access violations output displays the number of the
access list failed by the last packet for the source and destination pair. The number of packets reveals
how aggressive the attack is upon a specific destination.
Use the show ip accounting EXEC command to display the active accounting database, and traffic
coming from a remote site and transiting through a router. To display the ch eckpointed dat abase, use the
show ip accounting checkpoint EXEC command. The clear ip accounting EXEC command clears the
active database and creates the checkpointed database.
Configuring IP MAC Accounting
The MAC address accounting functionality provides accounting information for IP traffic based on the
source and destination MAC addresses on LAN interfaces. MAC accounting calculates the total packet
and byte counts for a LAN interface that receives or sends IP packets to or from a unique MAC address.
It also records a timestamp for the last packet received or sent. For example, with IP MAC accounting,
you can determine how much traffic is being sent to and/or received from various peers at NAPS/peering
points. IP MAC accounting is supported on Ethernet, FastEthernet, and FDDI interfaces and supports
Cisco Express Forwarding (CEF), distributed CEF (dCEF), flow, and optimum switching.
To configure the interface for IP accounting based on the MAC address, perform the following steps
beginning in global configuration:
Command Purpose
Router(config)# ip accounting-threshold
threshold
Sets the maximum number of accounting entries to be created.
Router(config)# ip accounting-list
ip-address wildcard
Filters accounting information for hosts.
Router(config)# ip accounting-transits
count
Controls the number of transit records that will be stored in the IP
accounting database.
Command Purpose
Router# show ip accounting [checkpoint]
access-violations
Displays IP access violation information.
Command Purpose
Step1 Router(config)# interface type number Specifies the interface and enters interface configuration
mode.
Step2 Router(config-if)# ip accounting mac-address
{input | output}Configures IP accounting based on the MAC address of
received (input) or transmitted (output) packets