Table Of Contents
Accounting Commands
aaa accounting
aaa accounting connection h323
aaa accounting delay-start
aaa accounting nested
aaa accounting resource start-stop group
aaa accounting resource stop-failure group
aaa accounting send stop-record authentication failure
aaa accounting suppress null-username
aaa accounting update
aaa dnis map accounting network
aaa session-mib
accounting
accounting (gatekeeper)
ppp accounting
show accounting
Accounting Commands
This chapter describes the commands used to manage accounting on the network. Accounting management allows you to track individual and group usage of network resources. The authentication, authorization, and accounting (AAA) accounting feature enables you to track the services users are accessing as well as the amount of network resources they are consuming. When AAA accounting is activated, the network access server reports user activity to the TACACS+ or RADIUS security server (depending on which security method you have implemented) in the form of accounting records. Each accounting record contains accounting attribute-value (AV) pairs and is stored on the security server. This data can then be analyzed for network management, client billing or auditing.
For information on how to configure accounting using AAA, refer to the chapter "Configuring Accounting" in the Cisco IOS Security Configuration Guide. For configuration examples using the commands in this chapter, refer to the section "Accounting Configuration Examples" located at the end of the chapter "Configuring Accounting" in the Cisco IOS Security Configuration Guide.
Refer also to the IP accounting feature in the chapter "Configuring IP Services" of the
Cisco IOS IP Configuration Guide.
aaa accounting
To enable authentication, authorization, and accounting (AAA) accounting of requested services for billing or security purposes when you use RADIUS or TACACS+, use the aaa accounting command in global configuration mode. To disable AAA accounting, use the no form of this command.
aaa accounting {auth-proxy | system | network | exec | connection | commands level} {default |
list-name} {start-stop | stop-only | none} [broadcast] group groupname
no aaa accounting {auth-proxy | system | network | exec | connection | commands level} {default
| list-name} [broadcast] group groupname
Syntax Description
auth-proxy
|
Provides information about all authenticated-proxy user events.
|
system
|
Performs accounting for all system-level events not associated with users, such as reloads.
|
network
|
Runs accounting for all network-related service requests, including SLIP1 , PPP2 , PPP NCPs3 , and ARAP4 .
|
exec
|
Runs accounting for EXEC shell session. This keyword might return user profile information such as what is generated by the autocommand command.
|
connection
|
Provides information about all outbound connections made from the network access server, such as Telnet, LAT5 , TN3270, PAD6 , and rlogin.
|
commands level
|
Runs accounting for all commands at the specified privilege level. Valid privilege level entries are integers from 0 through 15.
|
default
|
Uses the listed accounting methods that follow this argument as the default list of methods for accounting services.
|
list-name
|
Character string used to name the list of at least one of the accounting methods decribed in Table 12.
|
start-stop
|
Sends a "start" accounting notice at the beginning of a process and a "stop" accounting notice at the end of a process. The "start" accounting record is sent in the background. The requested user process begins regardless of whether the "start" accounting notice was received by the accounting server.
|
stop-only
|
Sends a "stop" accounting notice at the end of the requested user process.
|
none
|
Disables accounting services on this line or interface.
|
broadcast
|
(Optional) Enables sending accounting records to multiple AAA servers. Simultaneously sends accounting records to the first server in each group. If the first server is unavailable, fail over occurs using the backup servers defined within that group.
|
group groupname
|
At least one of the keywords described in Table 11.
|
Defaults
AAA accounting is disabled.
Command Modes
Global configuration
Command History
Release
|
Modification
|
10.3
|
This command was introduced.
|
12.0(5)T
|
Group server support was added.
|
12.1(1)T
|
The broadcast keyword was added on the Cisco AS5300 and Cisco AS5800 universal access servers.
|
12.1(5)T
|
The auth-proxy keyword was added.
|
Usage Guidelines
Use the aaa accounting command to enable accounting and to create named method lists defining specific accounting methods on a per-line or per-interface basis.
Table 11 contains descriptions of accounting method keywords.
Table 11 aaa accounting Methods
Keyword
|
Description
|
group radius
|
Uses the list of all RADIUS servers for authentication as defined by the aaa group server radius command.
|
group tacacs+
|
Uses the list of all TACACS+ servers for authentication as defined by the aaa group server tacacs+ command.
|
group group-name
|
Uses a subset of RADIUS or TACACS+ servers for accounting as defined by the server group group-name.
|
In Table 11, the group radius and group tacacs+ methods refer to a set of previously defined RADIUS or TACACS+ servers. Use the radius-server host and tacacs-server host commands to configure the host servers. Use the aaa group server radius and aaa group server tacacs+ commands to create a named group of servers.
Cisco IOS software supports the following two methods of accounting:
•
RADIUS—The network access server reports user activity to the RADIUS security server in the form of accounting records. Each accounting record contains accounting attribute-value (AV) pairs and is stored on the security server.
•
TACACS+—The network access server reports user activity to the TACACS+ security server in the form of accounting records. Each accounting record contains accounting attribute-value (AV) pairs and is stored on the security server.
Method lists for accounting define the way accounting will be performed. Named accounting method lists enable you to designate a particular security protocol to be used on specific lines or interfaces for particular types of accounting services. Create a list by entering the list-name and the method, where list-name is any character string used to name this list (excluding the names of methods, such as radius or tacacs+) and method identifies the methods to be tried in sequence as given.
If the aaa accounting command for a particular accounting type is issued without a named method list specified, the default method list is automatically applied to all interfaces or lines (where this accounting type applies) except those that have a named method list explicitly defined. (A defined method list overrides the default method list.) If no default method list is defined, then no accounting takes place.
Named accounting method lists are specific to the indicated type of accounting. Method list keywords are described in Table 12.
Table 12 aaa accounting Methods Lists
Keyword
|
Description
|
auth-proxy
|
Creates a method list to provide accounting information about all authenticated hosts that use the authentication proxy service.
|
commands
|
Creates a method list to provide accounting information about specific, individual EXEC commands associated with a specific privilege level.
|
connection
|
Creates a method list to provide accounting information about all outbound connections made from the network access server.
|
exec
|
Creates a method list to provide accounting records about user EXEC terminal sessions on the network access server, including username, date, and start and stop times.
|
network
|
Creates a method list to provide accounting information for SLIP, PPP, NCPs, and ARA sessions.
|
resource
|
Creates a method list to provide accounting records for calls that have passed user authentication or calls that failed to be authenticated.
|

