Page 1 of 1

Hang Up / logout

PostPosted: Fri Aug 16, 2013 4:16 am
by thrasher
Hi,

This is probably a very basic question but I am getting frustrated! Whenever my agents click 'hang up' they are kicked out of the conference and then have to wait 10-20 seconds before it asks them to reconnect and then resume - this is a bit of pain! Is this normal behavior?

Asterisk : Asterisk 1.4.39.1-vici
Vicidial : VERSION: 2.7-401a - BUILD: 130508-2256

Server is DELL DL-160G5 with 4GB RAM

System is using a Sangoma A102 card to link our ISDN30 to our Samsung Officeserv 7400. All functions are working apart from this annoying niggle!

Any help would be appreicated.

Re: Hang Up / logout

PostPosted: Sun Aug 18, 2013 9:42 am
by thrasher
300+ reads and no-one can even tell me if it's normal behavior?

Oh well....

Re: Hang Up / logout

PostPosted: Mon Aug 19, 2013 1:33 am
by williamconley
I strongly suspect you have a problem with your installation. I also note you have not mentioned your installation method.

If you did not install via Vicibox .. please put in a quick note why you couldn't (helpful). Also: Are these agents using "on-hook" phones? (Admin->Phones->{choose phone} "On-Hook" checked?)

Handy to show Asterisk CLI from a single occurrence (not 3000 lines of unrelated code ... just from the moment in question ... start just before the agent presses "Hangup customer" and stop as soon as the agent call dies)

Re: Hang Up / logout

PostPosted: Mon Aug 19, 2013 3:37 am
by thrasher
Hi William,

Here's a dump :

Here's a dump of a call which was hung up by the agent :

[Aug 19 09:15:42] -- Executing [8369@default:5] AGI in new stack
[Aug 19 09:15:42] -- Launched AGI Script /var/lib/asterisk/agi-bin/agi-VDAD_ALL_outbound.agi
[Aug 19 09:15:42] -- AGI Script agi-VDAD_ALL_outbound.agi completed, returning 0
[Aug 19 09:15:42] -- Executing [192*168*004*043*8600051@default:1] Goto("DAHDI/9-1", "default|8600051|1") in new stack
[Aug 19 09:15:42] -- Goto (default,8600051,1)
[Aug 19 09:15:42] -- Executing [8600051@default:1] MeetMe("DAHDI/9-1", "8600051|F") in new stack
[Aug 19 09:15:44] Parsing '/etc/asterisk/manager.conf': [Aug 19 09:15:44] Found
[Aug 19 09:15:44] Manager 'sendcron' logged on from 127.0.0.1
[Aug 19 09:15:44] -- Executing [58600051@default:1] MeetMe("Local/58600051@default-8e41,2", "8600051|Fmq") in new stack
[Aug 19 09:15:44] > Channel Local/58600051@default-8e41,1 was answered.
[Aug 19 09:15:44] -- Executing [8309@default:1] Answer("Local/58600051@default-8e41,1", "") in new stack
[Aug 19 09:15:44] -- Executing [8309@default:2] Monitor("Local/58600051@default-8e41,1", "wav|") in new stack
[Aug 19 09:15:44] Manager 'sendcron' logged off from 127.0.0.1
[Aug 19 09:15:44] -- Executing [8309@default:3] Wait("Local/58600051@default-8e41,1", "3600") in new stack
[Aug 19 09:15:46] Parsing '/etc/asterisk/manager.conf': [Aug 19 09:15:46] Found
[Aug 19 09:15:46] Manager 'sendcron' logged on from 127.0.0.1
[Aug 19 09:15:46] Spawn extension (default, 8600051, 1) exited non-zero on 'DAHDI/9-1'
[Aug 19 09:15:46] -- Executing [h@default:1] DeadAGI("DAHDI/9-1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0---------------") in new stack
[Aug 19 09:15:46] Manager 'sendcron' logged off from 127.0.0.1
[Aug 19 09:15:46] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Aug 19 09:15:46] -- Hungup 'DAHDI/9-1'
[Aug 19 09:15:46] Parsing '/etc/asterisk/manager.conf': [Aug 19 09:15:46] Found
[Aug 19 09:15:46] Manager 'sendcron' logged on from 127.0.0.1
[Aug 19 09:15:46] Manager 'sendcron' logged off from 127.0.0.1
[Aug 19 09:15:46] Parsing '/etc/asterisk/manager.conf': [Aug 19 09:15:46] Found
[Aug 19 09:15:46] Manager 'sendcron' logged on from 127.0.0.1
[Aug 19 09:15:46] Manager 'sendcron' logged off from 127.0.0.1
[Aug 19 09:15:46] Parsing '/etc/asterisk/manager.conf': [Aug 19 09:15:46] Found
[Aug 19 09:15:46] Manager 'sendcron' logged on from 127.0.0.1
[Aug 19 09:15:46] Manager 'sendcron' logged off from 127.0.0.1
[Aug 19 09:15:46] Spawn extension (default, 8600051, 1) exited non-zero on 'DAHDI/33-1'
[Aug 19 09:15:46] -- Hungup 'DAHDI/pseudo-433651915'
[Aug 19 09:15:46] -- Executing [h@default:1] DeadAGI("DAHDI/33-1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0---------------") in new stack
[Aug 19 09:15:46] Spawn extension (default, 58600051, 1) exited non-zero on 'Local/58600051@default-8e41,2'
[Aug 19 09:15:46] -- Executing [h@default:1] DeadAGI("Local/58600051@default-8e41,2", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0---------------") in new stack
[Aug 19 09:15:46] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Aug 19 09:15:46] -- Hungup 'DAHDI/33-1'
[Aug 19 09:15:46] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Aug 19 09:15:46] == Spawn extension (default, 8309, 3) exited non-zero on 'Local/58600051@default-8e41,1'
[Aug 19 09:15:46] -- Executing [h@default:1] DeadAGI("Local/58600051@default-8e41,1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0---------------") in new stack
[Aug 19 09:15:46] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0

