CBWFQ Bandwidth Test

Unanswered Question
Mar 17th, 2010

Hi, All! Please, help to cope with the lack of understanding. I'm studing QoS. Here is my test lab configuration:

(PC1) -> (E0/1 - E0/0) -> (PC2)

ip access-list extended UDP-ACL
  permit udp any any

class-map match-all UDP-CLASS
  match access-group name UDP-ACL

  class UDP-CLASS
    bandwidth percent 33
  class class-default
    bandwidth percent 66

interface Ethernet0/0
  bandwidth 5000
  ip address
  load-interval 60
  tx-ring-limit 1
  tx-queue-limit 1
  max-reserved-bandwidth 100
  service-policy output BANDWIDTH-TEST

I'm running bandwidth test from PC1 to PC2 through router's E0/0 interface. PC1 is attached to E0/1. There is no policy on E0/1. PC1 is traffic generator, PC2 is traffic reciver and measurer. One bandwidth test thread is running via TCP, another via UDP.

This is my results:

UDP ~ 7,7 Mbit/s
TCP ~ 336 Kbit/s

But i think there is will be about 3,3 Mbits/s (66% of 5Mbit/s)  for TCP. Why so? When i'm using nested policies with shaper attached to topmost policy - all is ok.

I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 2 (4 ratings)
francisco_1 Thu, 03/18/2010 - 03:34

Your CBWFQ policy map is applied on the interface out so how do you expect that to apply to traffic generated from PC1 since PC1 is behind interface Ethernet0/1!  With CBWFQ, the bandwidth reservation will only come in to effect when there is conjestion. If you want to limit BW for PC1, apply CBWFQ policy map also to interface Ethernet0/1 out or use policing by reserving maximum BW for PC1 and apply in on interface Ethernet0/0.

Also noticed you are using  rx-limit to limit hardware queue. why is that?

Eugene Khabarov Thu, 03/18/2010 - 03:47

You absolutely do not understand me. I do not need to limit the bandwidth, I want to guarantee it. Traffic flow is going to interface E0/1 throughout router to E0/0. E0/1 - ingress, E0/0 - egress.

Also noticed you are using  rx-limit to limit hardware queue. why is that?

I'm not using rx-limit. I'm using  tx-ring-limit 1

francisco_1 Thu, 03/18/2010 - 04:51

My mistake i meant "tx-ring-limit"

I could be wrong (Maybe someone else can comment) but my understanding is the tx-ring-limit  is normally used to ajust the size of the hardware  when the default queueing is used FIFO. Packet sent to the interface are enqueued directly in to the haware transit ring so i dont understand why you have it setup when you are using MQC on your router for software queueing.



Eugene Khabarov Thu, 03/18/2010 - 04:56

  is normally used to ajust the size of the hardware  when the default queueing is used FIFO

You are wrong. Hardware queue is always fifo.  If there is enougth space in hardware queue - software queue is not used.

Giuseppe Larosa Thu, 03/18/2010 - 04:12

Hello Ekhabarov,

in the case of a LAN interface like this the use of hierarchical QoS provides benefits by creating a logical pipe at the desired speed.

So this is the way to go in these cases as your results show.

A parent shaping all trafic  policy that invokes a child CBWFQ scheduler.

Otherwise, it is true that you have set bandwidth to 5 Mbps as administrative parameter, but this does not affect the way traffic is sent out the interface that has a natural speed of 10 Mbps.

As a result of this UDP traffic takes over because there is no flow control on it and TCP reacts to losses by reducing the TCP window or in any case by waiting the ACks from the receiving side.

I would not tune ring and queue size in this scenario that applies to physical queue you have software queues for shaping and the SW queues of CBWFQ that treat traffic. Once QoS decides to send a packet out it is placed in the tx ring.

Hope to help


Eugene Khabarov Thu, 03/18/2010 - 05:03

Perhaps i'm not understand you fully, but if we have actually 10 Mbps, why not CBWFQ allocates 66% of 10 Mbps for TCP (6,6 Mbit / s). Ie expected results should be as follows: 6,6 Mbps TCP, 3,3 Mbps UDP.


This Discussion

Related Content