Re: [asterisk-users] static realtime vs config files

2015-03-02 Thread Carlos Chavez

On 3/2/15 3:23 PM, Marek Cervenka wrote:

hi,

is it possible use asterisk static realtime and config files 
simultaneously in asterisk 11?


i want [globals] from extensions.conf in database, but dialplan in 
extensions.conf config file


i saw  this can be configured in stasis.conf in asterisk 13

thanks
No, you can only use Realtime (the real realtime)* along with the config 
files.  The static version will not load the config files.


*The person at Digium that came up with Realtime and Static Realtime 
should be given a timeout in the corner to think how stupid it was to 
name the DB system like that and confuse the hell out of everyone!



-- Telecomunicaciones Abiertas de México S.A. de C.V. Carlos Chávez 
+52 (55)9116-91161
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] static realtime vs config files

2015-03-02 Thread Marek Cervenka

hi,

is it possible use asterisk static realtime and config files 
simultaneously in asterisk 11?


i want [globals] from extensions.conf in database, but dialplan in 
extensions.conf config file


i saw  this can be configured in stasis.conf in asterisk 13

thanks

--
---
Marek Cervenka
===

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] Queue_log transfer

2015-03-02 Thread Carlos Chavez
I am having a problem with my queue_log.  When an agent transfers a 
call I am not getting the extension that was dialed for transfer, I am 
only getting the name of the macro we use:


1425307308|1425307242.33367|PedidosKosmos|Agente 
102|TRANSFER|s|macro-stdexten|13|52|1
1425309366|1425309316.33729|PedidosKosmos|Agente 
102|TRANSFER|s|macro-stdexten|7|42|1
1425312756|1425312589.34760|RecSelKosmos|Agente 
1|TRANSFER|s|macro-stdexten|38|113|1
1425313810|1425313658.35112|RecSelKosmos|Agente 
4|TRANSFER|s|macro-stdexten|39|96|1


This is the macro that is used for all internal extensions.  If I 
make an extension that only has a Dial command then I do get the correct 
number and context:


1424965940|1424965917.13835|PedidosKosmos|Agente 
103|TRANSFER|2528|oficina|8|14|1


How can this be corrected?  Why would it matter to the Queue system 
if the call is transferred to a macro in the dial plan?


--
Telecomunicaciones Abiertas de México S.A. de C.V.
Carlos Chávez
+52 (55)9116-91161


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] account code

2015-03-02 Thread ricky gutierrez
Hi list , I have a question with account codes, all my outgoing calls
are authenticated, but now the boss wants to monitor these calls with
the codes.

example: maria has an extension 110, but peter was in place and use
the phone maria , maria then says that she did not make that call to
that number of cell.

like to know who made it?, I think the pin code is my friendo , my
users have a four-digit pin to authenticate, I'm thinking of using the
cdr field userfield

as I can do to read the pin code and write it there?


[call-out-analog]

exten = _9.,1,Authenticate(/var/lib/asterisk/key.txt,am,4)

exten = 9.,n,Set(CDR(userfield)=pin-users)})

exten = _9.,n,Set(__SIP_CODEC=alaw)

exten = _92XXX,n,Dial(SIP/${EXTEN:1}@gw,40,rRT)

same = n,Busy(3)

same = n,Hangup

any idea?

regardss


-- 
rickygm

http://gnuforever.homelinux.com

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] situation with ivr and four-channel gateway

2015-03-02 Thread ricky gutierrez
2015-03-02 3:44 GMT-06:00 A J Stiles asterisk_l...@earthshod.co.uk:

 Ah.  *Incoming* calls are not something that is within your control; they have
 already been routed onto a line by your telco.  So you will need to speak to
 someone at your telco about doing this.


Hi Aj, I call to telco  and say they can not in GSM, only on lines are analogous

 As a temporary measure, you could try setting up divert-on-busy so SIM1
 diverts to SIM2, SIM2 diverts to SIM3, SIM3 diverts to SIM4 and SIM4 diverts
 to SIM1.  You can do this with specially-crafted Dial() statements,

With asterisk or the openvox gw?

 or by
 temporarily inserting the SIMs in an old mobile phone.  See your telco's
 website for details of setting up call diversion.

these guys do not help much! .

the ivr worked perfect with DEVICE_STATE , thank john!

exten = t,1,ExecIf($[ ${DEVICE_STATE(SIP/${EXTEN})} = INUSE ]?Busy)

exten = t,n,Dial(SIP/110,38,t)

