Enabling Accounting on Inbound and Outbound Interfaces
Unlike DCU, which only requires implementation on a single interface, accounting for SCU must be enabled on two interfaces: the inbound and outbound physical or logical interfaces traversed by the source class. You must define explicitly the two interfaces on which SCU monitored traffic is expected to arrive and depart. This is because SCU performs two lookups in the routing table: a source address (SA) and a destination address (DA) lookup. In contrast, DCU only has a single destination address lookup. By specifying the addresses involved in the additional SCU SA lookup, you minimize the performance impact on your router.
An individual SCU interface can be configured as
an input interface, an output interface, or both. SCU can be enabled
in an IPv4 (family inet) or IPv6 (family inet6) network. To configure SCU accounting, include the source-class-usage
statement at the [edit interfaces interface-name unit logical-unit-number family (inet | inet
6) accounting]
hierarchy level:
[edit] interfaces { interface-name { unit unit-number { family (inet | inet6) { accounting { source-class-usage { (input | output | input output); } destination-class-usage; } } } } }
After the full SCU configuration is enabled, every packet arriving on an SCU input interface is subjected to an SA-based lookup and then a DA-based lookup. In addition, an individual set of counters for every configured SCU class is maintained by the router on a per-interface and per-protocol family basis.