• No results found

Configuring Multilink PPP and LF

Multilink PPP with LFI can be configured for one or more links. That is, it is not necessary to have multiple links bundled together in order to use

Page 79

Figure 4-6 LFI with WFQ.

LFI. The basic steps are to enable multilink PPP, enable LFI, and then finetune its performance. To enable MLPPP on a standard serial interface, first define a virtual template and virtual template interface:

!

interface Virtual-template1

multilink virtual-template 1

Then add the ppp multilink interface commands for LFI, including reducing the fragment delay and enabling the RTP interleaving using the following commands:

ppp multilink

ppp multilink interleave

ppp multilink fragment-delay 20 ip rtp reserve 16384 100 1000

where

ppp multilink interleave enables the fragment interleaving

ppp multilink fragment-delay sets the maximum fragment size in ms ip rtp reserve sets the base UDP port for VoIP traffic

100 = the range of port numbers

1000 = the maximum bandwidth in kbps allocated for the RTP traffic

Page 80

EXAMPLE

An MPP with LFI example follows, showing a voice-enabled 3600 router connected to another 3600 router over a fractional T1 link. The configuration excerpt for one 3600 is

! hostname 3600A ! multilink virtual-template 1 ! interface Virtual-template1 ip address 192.168.1.1 255.255.255.0 ppp multilink ppp multilink interleave ppp multilink fragment-delay 20 ip rtp reserve 16384 100 384 ! interface serial0/0 bandwidth 512 encapsulation ppp no ip address ppp multilink multilink-group 1 !

Traffic Shaping

With IOS v11.2, Cisco introduced generic traffic shaping to help control the rate of traffic flow through the router. Generic traffic uses a basic token-bucket mechanism to limit the output rate of traffic. Generic traffic shaping operates at the interface descriptor block (IDB) level within the software, making it applicable to both physical and logical interfaces. This means that it can be

used on subinterfaces, as well as physical interfaces. It can be applied to all traffic through the interface or to a select set of traffic identified by an access list.

The token-bucket algorithm is defined by an average bit rate, a traffic burst size, and a time interval. The three are bound by the equation

Average bit rate = burst size / time interval

This means that for any time interval, the output traffic should not exceed the average bit rate. By default, the burst size is set to the bit rate divided by 8. Solving the above equation for the time interval, we can see that this makes the default time interval 1¼8 of a second or 125 ms. Given that the average bit rate is measured over a time period and is not an instantaneous value,

Page 81 the actual transmission rate of the traffic can vary significantly as long as the actual amount of data transferred over the time interval is not greater than the burst size. The following example illustrates this.

EXAMPLE

Generic traffic shaping is configured to limit outbound traffic on a frame relay subinterface to 64 kbps. The port rate for the interface is 256 kbps. Since outbound traffic must be transmitted at the port rate, traffic shaping slows the output of packets every time interval. In this example the burst size is set to 64 kbps/8 s, or 8000 bits. Accordingly, the time interval is 1/8 s or 125 ms. This means that every 125 ms, the interface transmits 8000 bits of data over the PVC. However, since the interface is transmitting at the 256-kbps port rate, it takes only 31.25 ms to transmit the allotted 8000 bits. This means that every 125 ms, the router transmits 8000 bits of data for 31.25 ms and then waits 93.75 ms before transmitting more data over the PVC. The graph in Figure 4-7 represents this.

While policing traffic over 125-ms intervals is effective for most purposes, you may want more control over the rate of traffic flow. An increase in control can be accomplished by specifying smaller burst sizes, because these will mandate a higher sampling frequency or shorter time intervals.

It is important to note that the router completes transmission of frames regardless of whether the remaining bits in the frame have exceeded the burst size. In other words, if the burst size is 8000 bits, and the router has already transmitted 7500 bits during the current time interval and the next frame is a 1500 bytes long, the router will transmit the 1500-byte frame before waiting for the next time interval.

Figure 4-7 Generic traffic shaping.

Page 82 Generic traffic shaping can be configured on a per-interface basis using the traffic-shape interface command described below:

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

where

bit-rate = the desired output rate. It is specified in bits per second, so 64 kbps must be entered as 64000.

burst-size = the number of bits allowed to be transmitted during a time interval. Specifying the burst-size parameter is optional. If it is not specified, the router derives its value by dividing the bit rate by 8.

excess-burst-size = the maximum number of bits that can exceed the burst size in the first interval in a congestion event.

When applying generic traffic shaping to a frame-relay interface or subinterface, the bit rate should be set to the PVC's CIR, the burst size should be set to committed burst size Bc, and the excess burst size should be set to the excess burst size, or Be, for the PVC.

EXAMPLE

The following is an example of generic traffic shaping for frame-relay PVC. To apply generic traffic shaping to a 32-kbps PVC on a 56-kbps circuit with a Bc of 16 kb, and a Be of 4000 kb, the configuration would be as follows:

interface serial0/0

description Frame Relay circuit XXX encapsulation frame-relay

frame-relay lmi-type ansi no ip address

bandwidth 56 !

interface serial0/0.1

description Subinterface to site Y (DLCI-365) ip address 192.168.1.1 255.255.255.0

bandwidth 32

traffic-rate 32000 16000 4000 frame-relay interface-dlci 365 !

The traffic-rate command mirrors the frame-relay class of service parameters agreed to by the network provider. In practice, the router would

Page 83 transmit an average of 16,000 bits over half-second intervals and, when extra traffic was present, transmit up to 20,000 bits (Bc + Be) every half-second. When applied to frame-relay interfaces, generic traffic shaping will respond to BECNs by reducing the output rate to the committed information rate. This is discussed in more detail in the chapter on frame relay QoS.

In designing voice networks, the goal is to avoid both congestion and dropped frames. Therefore, it is a good practice to set the excess burst size to 0. This limits traffic rates to the committed rate and avoids packet loss within the frame-relay network.

Generic traffic shaping can also limit the rate at which traffic is transmitted to a specific destination through an interface using access lists to classify the traffic. In voice networks, generic traffic shaping can be effective at limiting the rate of nonvoice traffic. The interface command traffic-shape group in conjunction with an access list is used to accomplish this. The interface command syntax is

traffic-shape group access-list bit-rate [burst-size [excess-burst-size]]

where bit-rate, burst-size, and excess-burst-size maintain the same definitions as with the traffic-rate command.

EXAMPLE

The following is an example of a traffic group. In order to ensure that there are 24 kbps of bandwidth available for two VoIP sessions, an administrator may wish to limit other traffic to 32 kbps on a 56-kbps dedicated circuit. The configuration would be as follows:

!

interface serial 0/1

description 56 kbps link to site B circuit ID: encapsulation ppp

ip address 172.16.0.1 255.255.255.0 bandwidth 56

traffic-shape group 140 32000 4000 0 !

!

access-list 140 deny udp any any range 16384 16624 access-list 140 permit ip any any

!

The traffic-shape group command uses the filter created by access list 140 to determine which packets are shaped by the token-bucket shaper. Access list 140 simply tells the shaper to exclude all RTP voice packets

Page 84 from the filter, but to include all other outbound IP traffic in the filter. In practice, this example may not be optimum because it limits data traffic to 32 kbps, even when voice traffic is not present.

Generic traffic shaping is an effective tool for smoothing out traffic bursts and subsequently minimizing congestion and packet loss in the network. In voice networks, it is often combined with another QoS technique because although it provides a means for controlling congestion, it does not address latency issues.