• No se han encontrado resultados

6.3 ANÁLISIS DE DATOS Y RESULTADOS

6.3.2 Análisis de los resultados

Generic traffic shaping is a mechanism for controlling the rate at which a router interface

transmits outbound traffic. Generic traffic shaping was added to the IOS in version 11.2 to enable a network administrator to specify the maximum traffic rate for outbound transmission through an interface. When applied to frame-relay (sub-) interfaces, generic traffic shaping can be made adaptive in that it will respond to the reception of frames with the BECN bit set by lowering the transmission rate toward the rate specified as the minimum rate. This enables the router to adapt to congestion conditions and throttle traffic flow back to the interface's CIR, which the network should honor. An additional frame-relay feature of generic traffic shaping is the ability to

"reflect" FECNs as BECNs. That is, with fecn-adaptive enabled, the router will set the BECN bit in frames returning to the source of the traffic which arrived with the FECN bit set. This enables the routers to respond more quickly to congestion conditions in that they do not have to wait for the frame-relay switches to set the BECN bit before throttling traffic. The ultimate goal of generic traffic shaping is rate-control output traffic in an effort to avoid congestion and to intelligently react when congestion arises.

Generic traffic employs a token-bucket approach for rate control. The algorithm allows for the specification of a traffic rate, burst size, and excess burst size. When used with frame relay, these parameters map directly to CIR, Bc, and Be, respectively.

Page 120

Configuring Generic Traffic Shaping

Generic traffic shaping is configured on an individual (sub-) interface basis. Access lists can be used if rate control is only desired for a subset of the interface's traffic. The interface command used to enable generic traffic shaping is

traffic-shape rate bit-rate [burst-size [excess-burst-size]]

where bit-rate specifies the desired output bit rate. It should be sent to the CIR of the DLCI which it is being applied to.

burst-size is optional, but should be used with frame-relay interfaces. It should be set to the Bc value used by the frame-relay network provider.

excess-burst-size is also optional and should be set the Be value used by the frame-relay network provider.

EXAMPLE

An example configuration implementing generic traffic shaping is shown in Figure 5-3. A voice-enabled router connects to a frame-relay network using a single port. That port uses two PVCs. One of those PVCs will carry voice traffic, while the other PVC will carry only data traffic. To avoid congestion and congestion-related packet loss, generic traffic shaping is configured for the voice-bearing PVC. The bit rate is set to the CIR, burst size set to the Bc, and

! hostname routerA ! interface Serial0/0 bandwidth 512 no ip address ip directed-broadcast encapsulation frame-relay frame-relay lmi-type ansi !

interface Serial0/0.1 point-to-point description Voice-bearing PVC bandwidth 128 ip address 192.168.1.1 255.255.255.0 no ip directed-broadcast traffic-shape rate 128000 64000 32000 frame-relay interface-dlci 100 !

interface Serial0/0.2 point-to-point description data-only PVC

bandwidth 128

ip address 192.168.2.1 255.255.255.0

Page 121

Figure 5-3 Generic traffic shaping.

no ip directed-broadcast

!

The values for Bc and Be are obtained from the provider. In this example, it is assumed that the provider configured a Tc of 0.5 s. Using the formula

or

Bc then becomes 64000.

Page 122 Since the data-only PVC will be transmitting bursty traffic, it needs to be controlled so that it will not unfairly grab bandwidth from the voice bearing PVC. However, the goal is to still allow the interface to take advantage of the frame relay's ability to deliver bursts of traffic. To accomplish this, generic traffic shaping will be configured with a peak rate equal to that of the link

bandwidth minus the voice bearing PVC's bandwidth. 512 kbps - 128 kbps = 384 kbps

To prevent significant data loss as well, each PVC should be configured to react to frame-relay congestion notifications. The interface command to allows generic traffic shaping to react to BECNs is

traffic-shape adaptive [bit-rate]

where bit-rate represents the minimum value traffic should be shaped to on reception of BECNs. In most situations, this value should be set to the CIR associated with the PVC. By using the PVC's CIR, the router can scale back transmission to a rate that is supported by the

frame-relay network.

In the example, applying this command to the data-only PVC will force the router to back off its transmission rate on the subinterface to the PVC's CIR when BECNs are received. The modified configuration then becomes the following:

! hostname routerA ! interface Serial0/0 bandwidth 512 no ip address ip directed-broadcast encapsulation frame-relay frame-relay lmi-type ansi !

interface Serial0/0.1 point-to-point description Voice-bearing PVC

Page 123 ip address 192.168.2.1 255.255.255.0 no ip directed-broadcast traffic-shape rate 384000 192000 192000 traffic-shape adaptive 128000 frame-relay interface-dlci 102 !

As a result of this configuration, the router can use most of the link's bandwidth for the data-only PVC, but is forced to back-off its transmission rate to the CIR when congestion occurs.

The last refinement is to enable more responsive congestion identification, by configuring the data-only PVC's remote peer to reflect FECNs back to the source as BECNs. The BECNs are sent using Q.922 test response messages. This is helpful in that the downstream router can notify the upstream router of congestion in an almost out-of-band manner. The intermediary frame-relay switches can only set the BECN bit in frames returning to the offending source router. If there are no immediate return frames, as there often are with windowing protocols such as TCP, then the source router will continue to overwhelm the network and, perhaps, cause additional congestion. The following interface command should be configured on both sides of the PVC in order to enable the reflection of FECNs as BECNs.

traffic-shape fecn-adapt

To complete this example, a subset of the configuration for data-only router B and complementary voice-enabled router C is included in addition to the updated router A configuration. Router A ! hostname routerA ! interface Serial0/0 bandwidth 512 no ip address ip directed-broadcast encapsulation frame-relay frame-relay lmi-type ansi !

interface Serial0/0.1 point-to-point description Voice-bearing PVC bandwidth 128 ip address 192.168.1.1 255.255.255.0 no ip directed-broadcast traffic-shape rate 128000 64000 32000 frame-relay interface-dlci 100 Page 124 !

description data-only PVC bandwidth 128 ip address 192.168.2.1 255.255.255.0 no ip directed-broadcast traffic-shape rate 384000 192000 192000 traffic-shape adaptive 128000 traffic-shape fecn-adapt frame-relay interface-dlci 102 ! Router B ! hostname routerB ! interface Serial0 bandwidth 512 no ip address ip directed-broadcast encapsulation frame-relay frame-relay lmi-type ansi !

interface Serial0.1 point-to-point description data-only PVC bandwidth 128 ip address 192.168.2.2 255.255.255.0 no ip directed-broadcast traffic-shape rate 384000 192000 19200 traffic-shape adaptive 128000 traffic-shape fecn-adapt frame-relay interface-dlci 202 ! Router C ! hostname routerC ! interface Serial0/0 bandwidth 256 no ip address ip directed-broadcast encapsulation frame-relay frame-relay lmi-type ansi !

interface Serial0/0.1 point-to-point description Voice-bearing PVC bandwidth 128 ip address 192.168.1.2 255.255.255.0 no ip directed-broadcast traffic-shape rate 128000 64000 32000 frame-relay interface-dlci 200 ! Page 125

Monitoring Generic Traffic Shaping

used. Here is sample output from Router A:

RouterA#sh traffic-shape

Access Target Byte Sustain Excess Interval Increment Adapt I/F List Rate Limit bits/int bits/int (ms) (bytes) Active Se0.1 128000 12000 64000 32000 500 8000 - Se0.2 384000 48000 192000 192000 500 24000 BECN

Note that the time interval (500 ms) is automatically derived by the router based upon the target rate and the burst size. Additionally, the activity of generic traffic shaping can be monitored using the show traffic-shape statistics command. Sample output follows:

RouterA#sh traffic-shape statistics

Access Queue Packets Bytes Packets Bytes Shaping I/F List Depth Delayed Delayed Active Se0.1 25 4460 500413 100 28455 yes Se0.2 0 1384 194366 0 0 no

At this point, traffic shaping is active on subinterface 0.1 with 25 currently queued and inactive on subinterface 0.2. The other values are cumulative so a total of 4460 packets containing 500,413 bytes have passed through subinterface 0.1 since traffic shaping was configured and of those, 100 packets containing 28,455 bytes have been delayed due to excess rate conditions.

Documento similar