same= n,Dial(SIP/162,40,t)

same= n,Hangup()


thnk for all help.





-- 
rickygm

http://gnuforever.homelinux.com

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] situation with ivr and four-channel gateway

2015-03-02 Thread A J Stiles
On Friday 27 Feb 2015, ricky gutierrez wrote:
 the problem is that my pbx all incoming calls using only the channel
 gsm 1 , the idea is that an incoming call to channel 1 is passed to
 channel 2

Ah.  *Incoming* calls are not something that is within your control; they have 
already been routed onto a line by your telco.  So you will need to speak to 
someone at your telco about doing this.

As a temporary measure, you could try setting up divert-on-busy so SIM1 
diverts to SIM2, SIM2 diverts to SIM3, SIM3 diverts to SIM4 and SIM4 diverts 
to SIM1.  You can do this with specially-crafted Dial() statements, or by 
temporarily inserting the SIMs in an old mobile phone.  See your telco's 
website for details of setting up call diversion.


-- 
AJS

Note:  Originating address only accepts e-mail from list!  If replying off-
list, change address to asterisk1list at earthshod dot co dot uk .

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Events

2015-03-02 Thread Jordan Cook - Gyron Networks
Hello,

I am playing around with events in asterisk via asterisk manager - i've noticed 
it doesnt seem to be emitting events to my connected client. Is there something 
that I need to do to receive events?

Also output from 'manager show events'

voip*CLI manager show events
Events:
      
  OriginateResponse ParkedCallGiveUp  ParkedCallTimeOut

Looking at other posts around should there be move events shown here?


This message may be private and confidential. If you have received this message 
in error, please notify us and remove it from your system.

Gyron may monitor email traffic data and the content of email for the purposes 
of security and staff training.

Gyron Internet Ltd is a limited company registered in England and Wales. 
Registered number: 4239332. Registered office: 3 Centro, Boundary Way, Hemel 
Hempstead, HP2 7SU. VAT reg no 804 2532 63. Gyron is a registered trademark.

Gyron is a Deloitte Technology Fast 50 ranked company.

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] System() command refuses to execute bash script

2015-03-02 Thread Stefan Viljoen
Hi all

I got this solved.

Turns out the script WAS executing, but I forgot that apparently you need to
follow cron rules in any BASH scripts executed via System() from an
Asterisk dialplan.

E. g. all paths must be fully and absolutely specified, there are no
relative path references available.

So I changed the the file wireless.sh which was:

#!/bin/bash
touch wireless-executed

to

#!/bin/bash
touch /root/wireless-executed

and now if I phone 800 on my Asterisk context I can see that the file 

wireless-executed

is created by the touch binary, which indicates that Asterisk has run the
script successfully.

So the problem was not Asterisk or BASH or permissions, but rather that it
appears that all paths in any System() script must be absolutely, not
relatively, specified.

Hope this helps somebody - simply follow cron rules when writing
Asterisk-callable BASH scripts which you plan to trigger via the System()
Asterisk dialplan application.

Regards

Stefan


-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] System() command refuses to execute bash script

2015-03-02 Thread Stefan Viljoen
Hi All

I'm using this extension to  try and get Asterisk 1.8.11.0 to run a bash
script:

exten=802,n,System(/bin/sh -f /root/wireless.sh)

This file is

-rwxr-xr-x  1 root root   171 Mar  2 16:23 wireless.sh

e.g. root owns the file, and it has execute permissions for all users.

Asterisk runs as root as well.

Asterisk executes the command without any errors at max verbosity.

The file wireless.sh contains:

#!/bin/bash
touch wireless-executed

In my /root folder however, the file

wireless-executed

is never written - indicating the script does not execute, even though it is
owner by the same user asterisk runs as, and is world-executable.

How can I use System to run a bash script?

Thanks!

Regards

Stefan


-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] System() command refuses to execute bash script

2015-03-02 Thread Tech Support
I'm surprised that you didn't have to specify the full path to the 'touch'
command. When writing AGI scripts, I always do something like 
$touch = which( 'touch' ). I guess it's over kill.
John

