A
A
Andrey Korekhov2021-03-02 10:51:50
Asterisk
Andrey Korekhov, 2021-03-02 10:51:50

How to get rid of stuttering Asterisk?

Good afternoon.
Conducted ip telephony for the enterprise. We raised our server and distribute internal subscribers through it.
server - Ubuntu 20.04.2 LTS
Asterisk version - Asterisk 16.2.1 - pure asterisk

There are two problems with communication:
1 Echo to city numbers, but the provider stubbornly says that this is normal and depends on the equipment through which the channel is created.
2 - BASIC - stuttering on the channel. Not always, but very often the subscriber starts to stutter, it can happen both right from the first second and after a few minutes.
The problem is two-sided. both we and the subscriber stutter.

I checked for packet loss with the provider via mtr -
100 packets were lost in half an hour, the average ping is 20ms, the maximum 120ms

is the connection diagram:603de9595db39270969310.png
configs :
sip conf :

[general]
deny=0.0.0.0/0.0.0.0
permit=192.168.0.44/255.255.255.0
permit=****/255.255.255.0
allowsubscribe=yes
callcounter=yes
subscribecontext=BLF

[authentication]

[20111]
type=friend
host=dynamic
secret=*****
nat=force_rport,comedia
canreinvite=no
context=internal
qualify=yes
call-limit=2
disallow=all
allow=alaw
deny=0.0.0.0/0.0.0.0
permit=192.168.0.0/255.255.255.0
allowsubscribe=yes
callcounter=yes
subscribecontext=BLF


extensions.conf
[general]
static=yes
writeprotect=no
[globals]
DBHost = localhost
DBuser = ********
DBpass = ********
DBname = asterisk
DBowners = owners

[default]

;Вешаем трубку
[handup-sip]
exten => _X!,1,HangUp()

; Busy Lamp Functionality
[BLF]
exten => _1XX,hint,SIP/20${EXTEN}

[internal]
;исходящие звонки с внутренних аппаратов попадают сюда

exten => _[123]XX,1,Set(fname=${STRFTIME(${EPOCH},,%Y-%m-%d-%H%M)}-${CALLERID(number)}-${EXTEN})
same => n,Set(AUDIOHOOK_INHERIT(MixMonitor)=yes)
same => n,Monitor(wav,/home/asterisk/records/inner/${fname},mb)
same => n,Dial(SIP/20${EXTEN},30)

[rset] ;входящие звонки с транка попадают сюда

exten => _201[123]X,1,Set(fname=${STRFTIME(${EPOCH},,%Y-%m-%d-%H%M)}-${CALLERID(number)}-${EXTEN})
same => n,Monitor(wav,/home/asterisk/records/in/${fname},mb)
same => n,Set(AUDIOHOOK_INHERIT(MixMonitor)=yes)
same => n,Playback(/home/asterisk/records/service/allRecord)
same => n,Dial(SIP/${EXTEN},30,rTt)

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
d-stream, 2021-03-02
@Haotik

Actually, a fairly predictable problem with the delivery of packets through public channels with non-guaranteed delivery / delay.
A typical situation: a crowd of people with web browsing, asterisks, etc. The user chats on the phone and opens a page with a bunch of photos -> the browser starts dragging pictures into a bunch of streams. The provider's channel is not rubber and at some point overflows - packets queue up and wait ... For uploading pictures, this will slow down the display of the cat's photo a little at most, for voice - stuttering will occur.
There are methods to partially eliminate this problem:
- you can reserve part of the bandwidth for voice
- you can at least prioritize traffic up to and including your gateway
- use a separate channel / gateway / network for telephony
It is much more problematic to eliminate similar congestion on the provider's side. Well, guaranteed streams (the same E1) are expensive now ...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question