Slow response when dialing manually

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

Slow response when dialing manually

Postby spinto » Fri Mar 02, 2007 3:32 pm

when I click the dial button it takes a long time to do the actual dialing. I have apache and mysql running on one server and asterisk running on the other. I have only one sip phone connected and logged on with a T1 connection. After some testing I found that saving to the db was taking the longest. As soon as it saved it immediately dialed. I know this becuase I uncommented the alert() command in basic_originate_call function.

Everything seems to be running slow including logging on, using the predictive dialer. I'm thinking it's a problem with apache but not sure. I did a clean install of everyting so nothing else is running. Based on performance monitor everything seems normal. I'm running CentOS 4.4 and the latest version of everything else.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby Op3r » Fri Mar 02, 2007 10:33 pm

check the time of those server if they are synchronized.
Get paid for US outbound Toll Free calls. PM me.
Op3r
 
Posts: 1432
Joined: Wed Jun 07, 2006 7:53 pm
Location: Manila

Postby mflorell » Fri Mar 02, 2007 11:01 pm

What is the loadavg when this happens?

Can you post some Asterisk CLI output?

Try any Linux distro except for CentOS or RHEL
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby spinto » Mon Mar 12, 2007 9:45 am

Here is a copy of the output when I run loadavg:

0.00 0.00 0.00 1/78 8228

I have reinstalled Vicidial and MySQL on a slackware box. I followed the instruction and am still having a problem. The page seems to take a while when saving to vicidial_manager table. I'm not sure if it's because the page manager_send is taking a long time to execute or if it's because of the insert query. As soon as manager_send sends me the response text the phone starts dialing.

Also there is no error in the CLI output. Everything seems normal.

Verbosity is at least 10
== Parsing '/etc/asterisk/manager.conf': Found
== Manager 'sendcron' logged on from 192.168.1.239
> Channel SIP/2002-09be14f8 was answered.
-- Executing AGI("SIP/2002-09be14f8", "call_log") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/call_log
-- AGI Script call_log completed, returning 0
-- Executing Dial("SIP/2002-09be14f8", "Zap/g1/17862641355|60|Ttr") in new stack
-- Requested transfer capability: 0x00 - SPEECH
-- Called g1/17862641355
-- Zap/1-1 is proceeding passing it to SIP/2002-09be14f8
-- Zap/1-1 is making progress passing it to SIP/2002-09be14f8
== Manager 'sendcron' logged off from 192.168.1.239
-- Zap/1-1 is ringing
-- Zap/1-1 answered SIP/2002-09be14f8
-- Channel 0/1, span 1 got hangup request
-- Hungup 'Zap/1-1'
== Spawn extension (outbound-level2, 917862641355, 2) exited non-zero on 'SIP/2002 -09be14f8'
-- Executing DeadAGI("SIP/2002-09be14f8", "call_log") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/call_log
-- AGI Script call_log completed, returning 0
-- Executing DeadAGI("SIP/2002-09be14f8", "VD_hangup--HVcauses--PRI-----NODEBUG- ----16-----ANSWER-----17-----3)") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/VD_hangup--HVcauses--PRI-----NO DEBUG-----16-----ANSWER-----17-----3)
-- AGI Script VD_hangup--HVcauses--PRI-----NODEBUG-----16-----ANSWER-----17----- 3) completed, returning 0


How do I go about turning on and monitoring debugging with Vicidial. Also I'm only trying to manually right now through astguiclient. I haven't even tried the predictive dialer yet.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

action_process log

Postby spinto » Mon Mar 12, 2007 12:47 pm

|
2007-03-12 10:41:27|SQL_QUERY|UPDATE vicidial_manager set status='SENT' where man_id='36'||
2007-03-12 10:47:05|SQL_QUERY|SELECT * FROM vicidial_manager where server_ip = '192.168.1.79' and status = 'QUEUE' order by entry_date desc limit 1||
2007-03-12 10:47:05|----BEGIN NEW COMMAND----
Action: Originate
Channel: SIP/2265
Context: default
Exten: 917862641355
Priority: 1
Callerid: "DOagcW11737144026666" <555555555>

----END NEW COMMAND----
|
2007-03-12 10:47:05|SQL_QUERY|UPDATE vicidial_manager set status='SENT' where man_id='37'||
2007-03-12 10:50:20|SQL_QUERY|SELECT * FROM vicidial_manager where server_ip = '192.168.1.79' and status = 'QUEUE' order by entry_date desc limit 1||
2007-03-12 10:50:20|----BEGIN NEW COMMAND----
Action: Originate
Channel: SIP/2265
Context: outbound-level2
Exten: 917862641355
Priority: 1
Callerid: "DOagcW11737145996666" <555555555>