-Original Message-
From: asterisk-users-boun...@lists.digium.com
[mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of Stefan Viljoen
Sent: Monday, March 02, 2015 9:45 AM
To: asterisk-users@lists.digium.com
Subject: Re: [asterisk-users] System() command refuses to execute bash
script

Hi all

I got this solved.

Turns out the script WAS executing, but I forgot that apparently you need to
follow cron rules in any BASH scripts executed via System() from an
Asterisk dialplan.

E. g. all paths must be fully and absolutely specified, there are no
relative path references available.

So I changed the the file wireless.sh which was:

#!/bin/bash
touch wireless-executed

to

#!/bin/bash
touch /root/wireless-executed

and now if I phone 800 on my Asterisk context I can see that the file 

wireless-executed

is created by the touch binary, which indicates that Asterisk has run the
script successfully.

So the problem was not Asterisk or BASH or permissions, but rather that it
appears that all paths in any System() script must be absolutely, not
relatively, specified.

Hope this helps somebody - simply follow cron rules when writing
Asterisk-callable BASH scripts which you plan to trigger via the System()
Asterisk dialplan application.

Regards

Stefan


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to
Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] System() command refuses to execute bash script

2015-03-02 Thread Kevin Larsen
asterisk-users-boun...@lists.digium.com wrote on 03/02/2015 08:27:07 AM:

 From: Stefan Viljoen viljo...@verishare.co.za
 To: asterisk-users@lists.digium.com, 
 Date: 03/02/2015 08:27 AM
 Subject: [asterisk-users] System() command refuses to execute bash 
script

 How can I use System to run a bash script?

Just to rule out some weird permissions issue, try to write the file to 
some directory that has full read/write permissions to everyone (eg 777). 
If the file can be written to that directory you probably have a 
permissions issue still. I run my asterisk under the asterisk user and 
have it kick of scripts that write to a folder on the system all the time. 
The folder has full permissions for the Asterisk user.

Give it a shot and see what you get.-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] Problems with the voice quality under load

2015-03-02 Thread Mordechay Kaganer
B.H.

Hello, all :-)

We have a cluster of Asterisk (v. 11.9) servers that host IVR applications.
The servers work behind SIP proxy (kamailio) for load balancing.

All servers are in 2 processor configuration, 8-10 cores per CPU.

When a particular server gets about 500 concurrent calls, the sound quality
begins to degrade, the sound plays slowly and with clicks. As far as i
understand, it's because asterisk is unable to send the voice stream in
time i.e. the server is overloaded.

What i don't understand is, at the time that the server appears to be
overloaded and the audio quality is bad, actual server's load is no more
than 30-40% (60-70% idle CPU on average). IMHO, this indicates that for
some reason the server is unable to use it's CPU capacity efficiently. May
be because of some kind of thread contention inside asterisk?

I have read blogs that advice to divide physical server into several VMs
and they claim that this will improve the total capacity. In my own
experience, this did not work very well and seems like the visualization
actually made the quality worse.

Do you have any advice for me (other than purchasing more servers ;-) ?

Thanks!

-- 
משיח NOW!
Moshiach is coming very soon, prepare yourself!
יחי אדוננו מורינו ורבינו מלך המשיח לעולם ועד!
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Problems with the voice quality under load

2015-03-02 Thread Steve Edwards

On Mon, 2 Mar 2015, Mordechay Kaganer wrote:

When a particular server gets about 500 concurrent calls, the sound 
quality begins to degrade, the sound plays slowly and with clicks. As 
far as i understand, it's because asterisk is unable to send the voice 
stream in time i.e. the server is overloaded.


What i don't understand is, at the time that the server appears to be 
overloaded and the audio quality is bad, actual server's load is no more 
than 30-40% (60-70% idle CPU on average). IMHO, this indicates that for 
some reason the server is unable to use it's CPU capacity efficiently. 
May be because of some kind of thread contention inside asterisk?


You may be using a feature (i.e., meetme) that is single threaded. If you 
view the system using 'htop' instead of 'top' (or, press '1' while running 
top) you may see that a single CPU is maxed out while the others are 
relatively idle.


--
Thanks in advance,
-
Steve Edwards   sedwa...@sedwards.com  Voice: +1-760-468-3867 PST
Newline  Fax: +1-760-731-3000

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] System() command refuses to execute bash script

2015-03-02 Thread Tzafrir Cohen
Hi,

Some notes,

Don't run Asterisk as root.

But also:

On Mon, Mar 02, 2015 at 04:44:48PM +0200, Stefan Viljoen wrote:
 Hi all
 
 I got this solved.
 
 Turns out the script WAS executing, but I forgot that apparently you need to
 follow cron rules in any BASH scripts executed via System() from an
 Asterisk dialplan.
 
 E. g. all paths must be fully and absolutely specified, there are no
 relative path references available.
 
 So I changed the the file wireless.sh which was:
 
 #!/bin/bash
 touch wireless-executed
 
 to
 
 #!/bin/bash
 touch /root/wireless-executed

