Supported Platforms
Related Documentation
- ACX, M, MX, PTX, T Series
- Guidelines for Configuring Firewall Filters
- Guidelines for Applying Firewall Filters
- M, MX, PTX, T Series
- Firewall Filter Terminating Actions
- M, MX, T Series
- Firewall Filter Nonterminating Actions
- MX Series
- Classic Filters Overview
- Defining Dynamic Filter Processing Order
- RADIUS Accounting Statistics for Subscriber Access Overview
- Configuring Per-Service Session Accounting
- Configuring Per-Subscriber Session Accounting
Configuring Service Packet Counting
Subscriber management uses service packet counting to report volume statistics for subscribers on a per-service session basis. To configure service packet counting, you specify the accounting action, and subscriber management then applies the results to a specific named counter (__junos-dyn-service-counter) for use by RADIUS.
The accounting action you configure specifies the counting mechanism that subscriber management uses when capturing statistics—either inline counters or deferred counters. Inline counters are captured when the event occurs, and do not include any additional packet processing that might occur after the event. Deferred counters (also called accurate accounting) are not incremented until the packet is queued for transmission, and therefore include the entire packet processing. Deferred counters provide a more accurate count of the packets than inline counters, and are more useful for subscriber accounting and billing.
You configure the accounting mechanism by specifying either the service-accounting-deferred action (for deferred counters) or the service-accounting action (for inline counters) at the [edit firewall family family-name filter filter-name term term-name then] hierarchy level.
The two accounting mechanisms are mutually exclusive, both on a per-term basis and a per-filter basis. Also, both accounting actions are mutually exclusive with the count action on a per-term basis.
![]() | Note: You can define deferred counters for the inet and inet6 families for classic filters only. Fast update filters do not support deferred counters. |
To enable service packet counting:
- Configure any match conditions that you want to count
using the service accounting action. For example:[edit firewall family inet filter filtername term term-name]user@host# set from source-address address
- Specify the accounting action for the filter.
To use deferred counters:
[edit firewall family inet filter filtername term term-name]user@host# set then service-accounting-deferredTo use inline counters:
[edit firewall family inet filter filtername term term-name]user@host# set then service-accounting
When the match conditions for the filter are met, the packet is counted and applied to the well-known service counter (__junos-dyn-service-counter) for use by the RADIUS server. This counter provides the volume statistics for per-service accounting.
![]() | Tip: You cannot use the service-accounting action or the service-accounting-deferred action in the same term as a count action. |
Related Documentation
- ACX, M, MX, PTX, T Series
- Guidelines for Configuring Firewall Filters
- Guidelines for Applying Firewall Filters
- M, MX, PTX, T Series
- Firewall Filter Terminating Actions
- M, MX, T Series
- Firewall Filter Nonterminating Actions
- MX Series
- Classic Filters Overview
- Defining Dynamic Filter Processing Order
- RADIUS Accounting Statistics for Subscriber Access Overview
- Configuring Per-Service Session Accounting
- Configuring Per-Subscriber Session Accounting
Published: 2013-07-31
Supported Platforms
Related Documentation
- ACX, M, MX, PTX, T Series
- Guidelines for Configuring Firewall Filters
- Guidelines for Applying Firewall Filters
- M, MX, PTX, T Series
- Firewall Filter Terminating Actions
- M, MX, T Series
- Firewall Filter Nonterminating Actions
- MX Series
- Classic Filters Overview
- Defining Dynamic Filter Processing Order
- RADIUS Accounting Statistics for Subscriber Access Overview
- Configuring Per-Service Session Accounting
- Configuring Per-Subscriber Session Accounting