# Configuring Disconnect Cause Information

You can configure an E Series LNS to convey PPP-related disconnect cause information to its L2TP peer. Enabling an LNS to send disconnect cause information to an LAC is particularly useful in an environment where the LAC initiates tunnels without a client’s request, knowledge, or approval. In this type of environment, all PPP signaling for the tunnel session takes place between the LNS and the client, without active participation of the LAC. As a result, the LAC is not aware of the reason that a session has disconnected.

| Note: An E Series LAC does not send PPP Disconnect Case Code AVPs to an LNS. In the event that a third-party LAC does send the AVP to an E Series LNS, the LNS discards the AVP.

1. Generating the Disconnect Cause AVP Globally
2. Generating the Disconnect Cause AVP with a Host Profile
3. Enabling RADIUS Accounting for Disconnect Cause
4. Displaying Disconnect Cause Statistics

## Generating the Disconnect Cause AVP Globally

You use the l2tp disconnect-cause command to specify that the LNS include the PPP Disconnect Cause Code AVP in all L2TP Call-Disconnect-Notify (CDN) messages that it sends to the LAC. For example, this feature enables the LAC to obtain information about the cause of a session disconnection,

- To enable disconnect cause generation chassis-wide on the LNS:
  host1(config)#l2tp disconnect-cause

  | Note: Sessions for which the AVP generation is enabled by the host-profile-specific disconnect-cause command continue to generate the AVP.

## Generating the Disconnect Cause AVP with a Host Profile

You use the disconnect-cause command in L2TP Destination Profile Host Configuration mode to specify that the E Series LNS generate PPP Disconnect Cause Code AVPs. This command pertains only to L2TP sessions to which the L2TP destination host profile applies. The AVP is included in all L2TP CDN messages that the LNS sends to an LAC for covered sessions.

| Note: This command is used only for dial-in sessions; use the l2tp disconnect-cause command in Global Configuration mode to generate PPP Disconnect Cause Code AVPs for dial-out sessions.

- To enable disconnect cause generation for all tunnels that use a particular host profile on the LNS:
  host1(config-l2tp-dest-profile-host)#disconnect-cause

## Enabling RADIUS Accounting for Disconnect Cause

You use the radius include l2tp-ppp-disconnect-cause acct-stop enable command to specify that the Disconnect-Cause RADIUS attribute (VSA 26-51) is generated and included in RADIUS acct-stop and acct-tunnel-link-stop records. RADIUS VSA 26-51 is not included in the accounting records by default.

At the LAC, this accounting reports remotely generated disconnect cause information received from the LNS. At the LNS, the accounting reports locally generated disconnect cause information.

- To enable disconnect cause accounting:
  host1(config)#radius include l2tp-ppp-disconnect-cause acct-stop enable

## Displaying Disconnect Cause Statistics

You can display chassis-wide summary statistics for all disconnect cause information received by the LAC, sorted by code number.

- To display summary statistics for disconnect cause information:
  host1(config)#show l2tp received-disconnect-cause-summary