Author Topic: Cannot track outbound calls  (Read 13258 times)

arturohg

  • Newbie
  • *
  • Posts: 14
  • Karma: 0
    • View Profile
Cannot track outbound calls
« on: May 21, 2009, 07:19:35 »
Hello,

i have installed QM 1.5.3.  It is working fine for tracking inbound queues. but I cannot get the outbound calls tracking to work.
It is not even recording the outbound events to the queue_log file.

I get the following asterisk console messages:

 Executing NoOp("SIP/156-b2c45110", "queuedial") in new stack
    -- Executing Dial("SIP/156-b2c45110", "Local/85451133@queuedial/n") in new stack
    -- Called 85451133@queuedial/n
    -- Executing Set("Local/85451133@queuedial-891a,2", "QDIALER_QUEUE=q-8") in new stack
    -- Executing Set("Local/85451133@queuedial-891a,2", "QDIALER_NUMBER=5451133") in new stack
    -- Executing Set("Local/85451133@queuedial-891a,2", "QDIALER_AGENT=Agent/156") in new stack
    -- Executing Set("Local/85451133@queuedial-891a,2", "QDIALER_CHANNEL=Zap/g9/5451133") in new stack
    -- Executing Set("Local/85451133@queuedial-891a,2", "QueueName=q-8") in new stack
    -- Executing MixMonitor("Local/85451133@queuedial-891a,2", "Q-q-8-1242882944.8120.WAV|b|") in new stack
    -- Executing Goto("Local/85451133@queuedial-891a,2", "qm-queuedial|s|1") in new stack
    -- Goto (qm-queuedial,s,1)
    -- Executing NoOp("Local/85451133@queuedial-891a,2", "Outbound call -> A:Agent/156 N:5451133 Q:q-8 Ch:Zap/g9/5451133") in new stack
    -- Executing Set("Local/85451133@queuedial-891a,2", "CDR(accountcode)=QDIALAGI") in new stack
    -- Executing Set("Local/85451133@queuedial-891a,2", "ST=1242882944") in new stack
    -- Executing Set("Local/85451133@queuedial-891a,2", "GM=QDV-Agent/156") in new stack
    -- Executing Set("Local/85451133@queuedial-891a,2", "GLOBAL(QDV-Agent/156)=U") in new stack
May 20 23:15:44 ERROR[17417]: pbx.c:1417 ast_func_write: Function GLOBAL not registered
    -- Executing Set("Local/85451133@queuedial-891a,2", "GLOBAL(QDV-Agent/156ans)=0") in new stack
May 20 23:15:44 ERROR[17417]: pbx.c:1417 ast_func_write: Function GLOBAL not registered
    -- Executing Macro("Local/85451133@queuedial-891a,2", "queuelog|1242882944|1242882944.8120|q-8|Agent/156|CALLOUTBOUND|-|5451133") in new stack
May 20 23:15:44 WARNING[17417]: pbx.c:1700 pbx_extension_helper: No application 'QueueLog' for extension (macro-queuelog, s, 1)
  == Spawn extension (macro-queuelog, s, 1) exited non-zero on 'Local/85451133@queuedial-891a,2' in macro 'queuelog'
  == Spawn extension (macro-queuelog, s, 1) exited non-zero on 'Local/85451133@queuedial-891a,2'
  == Everyone is busy/congested at this time (1:0/0/1)
    -- Executing Hangup("SIP/156-b2c45110", "") in new stack
  == Spawn extension (druid-user-telemarketing, 85451133, 3) exited non-zero on 'SIP/156-b2c45110'
  == Begin MixMonitor Recording Local/85451133@queuedial-891a,2
  == End MixMonitor Recording Local/85451133@queuedial-891a,2


I have the following configuration for queuedial:

exten => _XXX.,1,Set(QDIALER_QUEUE=q-${EXTEN:0:1})
exten => _XXX.,n,Set(QDIALER_NUMBER=${EXTEN:1})
exten => _XXX.,n,Set(QDIALER_AGENT=Agent/${CALLERID(num)})
exten => _XXX.,n,Set(QDIALER_CHANNEL=Zap/g9/${QDIALER_NUMBER})
exten => _XXX.,n,Set(QueueName=${QDIALER_QUEUE})
exten => _XXX.,n,MixMonitor(Q-${QDIALER_QUEUE}-${UNIQUEID}.WAV|b|)
exten => _XXX.,n,Goto(qm-queuedial,s,1)

