Author Topic: Outbound Calls Do Not Show Agent As Busy  (Read 8049 times)

adz

  • Newbie
  • *
  • Posts: 28
  • Karma: 0
    • View Profile
Outbound Calls Do Not Show Agent As Busy
« on: September 16, 2010, 17:22:29 »
Hello,

I have the latest version of QM, and asterisk version 1.4.25.1

When an agent makes an outbound call, the call shows up under "Calls being processed:" fine.

The issue I have is that their state does not change from available to busy (Orange), in the "Agents currently logged in:" section.

Any suggestions on ways to get this to work would be most appreciated!

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Outbound Calls Do Not Show Agent As Busy
« Reply #1 on: September 17, 2010, 09:13:44 »
Are you sure the agent name as it appears is exactly the same? not that one is seen as AgenT/101 and teh other as SIP/101?

adz

  • Newbie
  • *
  • Posts: 28
  • Karma: 0
    • View Profile
Re: Outbound Calls Do Not Show Agent As Busy
« Reply #2 on: September 17, 2010, 19:17:17 »
Here is a screenshot of our current realtime view.



As you can see, Barry (Agent 1022) is on an outbound call for 13.07 minutes.

His Agent is set as available though.

Does this help?

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Outbound Calls Do Not Show Agent As Busy
« Reply #3 on: September 21, 2010, 10:11:34 »
Yes - that is not correct - you see that the calls "waiting" for 13 minutes and there is nobody under "Agent".
Try and post what happens on the queue_log.


adz

  • Newbie
  • *
  • Posts: 28
  • Karma: 0
    • View Profile
Re: Outbound Calls Do Not Show Agent As Busy
« Reply #4 on: October 14, 2010, 18:25:35 »
My outbound code is as follows - do you see anything immediately thats wrong?

exten => _XXXXXXXXXXXXX,n,Set(MY_AGENT=${AGENTE_${CHANNEL:4:3}})
exten => _XXXXXXXXXXXXX,n,Set(QDIALER_QUEUE=${MY_AGENT})
exten => _XXXXXXXXXXXXX,n,Set(QDIALER_NUMBER=${EXTEN:3})
exten => _XXXXXXXXXXXXX,n,Set(QDIALER_AGENT=${CHANNEL:0:7})
exten => _XXXXXXXXXXXXX,n,Set(QDIALER_CHANNEL=${CHANNEL})
exten => _XXXXXXXXXXXXX,n,Set(QueueName=${QDIALER_QUEUE})
exten => _XXXNXXNXXXXXX,n,NoOp,Outbound call -> A:${MY_AGENT} N:${QDIALER_NUMBER} Q:${QDIALER_QUEUE} Ch:${QDIALER_CHANNEL}
exten => _XXXNXXNXXXXXX,n,Set(CDR(accountcode)=QDIALAGI)
exten => _XXXNXXNXXXXXX,n,Set(ST=${EPOCH})
exten => _XXXNXXNXXXXXX,n,Set(GM=QDV-${QDIALER_AGENT})
exten => _XXXNXXNXXXXXX,n,Set(GLOBAL(${GM})=U)
exten => _XXXNXXNXXXXXX,n,Set(GLOBAL(${GM}ans)=0)
exten => _XXXNXXNXXXXXX,n,Macro(queuelog,${ST},${UNIQUEID},${QDIALER_QUEUE},${QDIALER_AGENT},ENTERQUEUE,-,${QDIALER_NUMBER})
exten => _XXXNXXNXXXXXX,n,Set(MONFILENAME=/var/spool/asterisk/monitor/${STRFTIME(${EPOCH},GMT-5,%G%m%d)}/${STRFTIME(${EPOCH},GMT-5,%H%M%S)}-${CALLERID(num)}-${EXTEN:3})
exten => _XXXNXXNXXXXXX,n,Monitor(wav|${MONFILENAME}|m)
exten => _XXXNXXNXXXXXX,n,Dial(SIP/1${EXTEN:3}@<IP>:5060|300)
exten => _XXXNXXNXXXXXX,n,Set(CAUSECOMPLETE=${IF($["${DIALSTATUS}" = "ANSWER"]?C)})
exten => _XXXNXXNXXXXXX,n,Hangup()

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Outbound Calls Do Not Show Agent As Busy
« Reply #5 on: October 15, 2010, 09:20:15 »
You hit the queue_log only to mark an ENTERQUEUE  but  nothing else?
Try and post what gets added on the queue_log when you make an outbound call.