----END NEW COMMAND----
|
2007-03-12 10:50:20|SQL_QUERY|UPDATE vicidial_manager set status='SENT' where man_id='38'||
2007-03-12 10:51:59|SQL_QUERY|SELECT * FROM vicidial_manager where server_ip = '192.168.1.79' and status = 'QUEUE' order by entry_date desc limit 1||
2007-03-12 10:51:59|----BEGIN NEW COMMAND----
Action: Originate
Channel: SIP/2265
Context: outbound-level2
Exten: 917862641355
Priority: 1
Callerid: "DOagcW11737146376666" <555555555>

----END NEW COMMAND----
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby mflorell » Mon Mar 12, 2007 11:26 pm

How many seconds from login to your phone ringing?

Are you using "skip-lookups" in MySQL?
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby spinto » Tue Mar 13, 2007 9:18 am

It seems to vary from several seconds to a minute or so. It's never instant. Looking at the log I posted it looks like it's updating then the select query appears a minute or more later.

I don't know what skip-lookups is and how to enable/disable it. I'll do research on that one and get back to you.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby spinto » Tue Mar 13, 2007 11:38 am

I wasn't able to find anything out about skip-lookups. Let me know what that is and how to check it.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby spinto » Tue Mar 13, 2007 12:46 pm

Matt you asked me how many seconds between login and the phone ringing. I'm not using vicidial. I'm doing a manual dial from astguiclient.php. I haven't tried vicidial yet.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby mflorell » Tue Mar 13, 2007 3:20 pm

in your /etc/my.cnf file, add the following line after the [mysqld] section:

skip-name-resolve



Then shutdown and restart MySQL
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby spinto » Tue Mar 13, 2007 4:25 pm

I put that line there but no luck. There's still a delay. I have the following setup:

MySQL & Dialer
Dell P4
512 MB

Asterisk
Dell P4
512 MB

I wanted to mention the above in case that has something to do with the delay I'm seeing. I only have one sip phone hooked up to it. It's a test system before we go with the real deal. I did try vicidial and was running into the same delay. When I use the originate command from a PHP page my phone rings right away and as soon as I pick it up the called party begins to ring instantly.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby mflorell » Tue Mar 13, 2007 5:12 pm

have you tried using mtop to see mysql queries as they execute and see what that problem may be?
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby enjay » Tue Mar 13, 2007 11:47 pm

I've seen this with DNS before..

add a host record for the asterisk server on the mysql system.

On the MySQL Server vi /etc/hosts

in that file put

IP.address.of.asteriskserver hostname_of_asterisk_server

save that file and then try again.


more specifically if you try to connect to the mysql server from the asterisk box via "mysql -u username -p -h ip.of.sql.system" and after you put the password in when prompted if it hangs there for any duration of time "5-10 seconds" before providing the mysql> prompt this is typically due to DNS (at least in my experience).

Give that a shot and let us know if it helps..

NOTE: I see Matt said to put in skip-name-resolve which should also resolve this though I've put that in and not had it work before while adding the host entry has.
enjay
 
Posts: 806
Joined: Mon Jun 19, 2006 12:40 pm
Location: Utah

Postby spinto » Wed Mar 14, 2007 8:51 am

There's still a delay. I logged onto mysql instantly from the asterisk server. I don't think it's a problem with the machines communicating. The delay occurs when a manual call is made through astguiclient.php. Once I'm on the call I get the "call details" at the top of the page with options such as hangup, record, xfer. Those call details come as soon as the called party picks up and goes away as soon as the call is disconnected.

Likewise when a call comes in it gets displayed right away. When clicking the hangup link in the call details it doesn't hangup. I'm thinking there's a delay there as well.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby mflorell » Wed Mar 14, 2007 9:40 am

Can you post Asterisk CLI output when this happens?
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby spinto » Wed Mar 14, 2007 10:56 am

I installed and ran mtop. The queries running are not displaying on the screen. All I see is:

load average: 0.22, 0.06, 0.01 mysqld 4.0.27-log up 1 day(s), 21:11 hrs
11 threads: 1 running, 0 cached. Queries/slow: 4.8M/0 Cache Hit: 99.98%
Opened tables: 8 RRN: 200.6K TLW: 0 SFJ: 0 SMP: 0 QPS: 15

ID USER HOST DB TIME COMMAND STATE INFO
30536 root localhost Query show full processlist
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

CLI output

Postby spinto » Wed Mar 14, 2007 11:07 am

When manual dialing (took 7 seconds for the phone to ring)

Parsing '/etc/asterisk/manager.conf': Found
== Manager 'sendcron' logged on from 192.168.1.239
> Channel SIP/2265-09be1910 was answered.
-- Executing AGI("SIP/2265-09be1910", "call_log") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/call_log
-- AGI Script call_log completed, returning 0
-- Executing Dial("SIP/2265-09be1910", "Zap/g1/17862641355|60|Ttr") in new stack
-- Requested transfer capability: 0x00 - SPEECH
-- Called g1/17862641355
-- Zap/1-1 is proceeding passing it to SIP/2265-09be1910
-- Zap/1-1 is making progress passing it to SIP/2265-09be1910
== Manager 'sendcron' logged off from 192.168.1.239
-- Zap/1-1 is ringing
-- Zap/1-1 answered SIP/2265-09be1910
-- Hungup 'Zap/1-1'
== Spawn extension (outbound-level2, 917862641355, 2) exited non-zero on 'SIP/2265-09be1910'
-- Executing DeadAGI("SIP/2265-09be1910", "call_log") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/call_log
-- AGI Script call_log completed, returning 0
-- Executing DeadAGI("SIP/2265-09be1910", "VD_hangup--HVcauses--PRI-----NODEBUG-----16-----ANSWER-----15-----8)") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/VD_hangup--HVcauses--PRI-----NODEBUG-----16-----ANSWER-----15-----8)
-- AGI Script VD_hangup--HVcauses--PRI-----NODEBUG-----16-----ANSWER-----15-----8) completed, returning 0

when I receive an incoming call

-- Accepting call from '3054389696' to '8668056503' on channel 0/1, span 1
-- Executing Answer("Zap/1-1", "") in new stack
-- Executing Dial("Zap/1-1", "SIP/2265||Tto") in new stack
-- Called 2265
-- SIP/2265-09be1910 is ringing
-- SIP/2265-09be1910 answered Zap/1-1
== Parsing '/etc/asterisk/manager.conf': Found
== Manager 'sendcron' logged on from 192.168.1.239
== Parsing '/etc/asterisk/manager.conf': Found
== Manager 'sendcron' logged on from 192.168.1.239
== Manager 'sendcron' logged off from 192.168.1.239
== Manager 'sendcron' logged off from 192.168.1.239
-- Channel 0/1, span 1 got hangup request
== Spawn extension (incoming, 8668056503, 2) exited non-zero on 'Zap/1-1'
-- Hungup 'Zap/1-1'
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby mflorell » Wed Mar 14, 2007 11:47 am

What kind of card do you have that Zap 1 goes through?
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby spinto » Wed Mar 14, 2007 11:56 am

Currently we're using Digium Wildcard TE207P Dual T1 / E1 PCI Card Octasic DSP Echo Cancellation.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby mflorell » Wed Mar 14, 2007 12:16 pm

What kind of T1/E1 circuit are you using with this card? (zapata.conf/zaptel.conf settings)
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby spinto » Wed Mar 14, 2007 12:51 pm

Zaptel.conf

span=1,1,0,esf,b8zs
loadzone=us
defaultzone=us
bchan=1-23
dchan=24

span=2,1,0,esf,b8zs
loadzone=us
defaultzone=us
bchan=25-47
dchan=48

Zapata.conf
[trunkgroups]
[channels]
signalling=pri_cpe
switchtype=dms100
usecallerid=yes
hidecallerid=no
callerid="Some Company" <800-877-7777>
context=blah
language=en
rxgain=0.0
txgain=0.0

group=1
context=incoming
channel => 1-23

group=2
context=incoming
channel => 25-47
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby mflorell » Wed Mar 14, 2007 10:54 pm

What version of astguiclient are you using? The Asterisk CLI output doesn't look right.
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby gerski » Wed Mar 14, 2007 11:34 pm

Code: Select all
span=1,1,0,esf,b8zs
loadzone=us
defaultzone=us
bchan=1-23
dchan=24


are you using T1 or E1? T1 doesn't used dchannel..
if you use E1 use this config instead:
Code: Select all
span=1,1,0,esf,b8zs
loadzone=us
defaultzone=us
bchan=1-15,17-31
dchan=16

if you use T1:
Code: Select all
span=1,1,0,esf,b8zs
loadzone=us
defaultzone=us
bchan=1-24
gerski
 
Posts: 432
Joined: Fri Jul 14, 2006 6:21 am

Postby mflorell » Wed Mar 14, 2007 11:42 pm

PRI T1s do use a D-channel, RBS T1s do not.
mflorell
Site Admin
 
Posts: 18387
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida

Postby gerski » Wed Mar 14, 2007 11:44 pm

ok sorry.. my mistake :o
gerski
 
Posts: 432
Joined: Fri Jul 14, 2006 6:21 am

Postby spinto » Thu Mar 15, 2007 7:35 am

I'm not sure of the version. I just downloaded it about 2 weeks ago so I'm assuming it's the current version. Also it is a T1 PRI.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby spinto » Thu Mar 15, 2007 7:42 am

I found the version. Its:

Version: 2.0.1
Build: 60829-1528
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm

Postby spinto » Mon Mar 26, 2007 3:55 pm

I went away for a week, came back and moved the servers to a different location in the same building. For some reason it seems to be working okay. I'm having an issue with it hanging up after the person answers with autodialing but I'll post that elsewhere.

Thanks.
spinto
 
Posts: 96
Joined: Mon Jan 29, 2007 3:06 pm


Return to Support

Who is online

Users browsing this forum: No registered users and 77 guests