A variant on:

  cd `dirname $0`

can help in such cases.

-- 
   Tzafrir Cohen
icq#16849755  jabber:tzafrir.co...@xorcom.com
+972-50-7952406   mailto:tzafrir.co...@xorcom.com
http://www.xorcom.com

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Problems with the voice quality under load

2015-03-02 Thread Ron Wheeler

Have you done the math for the network connections? BTF and external
What bit rates for the sound?
What codecs?
How are calls coming in - SIP - analogue

Disks OK(low IO per second)? Caching working OK?

CPU may not be the problem if your CPU utilization is really that low.

Ron

On 02/03/2015 10:26 AM, Mordechay Kaganer wrote:

B.H.

Hello, all :-)

We have a cluster of Asterisk (v. 11.9) servers that host IVR 
applications. The servers work behind SIP proxy (kamailio) for load 
balancing.


All servers are in 2 processor configuration, 8-10 cores per CPU.

When a particular server gets about 500 concurrent calls, the sound 
quality begins to degrade, the sound plays slowly and with clicks. As 
far as i understand, it's because asterisk is unable to send the voice 
stream in time i.e. the server is overloaded.


What i don't understand is, at the time that the server appears to be 
overloaded and the audio quality is bad, actual server's load is no 
more than 30-40% (60-70% idle CPU on average). IMHO, this indicates 
that for some reason the server is unable to use it's CPU capacity 
efficiently. May be because of some kind of thread contention inside 
asterisk?


I have read blogs that advice to divide physical server into several 
VMs and they claim that this will improve the total capacity. In my 
own experience, this did not work very well and seems like the 
visualization actually made the quality worse.


Do you have any advice for me (other than purchasing more servers ;-) ?

Thanks!

--
משיח NOW!
Moshiach is coming very soon, prepare yourself!
יחי אדוננו מורינו ורבינו מלך המשיח לעולם ועד!





--
Ron Wheeler
President
Artifact Software Inc
email: rwhee...@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] System() command refuses to execute bash script

2015-03-02 Thread Tzafrir Cohen
On Mon, Mar 02, 2015 at 11:15:26AM -0500, Tech Support wrote:
 I'm surprised that you didn't have to specify the full path to the 'touch'
 command. When writing AGI scripts, I always do something like 
 $touch = which( 'touch' ). I guess it's over kill.
 John

You should generally not need a path to commands in /bin / /usr/bin .

If 'which touch' returned it, it's in the path.

-- 
   Tzafrir Cohen
icq#16849755  jabber:tzafrir.co...@xorcom.com
+972-50-7952406   mailto:tzafrir.co...@xorcom.com
http://www.xorcom.com

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] System() command refuses to execute bash script

2015-03-02 Thread Steve Edwards

On Mon, 2 Mar 2015, Tzafrir Cohen wrote:


A variant on:

 cd `dirname $0`

can help in such cases.


This would yield 'the directory the script lives in' which may be 
read-only and is probably not where you want random files created.


--
Thanks in advance,
-
Steve Edwards   sedwa...@sedwards.com  Voice: +1-760-468-3867 PST
Newline  Fax: +1-760-731-3000

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] System() command refuses to execute bash script

2015-03-02 Thread Steve Edwards

Please don' top post.

On Mon, 2 Mar 2015, Tech Support wrote:


I'm surprised that you didn't have to specify the full path to the 'touch'
command. When writing AGI scripts, I always do something like
$touch = which( 'touch' ). I guess it's over kill.


The AGI process inherits the environment of the parent, Asterisk.

You can set the Asterisk environment in the script that starts Asterisk.

For example:

cd /tmp/
ulimit -n 8192
nice --adjustment=-20\
env --ignore-environment\
HOSTNAME=${HOSTNAME}\
PATH=${PATH}\
$ASTERISK $START_OPTIONS

--
Thanks in advance,
-
Steve Edwards   sedwa...@sedwards.com  Voice: +1-760-468-3867 PST
Newline  Fax: +1-760-731-3000

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] System() command refuses to execute bash script

2015-03-02 Thread Steve Edwards

On Mon, 2 Mar 2015, Stefan Viljoen wrote:

So the problem was not Asterisk or BASH or permissions, but rather that 
it appears that all paths in any System() script must be absolutely, not 
relatively, specified.


Not quite.