Re: Hang Up / logout

PostPosted: Mon Aug 19, 2013 3:40 am
by thrasher
On-hook set to Y or N makes no difference.

Re: Hang Up / logout

PostPosted: Mon Aug 19, 2013 4:16 am
by DomeDan
Tell us about the system,
is it a scratch install? or did you download a iso, vicibox maybe? if so then what was the same of the iso?

Re: Hang Up / logout

PostPosted: Mon Aug 19, 2013 5:18 am
by thrasher
It is installed from the goautodial 3.0 iso - but I am using the vicidial front ends for admin etc.

One of the main reasons for going this route is that I am much more comfortable with Centos than Suse, coupled with management wanting pretty graphs. Best of both worlds seemed to be goautodial for them.

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 3:49 am
by thrasher
I can see it is doing two hangups, one for the pseudo and one for the actual line - any hints on why it would do this?

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 4:04 am
by DomeDan
I'm not familiar with that problem, but post some more info like your dialplan etc,
and does this happen when you are using the goautodial agent interface?

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 4:07 am
by thrasher
Happens with both interfaces - all testing being done by me is using the Vicidial interface.

Relevant parts of config :

[default]
include => vicidial-auto

exten => _XXXXXXXXXXXX,1,Dial(${TRUNKPRI}/${EXTEN:2},,tToR)
exten => _XXXXXXXXXXXX,2,Hangup

; dialplan to dial the epabx extensions - in my case epabx extensions is 3 digi$
exten => _2XX,1,Dial(${TRUNKPBX}/${EXTEN},,TtoR)
exten => _2XX,2,Hangup()

(rest in default is all standard)

[from-pstn] ; context to receive incomming calls fromt the service provider ie:port1 of E1 card
; dialplan to route the incomming calls from the service provider
; my provider send last 3 digits from my DID ie: my did is 4004400 so he sends 400 , 401 ...

;exten => _XXX,1,Dial(SIP/${EXTEN}) ; rings my asteirsk sip extension which matches the 3 Digits.
;exten => _XXX,2,Hangup()
; if you want to ring the EPABX extension then use the below dialplan

;exten => _XXXXXX,1,Dial(${TRUNKPBX}/${EXTEN},,TtoR)
;exten => _XXXXXX,2,Hangup()

exten => _XXXXXX,1,AGI(agi-DID_route.agi)
exten => _XXXXXX,2,Dial(${TRUNKPBX}/${EXTEN},,TtoR)
exten => _XXXXXX,3,Hangup()

[from-epabx] inbound cotext to handle the incomming from the epabx as mentioned in dahdi-channels.conf
exten => s,1,Answer()