adz

  • Newbie
  • *
  • Posts: 28
  • Karma: 0
    • View Profile
Re: Outbound Calls Do Not Show Agent As Busy
« Reply #6 on: July 14, 2011, 19:48:37 »
Here is the output from the pbx when we make an outbound call:

 -- Executing [300xxxxxxxxxx@extension-outbound:1] Set("SIP/306.extension-b7a61778", "CALLERID(all)="Tech Support" <xxxxxxxxxx>") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:2] Set("SIP/306.extension-b7a61778", "OUTCODE=pch300") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:3] AGI("SIP/306.extension-b7a61778", "outCheckTimeRemaining.agi|pch300") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/outCheckTimeRemaining.agi
  outCheckTimeRemaining.agi|pch300: I have checked for billable minutes in the DB: pch300 Billable: 0 Mins: 
[Jul 14 13:41:08] ERROR[28572]: utils.c:966 ast_carefulwrite: write() returned error: Broken pipe
    -- AGI Script outCheckTimeRemaining.agi completed, returning 0
    -- Executing [300xxxxxxxxxx@extension-outbound:4] GotoIf("SIP/306.extension-b7a61778", "0?:6") in new stack
    -- Goto (extension-outbound,300xxxxxxxxxx,6)
    -- Executing [300xxxxxxxxxx@extension-outbound:6] Set("SIP/306.extension-b7a61778", "MY_AGENT=1010") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:7] Set("SIP/306.extension-b7a61778", "QDIALER_QUEUE=1010") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:8] Set("SIP/306.extension-b7a61778", "QDIALER_NUMBER=xxxxxxxxxx") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:9] Set("SIP/306.extension-b7a61778", "QDIALER_AGENT=SIP/306") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:10] Set("SIP/306.extension-b7a61778", "QDIALER_CHANNEL=SIP/306.extension-b7a61778") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:11] Set("SIP/306.extension-b7a61778", "QueueName=1010") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:12] NoOp("SIP/306.extension-b7a61778", "Outbound call -> A:1010 N:xxxxxxxxxx Q:1010 Ch:SIP/306.extension-b7a61778") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:13] Set("SIP/306.extension-b7a61778", "CDR(accountcode)=QDIALAGI") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:14] Set("SIP/306.extension-b7a61778", "ST=1310665268") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:15] Set("SIP/306.extension-b7a61778", "GM=QDV-SIP/306") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:16] Set("SIP/306.extension-b7a61778", "GLOBAL(QDV-SIP/306)=U") in new stack
  == Setting global variable 'QDV-SIP/306' to 'U'
    -- Executing [300xxxxxxxxxx@extension-outbound:17] Set("SIP/306.extension-b7a61778", "GLOBAL(QDV-SIP/306ans)=0") in new stack
  == Setting global variable 'QDV-SIP/306ans' to '0'
    -- Executing [300xxxxxxxxxx@extension-outbound:18] Macro("SIP/306.extension-b7a61778", "queuelog|1310665268|1310665267.168661|1010|SIP/306|ENTERQUEUE|-|xxxxxxxxxx") in new stack
    -- Executing [s@macro-queuelog:1] QueueLog("SIP/306.extension-b7a61778", "1010|1310665267.168661|SIP/306|ENTERQUEUE|-|xxxxxxxxxx|") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:19] AGI("SIP/306.extension-b7a61778", "set-agent-outbound.agi|SIP/306.extension-b7a61778||300xxxxxxxxxx|"Tech Support" <3134817100>") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/set-agent-outbound.agi
    -- Remote UNIX connection
    -- Remote UNIX connection disconnected
    -- AGI Script set-agent-outbound.agi completed, returning 0
    -- Executing [300xxxxxxxxxx@extension-outbound:30] AGI("SIP/306.extension-b7a61778", "call_logger.php.agi|outstart|1310665269|1310665269|Outbound|xxxxxxxxxx|Remote Caller|pchxxxxxxxxxx|SIP/306.extension-b7a61778|300xxxxxxxxxx|NULL") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/call_logger.php.agi
    -- AGI Script call_logger.php.agi completed, returning 0
    -- Executing [300xxxxxxxxxx@extension-outbound:31] AGI("SIP/306.extension-b7a61778", "log-call.agi|outboundstart|1310665269|xxxxxxxxxx|pch300") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/log-call.agi
  agent-log.agi|wrapupin||1|1310665239|: I have written the agent login to the DB: 
[Jul 14 13:41:09] ERROR[28412]: utils.c:966 ast_carefulwrite: write() returned error: Broken pipe
    -- AGI Script agent-log.agi completed, returning 0
    -- Executing [h@callrouter:11] StopMonitor("SIP/enum03-b7a35ea0", "") in new stack
    -- AGI Script log-call.agi completed, returning 0
    -- Executing [300xxxxxxxxxx@extension-outbound:32] AGI("SIP/306.extension-b7a61778", "pending-calls.agi|out|SIP/306.extension-b7a61778|1310665267.168661|xxxxxxxxxx|1310665270|xxxxxxxxxx|pch300") in new stack
    -- Launched AGI Script /var/lib/asterisk/agi-bin/pending-calls.agi
  pending-calls.agi|out|SIP/306.extension-b7a61778|1310665267.168661|xxxxxxxxxx|1310665270|xxxxxxxxxx|pch300: SQL: INSERT INTO `pending_calls` (`status`, `queue`, `code`, `cid`, `details`,`unique_id`,`pickuptime`) VALUES(4,Outbound,pch300,xxxxxxxxxx,SIP/306.extension-b7a61778,1310665267.168661,1310665270)
[Jul 14 13:41:10] ERROR[28572]: utils.c:966 ast_carefulwrite: write() returned error: Broken pipe
    -- AGI Script pending-calls.agi completed, returning 0
    -- Executing [300xxxxxxxxxx@extension-outbound:33] Set("SIP/306.extension-b7a61778", "MONFILENAME=/var/spool/asterisk/monitor/extension/20110714/224110-3134817100-xxxxxxxxxx-pch300") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:34] Monitor("SIP/306.extension-b7a61778", "wav|/var/spool/asterisk/monitor/extension/20110714/224110-3134817100-xxxxxxxxxx-pch300|m") in new stack
    -- Executing [300xxxxxxxxxx@extension-outbound:35] Dial("SIP/306.extension-b7a61778", "SIP/1xxxxxxxxxx@xxx.xxx.xxx.xxx:5060|300") in new stack
    -- Called 1xxxxxxxxxx@xxx.xxx.xxx.xxx:5060
    -- Executing [h@callrouter:14] GotoIf("SIP/enum03-b7a35ea0", "1?250") in new stack
    -- Goto (callrouter,h,250)
    -- Executing [h@callrouter:250] Playback("SIP/enum03-b7a35ea0", "rating_howto") in new stack
[Jul 14 13:41:12] WARNING[28412]: file.c:741 ast_readaudio_callback: Failed to write frame
    -- <SIP/enum03-b7a35ea0> Playing 'rating_howto' (language 'en')
[Jul 14 13:41:12] WARNING[28412]: app_playback.c:439 playback_exec: ast_streamfile failed on SIP/enum03-b7a35ea0 for rating_howto
    -- Executing [h@callrouter:251] Read("SIP/enum03-b7a35ea0", "RATING||1|||4") in new stack
    -- Accepting a maximum of 1 digits.
    -- User disconnected
  == Spawn extension (callrouter, h, 251) exited non-zero on 'SIP/enum03-b7a35ea0'
    -- SIP/xxx.xxx.xxx.xxx:5060-090d3980 is making progress passing it to SIP/306.extension-b7a61778
    -- SIP/xxx.xxx.xxx.xxx:5060-090d3980 is making progress passing it to SIP/306.extension-b7a61778
    -- SIP/xxx.xxx.xxx.xxx:5060-090d3980 answered SIP/306.extension-b7a61778

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Outbound Calls Do Not Show Agent As Busy
« Reply #7 on: August 09, 2011, 10:23:33 »
We need the queue_log, not the CLI output  :)

adz

  • Newbie
  • *
  • Posts: 28
  • Karma: 0
    • View Profile
Re: Outbound Calls Do Not Show Agent As Busy
« Reply #8 on: September 13, 2011, 22:37:07 »
maybe I need to bump up the verbosity but all I see here is:

1315946100|1315946100.2925947|4001|SIP/132|ENTERQUEUE|-|(MY NUMBER)|
1315946126|1315946100.2925947|4001|SIP/132|ABANDON|1|1|26 (THIS IS AFTER I HANG UP)

QueueMetrics

  • Loway
  • Hero Member
  • *
  • Posts: 2999
  • Karma: 39
    • View Profile
    • QueueMetrics
Re: Outbound Calls Do Not Show Agent As Busy
« Reply #9 on: September 14, 2011, 09:55:43 »
Hmmm. this does not look like an outbound call.... it looks like an abandoned inbound.