I will appreciate any advice!

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Cannot track outbound calls
« Reply #1 on: May 22, 2009, 10:09:17 »
What is the version of Asterisk you are using? the dialplan crashes with:

Quote
May 20 23:15:44 WARNING[17417]: pbx.c:1700 pbx_extension_helper: No application 'QueueLog' for extension (macro-queuelog, s, 1)

the application QueueLog whould be there for all Asterisks 1.4+ - maybe you did not compile it in?



arturohg

  • Newbie
  • *
  • Posts: 14
  • Karma: 0
    • View Profile
Re: Cannot track outbound calls
« Reply #2 on: June 05, 2009, 01:33:49 »
Thank you for the answer.
Currently we have Asterisk Business Edition ABE-B.1-3.

The weird thing is that the messages for inbound queue log are read as they are supposed to be.  Should we still recompile? Should we check for anything else?

Best regards


QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Cannot track outbound calls
« Reply #3 on: June 05, 2009, 11:11:34 »
You should either compile in the "QueueLog' application, or you should comment the QueueLog line and uncomment the line that says:

Code: [Select]
exten => s,1,System( echo "${ARG1}|${ARG2}|${ARG3|${ARG4}|${ARG5}|${ARG6}|${ARG7}|${ARG8}" >> /var/log/asterisk/queue_log )
That's by the end of the file extensions_queuemetrics.conf


arturohg

  • Newbie
  • *
  • Posts: 14
  • Karma: 0
    • View Profile
Re: Cannot track outbound calls
« Reply #4 on: June 07, 2009, 04:03:48 »
Thank you.
We are almost there but now I am getting the following 3 error messages:

----------------------------------------------------------------------------------------------------
    -- Executing Set("Local/898703814@queuedial-f3b0,2", "GLOBAL(QDV-Agent/156)=U") in new stack
Jun  6 19:59:18 ERROR[23741]: pbx.c:1417 ast_func_write: Function GLOBAL not registered
    -- Executing Set("Local/898703814@queuedial-f3b0,2", "GLOBAL(QDV-Agent/156ans)=0") in new stack
Jun  6 19:59:18 ERROR[23741]: pbx.c:1417 ast_func_write: Function GLOBAL not registered


----------------------------------------------------------------------------------------------------
    -- Executing Macro("Local/898703814@queuedial-f3b0,2", "queuelog|1244339958|1244339958.30352|q-8|Agent/156|CALLOUTBOUND|-|98703814") in new stack
Jun  6 19:59:18 NOTICE[23741]: pbx.c:1488 pbx_substitute_variables_helper_full: Error in extension logic (missing '}')


----------------------------------------------------------------------------------------------------
    -- Executing Goto("Local/898703814@queuedial-f3b0,2", "case-0") in new stack
Jun  6 19:59:26 NOTICE[23741]: pbx.c:1753 pbx_extension_helper: No such label 'case-0' in extension 'h' in context 'qm-queuedial'
Jun  6 19:59:26 WARNING[23741]: pbx.c:6515 ast_parseable_goto: Priority 'case-0' must be a number > 0, or valid label


Thank you for the support.

arturohg

  • Newbie
  • *
  • Posts: 14
  • Karma: 0
    • View Profile
Re: Cannot track outbound calls
« Reply #5 on: June 07, 2009, 20:33:27 »
I have found a way to fix 2 of the errors.

The first one, probably because of the asterisk version, I changed the GLOBAL name for "g" as an option of the SET command.
For example
exten => s,n,Set(${GM}=U,g) instead of exten => s,n,Set(GLOBAL(${GM})=U)

The second error was a missing bracket (}) in the sentence, after ARG3:
exten => s,1,System( echo "${ARG1}|${ARG2}|${ARG3|${ARG4}|${ARG5}|${ARG6}|${ARG7}|${ARG8}" >> /var/log/asterisk/queue_log )

I am still looking for the third error.

arturohg

  • Newbie
  • *
  • Posts: 14
  • Karma: 0
    • View Profile
Re: Cannot track outbound calls
« Reply #6 on: June 08, 2009, 06:43:36 »
The third error was related to the GLOBAL command too. 

It seems that this version of asterisk is based on 1.2, not 1.4

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Cannot track outbound calls
« Reply #7 on: June 08, 2009, 11:33:14 »
IIRC, on Asterisk 1.2, if you set two underscores before a vaiable you get something functionally similar to a global variable.

http://www.voip-info.org/wiki/view/Asterisk+variables

The script was NOT written for Asterisk 1.2 though, so you may find other dead ends.
If you can get a working version, we'd like to share it.