The mac accounting enable command enables the MAC accounting function.
The undo mac accounting enable command disables the MAC accounting function.
By default, the MAC accounting function is disabled.
Usage Scenario
To collect MAC address-based traffic statistics on a physical interface, its sub-interfaces, an Eth-Trunk interface, or Eth-Trunk sub-interfaces, run the mac accounting enable command on the physical interface or Eth-Trunk interface to enable the MAC accounting function. This configuration allows a device to collect service traffic statistics based on an interface and its MAC address.
NOTE: This command can be run only on a main interface and takes effect on the interface and its sub-interfaces. MAC accounting can be used in either of the following scenarios: