# Quality/Volume Problem URGENT

**URL:** <https://community.asterisk.org/t/quality-volume-problem-urgent/15592>\
**Category:** Asterisk Support\
**Created:** [July 14, 2007, 8:30am UTC](https://community.asterisk.org/t/quality-volume-problem-urgent/15592 "2007-07-14T08:30:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nomadien2](https://avatars.discourse-cdn.com/v4/letter/n/dfb087/32.png) [@Nomadien2](https://community.asterisk.org/u/Nomadien2)\
**Post date:** [July 14, 2007, 8:30am UTC](https://community.asterisk.org/t/quality-volume-problem-urgent/15592/1 "2007-07-14T08:30:04Z")

</div>

Hi there,

I’ve installed Asterisk ( Trixbox in fact ) on a dedicated server where there’s now about 20+24 SIP trunks used for inbound and outbound calls, and 24 Users Added via FreePBX (16) and A2Billing ( 8 ).

First of all i began by installing it using the stable Asterisk 1.2.18 in trixbox repo and it was working like a charm ( just 10~15 SIP Trunks and 10 Users at that time ). After i had little problems with the dedicated server ( not enough disk space in the sys partition ) i had to make a new install and i decided to use 1.4 Asterisk rather than 1.2 one.

And so, i installed on a new dedicated server trixbox 2.0 that i upgraded to 2.2 and upgraded asterisk 1.2.18 to 1.4.4 present in the trixboxdev repo.  
All was working great but after a while outgoing calls begin to have very bad quality and low volume too. I downgraded Asterisk to 1.2.18 thinking that the 1.4.4 isn’t stable yet ( as is 1.4.5 ) but that didn’t solved the problem.

I’ve been trying lots of config changes in asterisk config files and FreePBX too but haven’t found where’s the problem.

Calls between extensions, Music On Hold and Inbound Calls are Ok ( very good quality for the caller/callee ) but Outbound calls are crappy and with low volume ( in fact the callee only have sound quality and volume problem, and not the caller )

calls with the same SIP trunk used on a softphone ( Xlite ) and an ATA (SPA3000) are good in inbound/outbound calls while once again, calls with SIP extension using that SIP Trunk on the dedicated server results in good inbound calls but bad quality and volume in outbound calls ( for the callee only ). And for Landline/GSM/VoIP destination.

here are the sip show peers example for the SIP trunks

XXXXXXXXX/XXXXXXXXX SIP\_TRUNK\_IP(providerA) N 5060 OK (91 ms)  
XXXXXXXXX/XXXXXXXXX SIP\_TRUNK\_IP(providerA) N 5060 OK (1091 ms)

XXXXXXXXX/XXXXXXXXX SIP\_TRUNK\_IP(providerB) N 5060 OK (6 ms)  
XXXXXXXXX/XXXXXXXXX SIP\_TRUNK\_IP(providerB) N 5060 OK (16 ms)

codec used is ulaw ( tried alaw too )

canreinvite=no  
qualify=yes

the only thing that i haven’t tried yet is installing a QoS on the dedicated server. But as i have shorewall firewall i already tried adding diffrent ToS rules but without any success.

Feel free to ask me some questions or to tell me do some debug/log

Could any one tell me where’s the problem ?  
And thanx in advance

---

<div class="post-metadata">

**Author:** ![ianplain](https://sea1.discourse-cdn.com/asterisk/user_avatar/community.asterisk.org/ianplain/32/1776_2.png) [@ianplain](https://community.asterisk.org/u/ianplain)\
**Post date:** [July 14, 2007, 9:01am UTC](https://community.asterisk.org/t/quality-volume-problem-urgent/15592/2 "2007-07-14T09:01:10Z")

</div>

Hi

Ok lets split the wheat from the chaff.

Basicly Incoming calls from providerA or B are OK but outgoing calls suffer from poor quality. Is that correct ?

What you need to do is a sip show channels when you have an incoming call and an outgoing call to see what codecs are in use.

Then post the results so we can see whats going on.

Ian

---

<div class="post-metadata">

**Author:** ![Nomadien2](https://avatars.discourse-cdn.com/v4/letter/n/dfb087/32.png) [@Nomadien2](https://community.asterisk.org/u/Nomadien2)\
**Post date:** [July 14, 2007, 9:05am UTC](https://community.asterisk.org/t/quality-volume-problem-urgent/15592/3 "2007-07-14T09:05:05Z")

</div>

Yep that’s it, and thx for the reply

I’ll show u that right now …

Here is the sip show channels while it’s just ringing ( Inbound Call on provider A using My A2Billing Account, using an external SIP account (from Provider A as it’s free) )

[quote]Asterisk (Ver. 1.2.18 ): Channels  
Active Channel(s)

Channel Location State Application(Data)  
SIP/MyA2B\_User\_ID-082fc (None) Ringing AppDial((Outgoing Line))  
SIP/Wrong\_Peer\_ID-b6d2cb Correct\_Peer\_ID@custom-a2b Ring Dial(SIP/MyA2B\_User\_ID|60|HL(3600

2 active channels  
1 active call

Sip Channel(s)  
Peer User/ANR Call ID Seq (Tx/Rx) Form Hold Last Message

My\_Xlite\_WAN\_IP MyA2B\_User\_ID 3a61cba9174 00102/00000 ulaw No Init: INVITE  
SIP\_IP\_PROVIDERA Wrong\_Peer\_ID(Maybe because of native bridging ?) 25c8b033398 00101/00102 alaw No Rx: INVITE

2 active SIP channels[/quote]

While the call is answered

[quote]Asterisk (Ver. 1.2.18 ): Channels  
Active Channel(s)

Channel Location State Application(Data)  
SIP/MyA2B\_UserID-082fc (None) Up Bridged Call(SIP/Wrong\_Peer\_ID-b6d  
SIP/Wrong\_Peer\_ID-b6d2cb Correct\_Peer\_ID@custom-a2b Up Dial(SIP/MyA2B\_UserID|60|HL(3600  
2 active channels  
1 active call

Sip Channel(s)

Peer User/ANR Call ID Seq (Tx/Rx) Form Hold Last Message  
My\_Xlite\_WAN\_IP MyA2B\_UserID 3a61cba9174 00102/00000 ulaw No Tx: ACK  
SIP\_IP\_PROVIDERA Wrong\_Peer\_ID 25c8b033398 00101/00102 alaw No Rx: ACK  
2 active SIP channels  
[/quote]

The inbound Call while ringing ( on the provider B, from the provider A external SIP account )

[quote]

Asterisk (Ver. 1.2.18 ): Channels  
Active Channel(s)

Channel Location State Application(Data)  
SIP/MyA2B\_UserID-082fc (None) Ringing AppDial((Outgoing Line))  
SIP/Wrong\_Peer\_ID-b6d2 Correct\_Peer\_ID@custom-a Ring Dial(SIP/MyA2B\_UserID|60|HL(3600  
2 active channels  
1 active call

Sip Channel(s)

Peer User/ANR Call ID Seq (Tx/Rx) Form Hold Last Message

My\_Xlite\_WAN\_IP MyA2B\_UserID 5ca6b5d3390 00102/00000 ulaw No Init: INVITE  
SIP\_IP\_PROVIDERB Wrong\_Peer\_ID 75c240974f6 00101/00102 alaw No Rx: INVITE  
2 active SIP channels  
[/quote]

[quote]

Asterisk (Ver. 1.2.18 ): Channels  
Active Channel(s)

Channel Location State Application(Data)  
SIP/MyA2B\_UserID-082fc (None) Up Bridged Call(SIP/Wrong\_Peer\_ID-b  
SIP/Wrong\_Peer\_ID-b6d2 Correct\_Peer\_ID@custom-a Up Dial(SIP/MyA2B\_UserID|60|HL(3600  
2 active channels  
1 active call

Sip Channel(s)

Peer User/ANR Call ID Seq (Tx/Rx) Form Hold Last Message  
My\_Xlite\_WAN\_IP MyA2B\_UserID 5ca6b5d3390 00102/00000 ulaw No Tx: ACK  
SIP\_IP\_PROVIDERB Wrong\_Peer\_ID 75c240974f6 00101/00102 alaw No Rx: ACK  
2 active SIP channels

While the call is answered  
[/quote]

Outgoing call via provider B to 0033172090404 ( a PSTN SIPBroker gateway Number )

while ringing

[quote]  
Asterisk (Ver. 1.2.18 ): Channels  
Active Channel(s)

Channel Location State Application(Data)  
SIP/Correct\_Peer\_ID-082f (None) Ringing AppDial((Outgoing Line))  
SIP/MyA2B\_UserID-b6d29 0033172090404@a2bill Ring Dial(SIP/Correct\_Peer\_ID/003317209  
2 active channels  
1 active call

Sip Channel(s)

Peer User/ANR Call ID Seq (Tx/Rx) Form Hold Last Message

SIP\_IP\_PROVIDERB 0033172090 5cb6779413a 00103/00000 alaw No Tx: INVITE  
My\_Xlite\_LAN\_IP MyA2B\_UserID MjIwMjUwODl 00101/00002 ulaw No Rx: INVITE

2 active SIP channels  
[/quote]  
while answered

[quote]  
Asterisk (Ver. 1.2.18 ): Channels  
Active Channel(s)

Channel Location State Application(Data)  
SIP/Correct\_Peer\_ID-082f (None) Up Bridged Call(SIP/MyA2B\_UserID-b6  
SIP/MyA2B\_UserID-b6d29 0033172090404@a2bill Up Dial(SIP/Correct\_Peer\_ID/003317209  
2 active channels  
1 active call

Sip Channel(s)

Peer User/ANR Call ID Seq (Tx/Rx) Form Hold Last Message

SIP\_IP\_PROVIDERB 0033172090 5cb6779413a 00103/00000 alaw No Tx: ACK  
My\_Xlite\_LAN\_IP MyA2B\_UserID MjIwMjUwODl 00101/00002 ulaw No Rx: ACK  
2 active SIP channels  
[/quote]

Outgoing call via provider A to a gsm phone number

while ringing

[quote]

Asterisk (Ver. 1.2.18 ): Channels  
Active Channel(s)

Channel Location State Application(Data)  
SIP/Correct\_Peer\_ID-082fc1 (None) Ringing AppDial((Outgoing Line))  
SIP/MyA2B\_UserID-b6d27 A\_GSM\_Number@a2bill Ring Dial(SIP/Correct\_Peer\_ID/A\_GSM\_Number  
2 active channels  
1 active call

Sip Channel(s)

Peer User/ANR Call ID Seq (Tx/Rx) Form Hold Last Message

SIP\_IP\_PROVIDERA A\_GSM\_Number 5862bdc5667 00103/00000 alaw No Tx: INVITE  
My\_Xlite\_LAN\_IP MyA2B\_UserID YzNkNmMwODZ 00101/00002 ulaw No Rx: INVITE

2 active SIP channels  
[/quote]

while answered

[quote]  
Asterisk (Ver. 1.2.18 ): Channels  
Active Channel(s)

Channel Location State Application(Data)  
SIP/Correct\_Peer\_ID-082fc1 (None) Up Bridged Call(SIP/MyA2B\_UserID-b6  
SIP/MyA2B\_UserID-b6d27 A\_GSM\_Number@a2bill Up Dial(SIP/Correct\_Peer\_ID/A\_GSM\_Number  
2 active channels  
1 active call

Sip Channel(s)

Peer User/ANR Call ID Seq (Tx/Rx) Form Hold Last Message

SIP\_IP\_PROVIDERA A\_GSM\_Number 5862bdc5667 00103/00000 alaw No Tx: ACK  
My\_Xlite\_LAN\_IP MyA2B\_UserID YzNkNmMwODZ 00101/00002 ulaw No Rx: ACK  
2 active SIP channels  
[/quote]

It’s so long 😃

U can see that codec used on the my Xlite is ulaw while codec on the dedicated server is alaw. I tried both ulaw and alaw in both server and Xlite with the same result

and thx