exten => s,n(start),Read(PHONE,,14,,,)
;exten => s,n,GotoIf($[${LEN} = 4]?asterisk)
exten => s,n,GotoIf($[${LEN} > 8]?landline)
;exten => s,n,GotoIf($[${LEN} > 8]?mobile)
exten => s,n(end),Playback(invalid)
exten => s,n(try),Goto(start)
exten => s,n(asterisk),Goto(asterisk,${PHONE},1)
exten => s,n(landline),Goto(landline,${PHONE},1)
exten => s,n(mobile),Goto(mobile,${PHONE},1)

exten => i,1,Playback(invalid)
exten => i,n,Hangup()

exten => t,1,Playback(unavailable)
exten => t,n,Hangup

[asterisk]
exten => _XXXX,1,Dial(SIP/${EXTEN:1}) ; discard first digit as my asterisk is a 3digit extension.
exten => _XXXX,2,Hangup
[landline]
exten => _X.,1,Dial(${TRUNKPRI}/${EXTEN:1},,tToR)
exten => _X.,2,Hangup
[mobile]
exten => _X.,1,Dial(${TRUNKPRI}/${EXTEN},,tToR) ; to dial mobile sometimes need zero prefix
exten => _X.,2,Hangup

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 4:15 am
by DomeDan
what about extensions-vicidial.conf ? or is some of the lines from that file?

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 4:20 am
by thrasher
Hi, I was unaware of this file (although it states it will be autogenerated so any changes I make will be removed?)

; WARNING- THIS FILE IS AUTO-GENERATED BY VICIDIAL, ANY EDITS YOU MAKE WILL BE LOST
TRUNKloop = IAX2/ASTloop:test@127.0.0.1:40569
TRUNKblind = IAX2/ASTblind:test@127.0.0.1:41569


; logging of all outbound calls from agent phones
[defaultlog]
exten => s,1,Answer
exten => s,n,AGI(agi-VDAD_inbound_calltime_check.agi,-----NO-----defaultlog-------------------------NO)
exten => s,n,Set(INVCOUNT=0)
exten => s,n,Background(sip-silence)
exten => s,n,WaitExten(20)


