Thanks for your feedback, Matt.
I've been monitoring the logs lately, and every call from PRI really goes through the system.
Please see list below for calls which I indicated if whether the customer hanged up or the system.
** The image seems a bit huge, please try to open it in a different tab/window, it has logs on the right side (whether from PRI signal hangup or system)
![Image](http://i.imgur.com/SbxPIhD.png)
Please see report below for average inbound calls from In-Group
- Code: Select all
Time range: 2017-06-26 00:00:00 to 2017-06-26 23:59:59
---------- TOTALS
Total calls taken in to this In-Group: 52
Average Call Length for all Calls: 156 seconds
Answered Calls: 50 96%
Average queue time for Answered Calls: 6.12 seconds
Calls taken into the IVR for this In-Group: 0
---------- DROPS
Total DROP Calls: 0 0% drop/answered: 0%
Average hold time for DROP Calls: 0 seconds
---------- CUSTOM INDICATORS
GDE (Answered/Total calls taken in to this In-Group): 96%
ACR (Dropped/Answered): 0%
TMR1 (Answered within 1 seconds/Answered): 0%
TMR2 (Answered within 1 seconds/Answered): 0%
---------- QUEUE STATS
Total Calls That entered Queue: 50 96%
Average QUEUE Length for queue calls: 6.12 seconds
Average QUEUE Length across all calls: 5.88 seconds
Your questions:
How frequently does this happen?
- In a day, around 5-10 calls are being considered as "hangup". I also posted in "General Discussion" about auto-hangup, it seems that it is from the code I added to automatically hangup the agent if he/she is in a "Dead Call".
What is the average number of inbound calls you handle in a day?
- Average is 50 calls per day.
What is the average length of an inbound call?
- Average Call Length for all Calls: 156 seconds
From my investigation:
- I was monitoring the table "vicidial_live_agents" in which the system puts a unique "callerId" to the column "callerid". Most of the time, the system do insert a unique value of "MmmddhhmmssLLLLLLLLL" (from the comment of vdc_db_query source).
I also added a log in conf_exten_check.php->'REFRESH'->"BEGIN DEAD logging section", I found out that it checks the "vicidial_auto_calls" table where callerid = currentCallerId in which currentCallerId is from "vicidial_live_agents.callerid".
The result from "vicidial_live_agents.callerid" is null and thus the condition ($AcalleridCOUNT < 1) will always be true from this mysql query = "SELECT count(*) from vicidial_auto_calls where callerid='$Acallerid';".
I am still tracing the code about where and when does the system inserts the data to "vicidial_live_agents" table. Maybe there's just a conflict between the timing of insertion and query.
How did I replicate the issue:
- In my local environment, I do have a cloud SIP account which takes inbound calls and does outbound calls from and to any physical phone device that has a number.
I called my local vicidial setup many times and the issue is intermittent. But I did get the cause on how the system says the calls is dead.