The 'base' for relative paths would be the 'cwd' (current working 
directory) of the Asterisk process.


You can show the cwd for your running Asterisk by:

sudo ls -l /proc/$(pidof asterisk)/cwd

which is a link to the process's cwd.

I suspect if you search your file system ('sudo find / -name 
wireless-executed'), you will find 'wireless-executed' -- probably in the 
directory shown by the above command.


You can set this in the script that starts Asterisk. I set mine to /tmp/ 
('cd /tmp/') so I know where any random file access will occur, relatively 
speaking.


--
Thanks in advance,
-
Steve Edwards   sedwa...@sedwards.com  Voice: +1-760-468-3867 PST
Newline  Fax: +1-760-731-3000

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Problems with the voice quality under load

2015-03-02 Thread A J Stiles
On Monday 02 Mar 2015, Mordechay Kaganer wrote:
 When a particular server gets about 500 concurrent calls, the sound quality
 begins to degrade, the sound plays slowly and with clicks. As far as i
 understand, it's because asterisk is unable to send the voice stream in
 time i.e. the server is overloaded.
 
 What i don't understand is, at the time that the server appears to be
 overloaded and the audio quality is bad, actual server's load is no more
 than 30-40% (60-70% idle CPU on average). IMHO, this indicates that for
 some reason the server is unable to use it's CPU capacity efficiently. May
 be because of some kind of thread contention inside asterisk?
 
 Do you have any advice for me (other than purchasing more servers ;-) ?

Perhaps it's not CPU that is blocking things, but I/O?  It should be visually 
and audibly obvious if this is the case -- the disk activity lights will be 
illuminated, and the HDDs will be making noises.

If you can spare the RAM, consider setting up a tmpfs to hold your IVR prompts 
in memory.

-- 
AJS

Note:  Originating address only accepts e-mail from list!  If replying off-
list, change address to asterisk1list at earthshod dot co dot uk .

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Problems with the voice quality under load

2015-03-02 Thread Mordechay Kaganer
B.H.

Hi, really thanks for all the relies :-)

Here's my answers:

On Mon, Mar 2, 2015 at 5:56 PM, Ron Wheeler rwhee...@artifact-software.com
 wrote:

 Have you done the math for the network connections? BTF and external
 What bit rates for the sound?
 What codecs?
 How are calls coming in - SIP - analogue

 Disks OK(low IO per second)? Caching working OK?


There's no problem with network speed - we have 3 port bonding of 1G
connections on each server and 1G external cross connect to the SIP
providers (which are located in the same server farm). Even single 1G link
is sufficient for more than 5000 calls with G711.

All disk IO is off-loaded to the central server with NFS and as far as i
can see, the load is low. In most cases, the people listen to the same
files and caching is OK - each server has 32GB of RAM most of it is used
for caching.

We are connected to several SIP trunk providers. All the setup is SIP only.
The codec is G711.

On Mon, Mar 2, 2015 at 6:02 PM, A J Stiles asterisk_l...@earthshod.co.uk
 wrote:


 Perhaps it's not CPU that is blocking things, but I/O?  It should be
 visually
 and audibly obvious if this is the case -- the disk activity lights will be
 illuminated, and the HDDs will be making noises.

 If you can spare the RAM, consider setting up a tmpfs to hold your IVR
 prompts
 in memory.


The prompts are anyway cached in in memory by the disk cache so i don't
think it's the issue in this case. As stated above, i don't see much of
disk load on the NFS server as well.

On Mon, Mar 2, 2015 at 6:14 PM, Steve Edwards asterisk@sedwards.com
wrote:

 You may be using a feature (i.e., meetme) that is single threaded. If you
 view the system using 'htop' instead of 'top' (or, press '1' while running
 top) you may see that a single CPU is maxed out while the others are
 relatively idle.


I did check the CPU load and it is distributed evenly between all the
cores. Most of the load is in system, probably network handling in the
kernel.

We do use ConfBridge a lot, but all conferences are on a single server and
the issue is on all the servers.

What other features are single-threaded?

Asterisk is almost the only thing that runs on the PBX servers. There are
also some PHP AGI scripts (5-10 per minute per server on average) and most
of the AGI functions are off-loaded to a java application on the central
server with fast AGI. But there is still a lot of dialplan logic that runs
on the PBX's. Maybe, huge dialplan is the key for the issue?

-- 
משיח NOW!
Moshiach is coming very soon, prepare yourself!
יחי אדוננו מורינו ורבינו מלך המשיח לעולם ועד!
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users