Note
System accounting does not use named accounting lists; you can only define the default list for system accounting.
For minimal accounting, include the stop-only keyword to send a "stop" record accounting notice at the end of the requested user process. For more accounting, you can include the start-stop keyword, so that RADIUS or TACACS+ sends a "start" accounting notice at the beginning of the requested process and a "stop" accounting notice at the end of the process. Accounting is stored only on the RADIUS or TACACS+ server. The none keyword disables accounting services for the specified line or interface.
When AAA accounting is activated, the network access server monitors either RADIUS accounting attributes or TACACS+ AV pairs pertinent to the connection, depending on the security method you have implemented. The network access server reports these attributes as accounting records, which are then stored in an accounting log on the security server. For a list of supported RADIUS accounting attributes, refer to the appendix "RADIUS Attributes" in the Cisco IOS Security Configuration Guide. For a list of supported TACACS+ accounting AV pairs, refer to the appendix "TACACS+ Attribute-Value Pairs" in the Cisco IOS Security Configuration Guide.
Note
This command cannot be used with TACACS or extended TACACS.
Examples
The following example defines a default commands accounting method list, where accounting services are provided by a TACACS+ security server, set for privilege level 15 commands with a stop-only restriction.
aaa accounting commands 15 default stop-only group tacacs+
The following example defines a default auth-proxy accounting method list, where accounting services are provided by a TACACS+ security server with a stop-only restriction. The aaa accounting command activates authentication proxy accounting.
aaa authentication login default group tacacs+
aaa authorization auth-proxy default group tacacs+
aaa accounting auth-proxy default start-stop group tacacs+
Related Commands
Command
|
Description
|
aaa authentication ppp
|
Specifies one or more AAA authentication methods for use on serial interfaces running PPP.
|
aaa authorization
|
Sets parameters that restrict user access to a network.
|
aaa group server radius
|
Groups different RADIUS server hosts into distinct lists and distinct methods.
|
aaa group server tacacs
|
Groups different server hosts into distinct lists and distinct methods.
|
aaa new-model
|
Enables the AAA access control model.
|
radius-server host
|
Specifies a RADIUS server host.
|
tacacs-server host
|
Specifies a TACACS+ server host.
|
aaa accounting connection h323
To define the accounting method list H.323 with RADIUS as a method with either stop-only or start-stop accounting options, use the aaa accounting connection h323 command in global configuration mode. To disable the use of this accounting method list, use the no form of this command.
aaa accounting connection h323 {stop-only | start-stop | none} [broadcast] group groupname
no aaa accounting connection h323 {stop-only | start-stop | none} [broadcast] group groupname
Syntax Description
stop-only
|
Sends a "stop" accounting notice at the end of the requested user process.
|
start-stop
|
Sends a "start" accounting notice at the beginning of a process and a "stop" accounting notice at the end of a process. The "start" accounting record is sent in the background. The requested user process begins regardless of whether the "start" accounting notice was received by the accounting server.
|
none
|
Disables accounting services on this line or interface.
|
broadcast
|
(Optional) Enables sending accounting records to multiple AAA servers. Simultaneously sends accounting records to the first server in each group. If the first server is unavailable, failover occurs using the backup servers defined within that group.
|
group groupname
|
Specifies the server group to be used for accounting services. The following are valid server group names:
• string: Character string used to name a server group.
• radius: Uses list of all RADIUS hosts.
• tacacs+: Uses list of all TACACS+ hosts.
|
Defaults
No accounting method list
Command Modes
Global configuration
Command History
Release
|
Modification
|
11.3(6)NA2
|
This command was introduced.
|
Usage Guidelines
This command creates a method list called h323 and is applied by default to all voice interfaces if the gw-accounting h323 command is also activated.
Examples
The following example enables authentication, authorization, and accounting (AAA) services, gateway accounting services, and defines a connection accounting method list (h323). The h323 accounting method lists specifies that RADIUS is the security protocol that will provide the accounting services, and that the RADIUS service will track start-stop records.
aaa accounting connection h323 start-stop radius
aaa accounting delay-start
To delay generation of accounting "start" records until the user IP address is established, use the aaa accounting delay-start command in global configuration mode. To disable this functionality, use the no form of this command.
aaa accounting delay-start
no aaa accounting delay-start
Syntax Description
This command has no arguments or keywords.
Defaults
Accounting records are not delayed.
Command Modes
Global configuration
Command History
Release
|
Modification
|
12.1
|
This command was introduced.
|
Usage Guidelines
Use the aaa accounting delay-start command to delay creation of the PPP network "start" record until the peer IP address is known.
Examples
The following example shows how to delay accounting "start" records until the IP address of the user is established:
aaa authentication ppp default radius
aaa accounting network default start-stop group radius
aaa accounting delay-start
radius-server host 172.16.0.0 non-standard
Related Commands
Command
|
Description
|
aaa accounting
|
Enables AAA accounting of requested services for billing or security purposes when you use RADIUS or TACACS+.
|
aaa authentication ppp
|
Specifies one or more AAA authentication methods for use on serial interfaces running PPP.
|
aaa authorization
|
Sets parameters that restrict user access to a network.
|
aaa new-model
|
Enables the AAA access control model.
|
radius-server host
|
Specifies a RADIUS server host.
|
tacacs-server host
|
Specifies a TACACS+ server host.
|
aaa accounting nested
To specify that NETWORK records be generated, or nested, within EXEC "start" and "stop" records for PPP users who start EXEC terminal sessions, use the aaa accounting nested command in global configuration mode. To allow the sending of records for users with a NULL username, use the no form of this command.
aaa accounting nested
no aaa accounting nested
Syntax Description
This command has no arguments or keywords.
Defaults
Disabled
Command Modes
Global configuration
Command History
Release
|
Modification
|
12.0(5)T
|
This command was introduced.
|
Usage Guidelines
Use this command when you want to specify that NETWORK records be nested within EXEC "start" and "stop" records, such as for PPP users who start EXEC terminal sessions. In some cases, such as billing customers for specific services, is can be desirable to keep NETWORK "start" and "stop" records together, essentially nesting them within the framework of the EXEC "start" and "stop" messages. For example, a user dialing in using PPP can create the following records: EXEC-start, NETWORK-start, EXEC-stop, NETWORK-stop. By nesting the accounting records, NETWORK-stop records follow NETWORK-start messages: EXEC-start, NETWORK-start, NETWORK-stop, EXEC-stop.
Examples
The following example enables nesting of NETWORK accounting records for user sessions:
aaa accounting resource start-stop group
To enable full resource accounting, which will generate both a "start" record at call setup and a "stop" record at call termination, use the aaa accounting resource start-stop group command in global configuration mode. To disable full resource accounting, use the no form of this command.
aaa accounting resource method-list start-stop [broadcast] group groupname
no aaa accounting resource method-list start-stop [broadcast] group groupname
Syntax Description
method-list
|
Method used for accounting services. Use one of the following options:
• default: Uses the listed accounting methods that follow this argument as the default list of methods for accounting services.
• string: Character string used to name the list of accounting methods.
|
broadcast
|
(Optional) Enables sending accounting records to multiple AAA servers. Simultaneously sends accounting records to the first server in each group. If the first server is unavailable, failover occurs using the backup servers defined within that group.
|
group groupname
|
Specifies the server group to be used for accounting services. The following are valid server group names:
• string: Character string used to name a server group.
• radius: Uses list of all RADIUS hosts.
• tacacs+: Uses list of all TACACS+ hosts.
|
Defaults
No default behavior or values.
Command Modes
Global configuration
Command History
Release
|
Modification
|
12.1(3)T
|
This command was introduced.
|
Usage Guidelines
Use the aaa accounting resource start-stop group command to send a "start" record at each call setup followed with a corresponding "stop" record at the call disconnect. There is a separate "call setup-call disconnect "start-stop" accounting record tracking the progress of the resource connection to the device, and a separate "user authentication start-stop accounting" record tracking the user management progress. These two sets of accounting records are interlinked by using a unique session ID for the call.
You may want to use this command to manage and monitor wholesale customers from one source of data reporting, such as accounting records.
Note
Sending "start-stop" records for resource allocation along with user "start-stop" records during user authentication can lead to serious performance issues and is discouraged unless absolutely required.
All existing AAA accounting method list and server group options are made available to this command.
Examples
The following example shows how to configure resource accounting for "start-stop" records:
aaa authentication login AOL group radius local
aaa authentication ppp default group radius local
aaa authorization exec AOL group radius if-authenticated
aaa authorization network default group radius if-authenticated
aaa accounting exec default start-stop group radius
aaa accounting network default start-stop group radius
aaa accounting resource default start-stop group radius
Related Commands
Command
|
Description
|
aaa accounting start-stop failure
|
Enables resource failure stop accounting support, which will only generate a stop record at any point prior to user authentication if a call is terminated.
|
aaa accounting resource stop-failure group
To enable resource failure stop accounting support, which will generate a "stop" record at any point prior to user authentication only if a call is terminated, use the aaa accounting resource stop-failure group command in global configuration mode. To disable resource failure stop accounting, use the no form of this command.
aaa accounting resource method-list stop-failure [broadcast] group groupname
no aaa accounting resource method-list stop-failure [broadcast] group groupname
Syntax Description
method-list
|
Method used for accounting services. Use one of the following options:
• default: Uses the listed accounting methods that follow this argument as the default list of methods for accounting services.
• string: Character string used to name the list of accounting methods.
|
broadcast
|
(Optional) Enables sending accounting records to multiple AAA servers. Simultaneously sends accounting records to the first server in each group. If the first server is unavailable, failover occurs using the backup servers defined within that group.
|
group groupname
|
Group to be used for accounting services. Use one of the following options:
• string: Character string used to name a server group.
• radius: Uses list of all RADIUS hosts.
• tacacs+: Uses list of all TACACS+ hosts.
|
Defaults
No default behavior or values.
Command Modes
Global configuration
Command History
Release
|
Modification
|
12.1(3)T
|
This command was introduced.
|
Usage Guidelines
Use the aaa accounting resource stop-failure group command to generate a "stop" record for any calls that do not reach user authentication; this function creates "stop" accounting records for the moment of call setup. All calls that pass user authentication will behave as before; that is, no additional accounting records will be seen.
All existing authentication, authorization, and accounting (AAA) accounting method list and server group options are made available to this command.
Examples
The following example shows how to configure "stop" accounting records from the moment of call setup:
aaa authentication login AOL group radius local
aaa authentication ppp default group radius local
aaa authorization exec AOL group radius if-authenticated
aaa authorization network default group radius if-authenticated
aaa accounting exec default start-stop group radius
aaa accounting network default start-stop group radius
aaa accounting resource default stop-failure group radius
Related Commands
aaa accounting send stop-record authentication failure
To generate accounting "stop" records for users who fail to authenticate at login or during session negotiation, use the aaa accounting send stop-record authentication failure command in global configuration mode. To stop generating records for users who fail to authenticate at login or during session negotiation, use the no form of this command.
aaa accounting send stop-record authentication failure
no aaa accounting send stop-record authentication failure
Syntax Description
This command has no arguments or keywords.
Defaults
Disabled
Command Modes
Global configuration
Command History
Release
|
Modification
|
12.0(5)T
|
This command was introduced.
|
Usage Guidelines
Use this command to generate accounting "stop" records for users who fail to authenticate at login or during session negotiation. When aaa accounting is activated, the Cisco IOS software by default does not generate accounting records for system users who fail login authentication or who succeed in login authentication but fail PPP negotiation for some reason.
Examples
The following example generates "stop" records for users who fail to authenticate at login or during session negotiation:
aaa accounting send stop-record authentication failure
aaa accounting suppress null-username
To prevent the Cisco IOS software from sending accounting records for users whose username string is NULL, use the aaa accounting suppress null-username command in global configuration mode. To allow sending records for users with a NULL username, use the no form of this command.
aaa accounting suppress null-username
no aaa accounting suppress null-username
Syntax Description
This command has no arguments or keywords.
Defaults
Disabled
Command Modes
Global configuration
Command History
Release
|
Modification
|
11.2
|
This command was introduced.
|
Usage Guidelines
When aaa accounting is activated, the Cisco IOS software issues accounting records for all users on the system, including users whose username string, because of protocol translation, is NULL. This command prevents accounting records from being generated for those users who do not have usernames associated with them.
Examples
The following example supresses accounting records for users who do not have usernames associated with them:
aaa accounting suppress null-username
Related Commands
Command
|
Description
|
aaa accounting
|
Enables AAA accounting of requested services for billing or security purposes.
|
aaa accounting update
To enable periodic interim accounting records to be sent to the accounting server, use the aaa accounting update command in global configuration mode. To disable interim accounting updates, use the no form of this command.
aaa accounting update [newinfo] [periodic number]
no aaa accounting update
Syntax Description
newinfo
|
(Optional) Causes an interim accounting record to be sent to the accounting server whenever there is new accounting information to report relating to the user in question.
|
periodic
|
(Optional) Causes an interim accounting record to be sent to the accounting server periodically, as defined by the argument number.
|
number
|
Integer specifying number of minutes.
|
Defaults
Disabled
Command Modes
Global configuration
Command History
Release
|
Modification
|
11.3
|
This command was introduced.
|
Usage Guidelines
When aaa accounting update is activated, the Cisco IOS software issues interim accounting records for all users on the system. If the keyword newinfo is used, interim accounting records will be sent to the accounting server every time there is new accounting information to report. An example of this would be when IP Control Protocol (IPCP) completes IP address negotiation with the remote peer. The interim accounting record will include the negotiated IP address used by the remote peer.
When used with the keyword periodic, interim accounting records are sent periodically as defined by the argument number. The interim accounting record contains all of the accounting information recorded for that user up to the time the accounting record is sent.
When using both the newinfo and periodic keywords, interim accounting records are sent to the accounting server every time there is new accounting information to report, and accounting records are sent to the accounting server periodically as defined by the argument number. For example, if you configure aaa accounting update newinfo periodic number, all users currently logged in will continue to generate periodic interim accounting records while new users will generate accounting records based on the newinfo algorithm.
Caution 
Using the
aaa accounting update periodic command can cause heavy congestion when many users are logged in to the network.
Examples
The following example sends PPP accounting records to a remote RADIUS server. When IPCP completes negotiation, this command sends an interim accounting record to the RADIUS server that includes the negotiated IP address for this user; it also sends periodic interim accounting records to the RADIUS server at 30 minute intervals.
aaa accounting network default start-stop group radius
aaa accounting update newinfo periodic 30
Related Commands
Command
|
Description
|
aaa accounting
|
Enables AAA accounting of requested services for billing or security purposes.
|
aaa dnis map accounting network
To map a Dialed Number Information Service (DNIS) number to a particular authentication, authorization, and accounting (AAA) server group that will be used for AAA accounting, use the aaa dnis map accounting network command in global configuration mode. To remove DNIS mapping from the named server group, use the no form of this command.
aaa dnis map dnis-number accounting network [start-stop | stop-only | none] [broadcast] group
groupname
no aaa dnis map dnis-number accounting network
Syntax Description
dnis-number
|
Number of the DNIS.
|
start-stop
|
(Optional) Indicates that the defined security server group will send a "start accounting" notice at the beginning of a process and a "stop accounting" notice at the end of a process. The "start accounting" record is sent in the background. (The requested user process begins regardless of whether the "start accounting" notice was received by the accounting server.)
|
stop-only
|
(Optional) Indicates that the defined security server group will send a "stop accounting" notice at the end of the requested user process.
|
none
|
(Optional) Indicates that the defined security server group will not send accounting notices.
|
broadcast
|
(Optional) Enables sending accounting records to multiple AAA servers. Simultaneously sends accounting records to the first server in each group. If the first server is unavailable, failover occurs using the backup servers defined within that group.
|
group groupname
|
At least one of the keywords described in Table 13.
|
Defaults
This command is disabled by default.
Command Modes
Global configuration
Command History
Release
|
Modification
|
12.0(7)T
|
This command was introduced.
|
12.1(1)T
|
• The optional broadcast keyword was added.
• The ability to specify multiple server groups was added.
• To accommodate multiple server groups, the name of the command was changed from aaa dnis map accounting network group to aaa dnis map accounting network.
|
Usage Guidelines
This command lets you assign a DNIS number to a particular AAA server group so that the server group can process accounting requests for users dialing in to the network using that particular DNIS. To use this command, you must first enable AAA, define an AAA server group, and enable DNIS mapping.
Table 12 contains descriptions of accounting method keywords.
Table 13 AAA Accounting Methods
Keyword
|
Description
|
group radius
|
Uses the list of all RADIUS servers for authentication as defined by the aaa group server radius command.
|
group tacacs+
|
Uses the list of all TACACS+ servers for authentication as defined by the aaa group server tacacs+ command.
|
group group-name
|
Uses a subset of RADIUS or TACACS+ servers for accounting as defined by the server group group-name.
|
In Table 13, the group radius and group tacacs+ methods refer to a set of previously defined RADIUS or TACACS+ servers. Use the radius-server host and tacacs+-server host commands to configure the host servers. Use the aaa group server radius and aaa group server tacacs+ commands to create a named group of servers.
Examples
The following example maps DNIS number 7777 to the RADIUS server group called group1. Server group group1 will use RADIUS server 172.30.0.0 for accounting requests for users dialing in with DNIS 7777.
radius-server host 172.30.0.0 acct-port 1646 key cisco1
aaa group server radius group1
aaa dnis map 7777 accounting network group group1
Related Commands
Command
|
Description
|
aaa dnis map authentication ppp group
|
Maps a DNIS number to a particular authentication server group.
|
aaa dnis map enable
|
Enables AAA server selection based on DNIS.
|
aaa group server
|
Groups different server hosts into distinct lists and distinct methods.
|
aaa new-model
|
Enables the AAA access control model.
|
radius-server host
|
Specifies a RADIUS server host.
|
aaa session-mib
To enable disconnect by using Simple Network Management Protocol (SNMP), use the aaa session-mib global configuration mode command. To disable this function, use the no form of this command.
aaa session-mib disconnect
no aaa session-mib disconnect
Syntax Description
disconnect
|
Enables authentication, authorization, and accounting (AAA) session MIB disconnect.
|
Defaults
No default behavior or values.
Command Modes
Global configuration
Command History
Release
|
Modification
|
12.1(3)T
|
This command was introduced.
|
Usage Guidelines
Use the aaa session-mib command to terminate authenticated client connections using SNMP.
You must enable the disconnect keyword with this command. Otherwise, the network management station cannot perform set operations and disconnect users; it can only poll the table.
Examples
The following example shows how to enable a AAA session MIB to disconnect authenticated clients using SNMP:
aaa session-mib disconnect
accounting
To enable authentication, authorization, and accounting (AAA) accounting services to a specific line or group of lines, use the accounting command in line configuration mode. To disable AAA accounting services, use the no form of this command.
accounting {arap | commands level | connection | exec} [default | list-name]
no accounting {arap | commands level | connection | exec} [default | list-name]
Syntax Description
arap
|
Enables accounting on lines configured for AppleTalk Remote Access Protocol (ARAP).
|
commands level
|
Enables accounting on the selected lines for all commands at the specified privilege level. Valid privilege level entries are 0 through 15.
|
connection
|
Enables both CHAP and PAP, and performs PAP authentication before CHAP.
|
exec
|
Enables accounting for all system-level events not associated with users, such as reloads on the selected lines.
|
default
|
(Optional) The name of the default method list, created with the aaa accounting command.
|
list-name
|
(Optional) Specifies the name of a list of accounting methods to use. If no list name is specified, the system uses the default. The list is created with the aaa accounting command.
|
Defaults
Accounting is disabled.
Command Modes
Line configuration
Command History
Release
|
Modification
|
11.3 T
|
This command was introduced.
|
Usage Guidelines
After you enable the aaa accounting command and define a named accounting method list (or use the default method list) for a particular type of accounting, you must apply the defined lists to the appropriate lines for accounting services to take place. Use the accounting command to apply the specified method lists (or if none is specified, the default method list) to the selected line or group of lines.
Examples
The following example enables command accounting services (for level 15) using the accounting method list named charlie on line 10:
accounting commands 15 charlie
Related Commands
Command
|
Description
|
aaa accounting
|
Enables AAA accounting of requested services for billing or security purposes.
|
accounting (gatekeeper)
To enable the accounting on the gatekeeper, use the accounting command in gatekeeper configuration mode. To disable accounting, use the no form of this command.
accounting
no accounting
Syntax Description
This command has no arguments or keywords.
Defaults
Disabled
Command Modes
Gatekeeper configuration
Command History
Release
|
Modification
|
11.3(2)NA
|
This command was introduced.
|
12.0(3)T
|
This command was integrated into Cisco IOS release 12.0(3)T.
|
Usage Guidelines
Specify a RADIUS server before using the accounting command.
Examples
The following example enables the gateway to report user activity to the RADIUS server in the form of connection accounting records:
aaa accounting connection start-stop group radius
Related Commands
Command
|
Description
|
aaa new-model
|
Enables the AAA access control model.
|
radius-server host
|
Specifies a RADIUS server host.
|
radius-server key
|
Sets the authentication and encryption key for all RADIUS communications between the router and the RADIUS daemon.
|
ppp accounting
To enable authentication, authorization, and accounting (AAA) accounting services on the selected interface, use the ppp accounting command in interface configuration mode. To disable AAA accounting services, use the no form of this command.
ppp accounting default
no ppp accounting
Syntax Description
default
|
The name of the method list is created with the aaa accounting command.
|
Defaults
Accounting is disabled.
Command Modes
Interface configuration
Command History
Release
|
Modification
|
11.3 T
|
This command was introduced.
|
Usage Guidelines
After you enable the aaa accounting command and define a named accounting method list (or use the default method list), you must apply the defined lists to the appropriate interfaces for accounting services to take place. Use the ppp accounting command to apply the specified method lists (or if none is specified, the default method list) to the selected interface.
Examples
The following example enables accounting on asynchronous interface 4 and uses the accounting method list named charlie:
Related Commands
Command
|
Description
|
aaa accounting
|
Enables AAA accounting of requested services for billing or security purposes.
|
show accounting
To step through all active sessions and to print all the accounting records for actively accounted functions, use the show accounting command in EXEC mode. Use the no form of this command to disable viewing and printing accounting records.
show accounting
no show accounting
Syntax Description
This command has no arguments or keywords.
Command Modes
EXEC
Command History
Release
|
Modification
|
11.1
|
This command was introduced.
|
Usage Guidelines
The show accounting command allows you to display the active accountable events on the network. It provides system administrators with a quick look at what is going on, and it also can help collect information in the event of a data loss on the accounting server.
The show accounting command displays additional data on the internal state of authentication, authorization, and accounting (AAA) if debug aaa accounting is activated.
Examples
The following is sample output from the show accounting command.
Active Accounted actions on Interface Serial0:19, User jdoe Priv 1
Task ID 15, Network Accounting record, 00:00:18 Elapsed
task_id=15 timezone=PDT service=ppp mlp-links-max=4 mlp-links-current=4
protocol=ip addr=9.0.0.2 mlp-sess-id=1
Active Accounted actions on Interface Serial0:20, User jdoe Priv 1
Task ID 13, Network Accounting record, 00:00:49 Elapsed
task_id=13 timezone=PDT service=ppp mlp-links-max=4 mlp-links-current=4
protocol=ip addr=9.0.0.2 mlp-sess-id=1
Active Accounted actions on Interface Serial0:21, User jdoe Priv 1
Task ID 11, Network Accounting record, 00:01:19 Elapsed
task_id=11 timezone=PDT service=ppp mlp-links-max=4 mlp-links-current=4
protocol=ip addr=9.0.0.2 mlp-sess-id=1
Active Accounted actions on Interface Serial0:22, User jdoe Priv 1
Task ID 9, Network Accounting record, 00:01:20 Elapsed
task_id=9 timezone=PDT service=ppp mlp-links-max=4 mlp-links-current=4
mlp-sess-id=1 protocol=ip addr=9.0.0.2
Active Accounted actions on , User (not logged in) Priv 0
Task ID 1, Resource-management Accounting record, 06:21:47 Elapsed
task_id=1 timezone=PDT rm-protocol-version=1.0
service=resource-management
protocol=nas-status event=nas-start reason=reload
Overall Accounting Traffic
Starts Stops Updates Active Drops
User creates:21, frees:9, Acctinfo mallocs:15, frees:6
Users freed with accounting unaccounted for:0
Table 14 describes the fields contained in this example.
Table 14 show accounting Field Descriptions
Field
|
Description
|
Active Accounted actions on
|
Terminal line or interface name with which the user logged in.
|
User
|
ID of the user.
|
Priv
|
Privilege level of the user.
|
Task ID
|
Unique identifier for each accounting session.
|
Accounting Record
|
Type of accounting session.
|
Elapsed
|
Length of time (hh:mm:ss) for this session type.
|
Related Commands
Command
|
Description
|
aaa accounting
|
Enables AAA accounting of requested services for billing or security purposes.
|
show line
|
Displays the parameters of a terminal line.
|
show users
|
Displays information about the active lines on the router.
|