; hangup
exten => t,1,Playback(vm-goodbye)
exten => t,n,Hangup()
exten => i,1,Goto(s,4)
exten => i,n,Hangup()
; hangup
exten => h,1,DeadAGI(agi://127.0.0.1:4577/call_log--HVcauses ... EBUG-----${HANGUPCAUSE}-----${DIALSTATUS}-----${DIALEDTIME}-----${ANSWEREDTIME})

; custom dialplan entries
exten => _X.,1,AGI(agi-NVA_recording.agi,BOTH------Y---Y---Y)
exten => _X.,n,Goto(default,${EXTEN},1)




[vicidial-auto-external]
exten => h,1,DeadAGI(agi://127.0.0.1:4577/call_log--HVcauses ... EBUG-----${HANGUPCAUSE}-----${DIALSTATUS}-----${DIALEDTIME}-----${ANSWEREDTIME})

; Local Server: 192.168.4.43
exten => _192*168*004*043*.,1,Goto(default,${EXTEN:16},1)
exten => _192*168*004*043*.,2,Hangup()
exten => _**192*168*004*043*.,1,Goto(default,${EXTEN:18},1)
exten => _**192*168*004*043*.,2,Hangup()

[vicidial-auto-internal]
exten => h,1,DeadAGI(agi://127.0.0.1:4577/call_log--HVcauses ... EBUG-----${HANGUPCAUSE}-----${DIALSTATUS}-----${DIALEDTIME}-----${ANSWEREDTIME})
; Voicemail Extensions:
exten => _85026666666666.,1,Wait(1)
exten => _85026666666666.,n,Voicemail(${EXTEN:14},u)
exten => _85026666666666.,n,Hangup()
exten => 8500,1,VoicemailMain
exten => 8500,2,Goto(s,6)
exten => 8500,3,Hangup()
exten => 8501,1,VoicemailMain(s${CALLERID(num)})
exten => 8501,2,Hangup()

; Prompt Extensions:
exten => 8167,1,Answer
exten => 8167,2,AGI(agi-record_prompts.agi,wav-----720000)
exten => 8167,3,Hangup()
exten => 8168,1,Answer
exten => 8168,2,AGI(agi-record_prompts.agi,gsm-----720000)
exten => 8168,3,Hangup()

; this is used for recording conference calls, the client app sends the filename
; value as a callerID recordings go to /var/spool/asterisk/monitor (WAV)
; Recording is limited to 1 hour, to make longer, just change the server
; setting ViciDial Recording Limit
; this is the WAV verison, default
exten => 8309,1,Answer
exten => 8309,2,Monitor(wav,${CALLERID(name)})
exten => 8309,3,Wait(3600)
exten => 8309,4,Hangup()
; this is the GSM verison
exten => 8310,1,Answer
exten => 8310,2,Monitor(gsm,${CALLERID(name)})
exten => 8310,3,Wait(3600)
exten => 8310,4,Hangup()

; agent alert extension
exten => 83047777777777,1,Answer
exten => 83047777777777,2,Playback(${CALLERID(name)})
exten => 83047777777777,3,Hangup()
; This is a loopback dial-around to allow for immediate answer of outbound calls
exten => _8305888888888888.,1,Answer
exten => _8305888888888888.,n,Wait(${EXTEN:16:1})
exten => _8305888888888888.,n,Dial(${TRUNKloop}/${EXTEN:17},,To)
exten => _8305888888888888.,n,Hangup()
; No-call silence extension
exten => _8305888888888888X999,1,Answer
exten => _8305888888888888X999,n,Wait(3600)
exten => _8305888888888888X999,n,Hangup()

[vicidial-auto-phones]
exten => h,1,DeadAGI(agi://127.0.0.1:4577/call_log--HVcauses ... EBUG-----${HANGUPCAUSE}-----${DIALSTATUS}-----${DIALEDTIME}-----${ANSWEREDTIME})

; Phones direct dial extensions:

[vicidial-auto]
exten => h,1,DeadAGI(agi://127.0.0.1:4577/call_log--HVcauses ... EBUG-----${HANGUPCAUSE}-----${DIALSTATUS}-----${DIALEDTIME}-----${ANSWEREDTIME})

include => vicidial-auto-internal
include => vicidial-auto-phones
include => vicidial-auto-external


; END OF FILE

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 4:35 am
by DomeDan
Seams like you didn't add the dialplan in the vicidial webui,
that would appear in that file then.

Ah yeah right, you use PRI
I guess this is the dialplan to dial out:
exten => _XXXXXXXXXXXX,1,Dial(${TRUNKPRI}/${EXTEN:2},,tToR)
might be that you are missing the AGI function

try this:
exten => _XXXXXXXXXXXX,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _XXXXXXXXXXXX,2,Dial(${TRUNKPRI}/${EXTEN:2},,tToR)
exten => _XXXXXXXXXXXX,3,Hangup

If it aint helping then wait for someone with more knowledge with PRI,
when they see this post they will probably understand the problem

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 4:40 am
by thrasher
Hi,

Thanks for the help so far, added that in and it's done nothing after a dialplan reload - I might try and force an asterisk restart.

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 7:01 am
by thrasher
Pretty sure the issue lies here :

[Aug 20 12:58:25] == Parsing '/etc/asterisk/manager.conf': [Aug 20 12:58:25] Found
[Aug 20 12:58:25] == Manager 'sendcron' logged on from 127.0.0.1
[Aug 20 12:58:25] == Manager 'sendcron' logged off from 127.0.0.1
[Aug 20 12:58:25] == Spawn extension (default, 8600051, 1) exited non-zero on 'DAHDI/2-1'
[Aug 20 12:58:25] -- Executing [h@default:1] DeadAGI("DAHDI/2-1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0---------------") in new stack
[Aug 20 12:58:25] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Aug 20 12:58:25] -- Hungup 'DAHDI/2-1'
[Aug 20 12:58:25] == Parsing '/etc/asterisk/manager.conf': [Aug 20 12:58:25] Found
[Aug 20 12:58:25] == Manager 'sendcron' logged on from 127.0.0.1
[Aug 20 12:58:25] == Manager 'sendcron' logged off from 127.0.0.1
[Aug 20 12:58:25] == Parsing '/etc/asterisk/manager.conf': [Aug 20 12:58:25] Found
[Aug 20 12:58:25] == Manager 'sendcron' logged on from 127.0.0.1
[Aug 20 12:58:25] == Manager 'sendcron' logged off from 127.0.0.1
[Aug 20 12:58:25] -- Hungup 'DAHDI/pseudo-837752789'
[Aug 20 12:58:25] == Spawn extension (default, 8600051, 1) exited non-zero on 'DAHDI/34-1'
[Aug 20 12:58:25] -- Executing [h@default:1] DeadAGI("DAHDI/34-1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0---------------") in new stack
[Aug 20 12:58:25] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Aug 20 12:58:25] -- Hungup 'DAHDI/34-1'

It is cutting the PRI conection (DAHDI/2-1), and then proceeding to disconnect the Phonesystem to Asterisk connection (DAHDI/34-1). I guess I just need to find out how to stop it doing this :(

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 7:25 am
by DomeDan
Play around with a higher debugging level

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 8:44 am
by thrasher
Hi - what sort of debug level do you suggest?

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 8:52 am
by DomeDan
Go for the highest if you have to :wink:

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 9:13 am
by thrasher
Verbosity and Debug set at 8 and 4 respectively - nothing new showing up....

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 9:16 am
by thrasher
[Aug 20 15:12:48] == Spawn extension (default, 58600053, 1) exited non-zero on 'Local/58600053@default-aec0,2'
[Aug 20 15:12:48] -- Executing [h@default:1] DeadAGI("Local/58600053@default-aec0,2", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0---------------") in new stack
[Aug 20 15:12:48] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Aug 20 15:12:48] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Aug 20 15:12:48] -- Hungup 'DAHDI/41-1'

Am I reading this right? 58600053 is the recording right? It's not even on for this campaign so why is it trying to hang it up?

Re: Hang Up / logout

PostPosted: Tue Aug 20, 2013 9:21 am
by thrasher
With AGI debug on too :

[Aug 20 15:19:59] == Spawn extension (default, 8600051, 1) exited non-zero on 'DAHDI/34-1'
[Aug 20 15:19:59] -- Executing [h@default:1] DeadAGI("DAHDI/34-1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0---------------") in new stack
[Aug 20 15:19:59] AGI Tx >> agi_network: yes
[Aug 20 15:19:59] AGI Tx >> agi_network_script: call_log--HVcauses--PRI-----NODEBUG-----0---------------
[Aug 20 15:19:59] AGI Tx >> agi_request: agi://127.0.0.1:4577/call_log--HVcauses ... ----------
[Aug 20 15:19:59] AGI Tx >> agi_channel: DAHDI/34-1
[Aug 20 15:19:59] AGI Tx >> agi_language: en
[Aug 20 15:19:59] AGI Tx >> agi_type: DAHDI
[Aug 20 15:19:59] AGI Tx >> agi_uniqueid: 1377008355.732
[Aug 20 15:19:59] AGI Tx >> agi_callerid: 0844000000
[Aug 20 15:19:59] AGI Tx >> agi_calleridname: ACagcW1377008351agent278agent278agent278agent278
[Aug 20 15:19:59] AGI Tx >> agi_callingpres: 0
[Aug 20 15:19:59] AGI Tx >> agi_callingani2: 0
[Aug 20 15:19:59] AGI Tx >> agi_callington: 0
[Aug 20 15:19:59] AGI Tx >> agi_callingtns: 0
[Aug 20 15:19:59] AGI Tx >> agi_dnid: unknown
[Aug 20 15:19:59] AGI Tx >> agi_rdnis: unknown
[Aug 20 15:19:59] AGI Tx >> agi_context: default
[Aug 20 15:19:59] AGI Tx >> agi_extension: h
[Aug 20 15:19:59] AGI Tx >> agi_priority: 1
[Aug 20 15:19:59] AGI Tx >> agi_enhanced: 0.0
[Aug 20 15:19:59] AGI Tx >> agi_accountcode:
[Aug 20 15:19:59] AGI Tx >>
[Aug 20 15:19:59] -- AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ---------- completed, returning 0
[Aug 20 15:19:59] -- Hungup 'DAHDI/34-1'

Re: Hang Up / logout

PostPosted: Thu Aug 29, 2013 5:54 pm
by thrasher
All sorted - changed the phones from Zap to External and it all works (with correct dialplan for the extensions)

Re: Hang Up / logout

PostPosted: Fri Aug 30, 2013 2:49 am
by DomeDan
cool! good postback!

Re: Hang Up / logout

PostPosted: Thu Oct 10, 2013 2:42 pm
by budol69
hi thrasher,

Can you post here your working sample dialplan.
I have experiencing the same issue but I'm using VERSION: 2.7-401a BUILD: 130508-2256, Asterisk 1.8.23.1 and SIPTrunk.

Thanks!