Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
New Member

QoS configuration

This is my network scenario:

-a DSL access to the Internet that works properly.

-a PBX based on Asterisk and many Ip-phones. The signaling protocol used is SIP.

-a SIP account to a SIP Proxy on the Internet. In this way the PBX could receive incoming calls from the PSTN and place outgoing calls to the PSTN.

-many workstation attached at the same LAN segment.

Now I've realize that sometimes Voip calls quality it's not good.

So I'm trying to implement QoS (CBWFQ) on the 837 (IOS 12.4) that share Internet access. Here's a part of the configuration. In particular the main purpose is to reserve at least 128 Kbit/s to support at least 4 VoIP calls (the codec used is g.729).

class-map VoIP

match access-group 102

policy-map VoIP

class VoIP

bandwidth 128

interface atm 0.35

....

bandwidth 2048

.....

.....

.....

service policy output VoIP

access-list 102 permit udp any eq 5060 any eq 5060

access-list 102 permit udp any range 60000 65000 host <ip address SIP proxy>

So I try to check my configuration with this command:

show policy-map interface atm 0.35

but I see that all VoIP traffic is matched as class-default.

What's wrong?

Thanks in advance.

17 REPLIES

Re: QoS configuration

Hi

In your access-list , you have configured the source port to be 5060 and source port that tries to access the sip proxy would contact in a diff port , so match would not occur.

Similarly source port range might not be between 60000 to 65000 .Its all the destination ports used rather than the souce ports.

Try changing the access-list to

access-list 102 permit udp any any eq 5060

access-list 102 permit udp any host range 60000 65000

Try and let us know wheter u get hits or if you have a fixed sip proxy ip , give a permit ip level access for sip proxy server.

Just to add in policy map , instead of " bandwidth 128 " change it to " priority 128 " so that voice traffic is given first priority over other traffic.

Hope this helps

regards

vanesh k

Re: QoS configuration

Hi

Just want to clear from you abt the port mentioned 60000 to 65000 , bcos voice applications usually use udp ports in the range 16384-32767 (RTP ) .

regards

vanesh k

New Member

Re: QoS configuration

Hi,

I've edit my configuration.

!

class-map match-all SIP

match access-group 102

class-map match-all RTP

match access-group 103

!

!

policy-map VoIP

class SIP

priority 128

class RTP

priority 128

!

!

.....

access-list 102 permit udp any any eq 5060

access-list 103 permit udp any range 60000 65000

Now the policy map match all outbound SIP and RTP traffic.

What about inbound VoIP call?

Re: QoS configuration

Hi

From your config , you are assigning 128K for your voice traffic . Also chcek wheter now there is no traffic in the default class to chcek wheter the ports you have mapped is correct.

The QOS configuration you have done is only Local to your router and help in case if your Last mile is congested , and in the SP network traffic would be sent in his default class .For the return traffic , you need to coordinate with the SP for doing the same.

Hope this helps

regards

vanesh k

New Member

Re: QoS configuration

Hi,

I've already check the configuration in my lab on 2611XM.Only VoIP traffic is matched by the policy. All other traffic is matched as class-default.

I confirm that range port used by our own Asterisk PBK is udp 60000 65000.

That's all clear now about inbound calls.

I've another question.

How to apply this QoS configuration on a 837?

When I try to confirm the service policy command on the atm sub-interface configuration the CLI gives me an error.

It says that CBWFQ is not supported.What's wrong?

I've attached my configuration.

Thanks in advance.

Re: QoS configuration

Hi

Pls let us know the Ios version you are using in your router .

regards

vanesh k

New Member

Re: QoS configuration

This is the show version output:

Cisco IOS Software, C837 Software (C837-K9O3Y6-M), Version 12.4(5b), RELEASE SOFTWARE (fc2)

Technical Support: http://www.cisco.com/techsupport

Copyright (c) 1986-2006 by Cisco Systems, Inc.

Compiled Wed 19-Apr-06 05:59 by ssearch

ROM: System Bootstrap, Version 12.2(11r)YV3, RELEASE SOFTWARE (fc2)

XXXXX uptime is 20 hours, 2 minutes

System returned to ROM by power-on

System image file is "flash:c837-k9o3y6-mz.124-5b.bin"

Thanks in advance for your help.

Best regards.

New Member

Re: QoS configuration

I had the same problem. Here is my config. It works now.

class-map match-any Avaya

match access-group 101

match ip dscp ef

class-map match-any voice

match ip dscp ef

!

!

policy-map Avaya

class Avaya

set dscp ef

policy-map voice

class voice

priority percent 70

interface Multilink1

description Multilink interface to valcpa1

ip address 192.168.158.70 255.255.255.252

ip route-cache flow

ip tcp header-compression iphc-format

load-interval 30

service-policy output voice

ppp multilink

ppp multilink fragment-delay 10

ppp multilink interleave

multilink-group 1

ip rtp header-compression iphc-format

interface FastEthernet0/0.1

encapsulation dot1Q 1 native

ip address 172.29.85.254 255.255.255.0

ip helper-address 172.29.4.136

ip helper-address 172.29.4.137

service-policy input Avaya

access-list 101 permit ip host 172.29.85.37 any

access-list 101 permit ip host 172.29.85.38 any

Re: QoS configuration

Hi

Your IOS supports CBWFQ , I think on ATM sub-interface it is not allowing a plane service-policy . We will check by configuring a parent-child class.

Considering your bandwidth to be 2048 kbps

policy-map child

class SIP

priority 128

class RTP

priority 128

class class-default

fair-queue

!

policy-map VoIP

Class class-default

shape average 2048000

service-policy output child

Apply " service-policy output VoIP " in the ATM-subinterface and check.

Pls check the same and Let us know to help further.

Hope this helps

regards

vanesh k

New Member

Re: QoS configuration

Hi,

I've read documentation at this URL:

http://www.cisco.com/univercd/cc/td/doc/product/software/ios124/124cg/hqos_c/qosh_bk.pdf

In particular I've seen this example (page 880):

class-map class1

match access-group 101

class-map class2

match access-group 102

policy-map policy1

class class1

bandwidth 500

queue-limit 30

class class2

bandwidth 1000

interface ATM1/1/0.46 multipoint

ip address 200.126.186.2 255.255.255.0

pvc cisco 46

vbr-nrt 2000 2000

encap aal5snap

service policy output policy1

What do you think?

I'll try to implement your solution first.

Thanks.

Re: QoS configuration

Hi

Iam not sure about the ATM QOS config given in the Doc , Try it out and share the output , so that it would be a good learning for us.

regards

vanesh k

New Member

Re: QoS configuration

Hi,

I've edit my configuration again, there's a copy in the conf.txt file.

I've also check my new configuration.

At the ATM PVC, as you can see in the file called output.txt, VoIP packets are sent to the SIP-calls class, all other packets are sent to the class-default.

So I try to make some calls to verify voice quality.I've seen that if only VoIP calls,and no other traffic, flow through the ATM interface the voice quality is good.

If a VoIP call and an application that upload data,like an FTP connection that send a file to a host on the Internet, transmit at the same time to the ATM interface then the VoIP call become incomprehensible.

So now I don't now what to do.

Thanks in advance.

Best Regards.

P.S. I've check from my SP about DSL parameters. Here they are: ULL 2048 Kbit/s downstream, MCR 256 Kbit/s.

Bronze

Re: QoS configuration

Hi,

Looks like you're matching the SIP traffic OK, now the problem is you're not matching RTP. As someone else mentioned, it uses UDP on even ports in the range 16384 - 32767. The easiest way to match that traffic is first try DSCP or Precedence, then use NBAR as a backup.

Here is my config for an 871. Hopefully this works on the 830 as well, but I'm not sure if the "match ip rtp" command is supported.

class-map match-any SIP

match ip dscp cs3

match ip precedence 3

match access-group name SIP-LIST

!

class-map match-any RTP

match ip dscp ef

match ip precedence 5

match ip rtp 16384 16383

!

policy-map VoIP

class SIP

priority 16

class RTP

priority 128

class class-default

fair-queue

!

interface FastEthernet4

description Connection to Internet

ip address dhcp

ip nbar protocol-discovery

service-policy out VoIP

!

ip access-list extended SIP-LIST

permit udp any any eq 5060

!

New Member

Re: QoS configuration

Hi,

As you can see in the output.txt file RTP packets are matched also.

Match: access-group 103

49480 packets, 3562560 bytes

5 minute rate 0 bps

I confirm that our VoIP application, based on Asterisk PBX, used this port range: RTP 60000-65000.

Bronze

Re: QoS configuration

Ah ok. Just FYI Cisco recommends you match using DSCP or IP Precedence when possible, just in case the port is not know or changes.

Just curious, what does "show int ATM0.35" look like? I noticed you have a max of only 40 conversations on that interface. On my 831 with the same config, I have 264 but that of course is Ethernet.

New Member

Re: QoS configuration

Hi johnnylingo,

Do you think that my voice problem is due to the conversation limit in the queue?

I really don't knowk what to do..

New Member

Re: QoS configuration

Hi,

I'm trying to implement your solution.

Router accept the command "shape average 2048000" but this command not appear if I type a "show run".

Moreover the router accept the "service-policy output VoIP" in the atm-sub-if but this command also not appear in configuration after a "show run".

Moreover no information about queue are displayed with a "show policy-map inetrface atm 0.35"

Any other ideas?

Thanks for all.

429
Views
0
Helpful
17
Replies
CreatePlease to create content