TUTORIAL Tally of Concurrent Calls

hmonroe

New Member
Joined
Apr 16, 2008
Messages
24
Reaction score
0
Is there a way I can tell the maximum number of concurrent calls over a period of time?

We have a PRI which is overkill for our downsized company. I've heard that you can get a "fractional" PRI dedicating some bandwidth for calls, some Internet, but I need to know the maximum number of concurrent calls which are being made?
 

jroper

Guru
Joined
Oct 20, 2007
Messages
3,832
Reaction score
71
Inspection of the CDR and reports will give that report, although you will have to do some searching.

Joe
 

jmullinix

Guru
Joined
Oct 21, 2007
Messages
1,263
Reaction score
7
In the reports section, click on daily load. Choose the day you want to investigate and click search. Scroll town to the second part of the page, choose what hour you are interested in and choose fluctuation graph. There you go.
 

deano

Member
Joined
May 26, 2008
Messages
212
Reaction score
7
This is a good question.

I too would like to be able to see what and when in a day my lines hit the max load. Is there an easy report. I did see the one for each hour, but I would like to see one for the whole day. That way i can see if there is enough need for more lines. Also, if there was as way to see the duration that these lines were like this.

Thanks
 

hmonroe

New Member
Joined
Apr 16, 2008
Messages
24
Reaction score
0
That did the trick for hourly, I sure would like to know daily for the month, but this is a start. Thanks for the tip!
 

JoelC707

New Member
Joined
Feb 24, 2009
Messages
9
Reaction score
0
What I did was access the CDR in FreePBX and tell it to show the date range I want and filter by source. In the source I know my PRI uses ZAP channels Zap/1-1 to Zap/23-1. So I filtered by "Zap/2", inspected the results then re-filtered by "Zap/3" and so on till it quit giving me results. The last channel you filtered by was the total number of channels in use at any given time. In my case I ended on Zap/8 meaning the most channels ever in use in the past year was 8 channels. It was only one occurrence and the most channels used with more than one occurrence was 6 channels. A far cry from the 23 channels I have available which is causing me to look at cheaper alternatives since it is clear we don't even need half the channels.

Is Nuvox a reseller in your area? I can't get it because I'm a legacy FDN customer but they offer a dynamic PRI. It's similar to what you are looking at but you don't have to choose how many channels you want for data and voice. When no calls are in use you essentially have a full T1 available for data. But as calls come in some of the data bandwidth gets reallocated to voice and you can still burst all the way up to 23 channels. The downside is that you need another internet source because it is a PRI first meaning if needed, the entire trunk will be allocated to voice. Unlike a dynamic T1 where it is data first and the voice can't fully allocate it. The other downside is price, it won't give you any cost savings because it's the same cost as a PRI. But what it will do is give you another internet source for load balancing and maybe even some redundancy.

Joel
 

Boolah

Guru
Joined
Nov 16, 2007
Messages
331
Reaction score
20
I was somewhat surprised that this information could not be gleaned from the CDR reports, in anything other than one hour increments, so I wrote a quick PHP script to generate the information for any specified time period (seconds, days, months, etc.). Just specify a date and time for the period you're interested in looking at and click the Update button.

Please note that this script was primarily created for my own edification, so it's not well documented, pretty or secure on the open Internet. I would make sure that it's only accessible from your LAN. Just drop this in your /var/www/html/admin folder and access it by going to http://<your PiaF IP>/admin/load.php

The script only takes into account [incoming and outgoing] external calls and ignores calls between extensions.

Checking the "debug" option will display the number of simultaneous calls at every "occurrence" (i.e. every time a call is started or stopped). Use this with care since looking at the debug info for months of CDRs can fill up your browser quickly.

It also provides a distribution of simultaneous calls so you can tell how many times in the given time period you hit a given load.

Hope someone finds this useful.

EDIT: Please see this post for the most recent version.
 

jroper

Guru
Joined
Oct 20, 2007
Messages
3,832
Reaction score
71
Hi

I've quickly knocked it up as a module so you can upload it through the PBX interface.

It would look really good with a bit of tidying up, and I reckon we can also solve the issue of the username and password for the CDR reports by getting that from amportal - I think tshif is the master of that.

Try it and upload via module admin in FreePBX, then enable it.

I cannot attach tgz files to the forum, so its here for the moment.

http://www.fonicaprojects.com/downloads/freepbxmodules/concurrentcalls-1.0.tgz




Joe

PS - The module is very rough and ready
 

Boolah

Guru
Joined
Nov 16, 2007
Messages
331
Reaction score
20
There was a bug in the script where the distribution of calls was incorrect if the number of simultaneous calls jumped non-sequentially (i.e. jumping from 1 to 4). This only affected the distribution, not the the maximum, but it's been fixed and updated in my original post.
 

Boolah

Guru
Joined
Nov 16, 2007
Messages
331
Reaction score
20
Joe - when using your module, when I click the Update button I just get taken to the main FreePBX page. I supposed this because the form I'm using submits to $_SERVER["PHP_SELF"]
 

deano

Member
Joined
May 26, 2008
Messages
212
Reaction score
7
This is a good report.

Ideally, I would like to see one that can tell me how many times my lines were maxed out. That way, I can determine if I need more lines. Also, it would help to understand what time of day these were hitting. But this is a great start. I will look at the script and see if I can modify it some more.

The total Idea is to see how many times my lines are in full use and then for how long. That way I can assess the need for more lines.

Thanks everyone.
 

deano

Member
Joined
May 26, 2008
Messages
212
Reaction score
7
ok, so I looked it over and I am fooling myself. I don't know the database that well.

Anyone interested in hammering this out?
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,206
Reaction score
5,228
Here's the module in zip format. Thanks, Joe.
 

Attachments

  • concurrentcalls.zip
    2.5 KB · Views: 35

Boolah

Guru
Joined
Nov 16, 2007
Messages
331
Reaction score
20
deano: If you have 5 lines and 5 concurrent calls, your lines are maxed out. If this occurs 10 times, you've maxed out your lines 10 times. Did I understand your question correctly?

If you're asking for the number of times that a 6th person has called when you only have 5 lines, I don't think that's something you'll be able to glean from the CDR since the 6th call would never have made it to your PBX to begin with.

To see what time of day you were hitting specific loads, enable debugging. It will list the time stamp and current load at each time stamp. You can also change the start and end date and time to look at different time periods, but watch out looking at months with debugging on - you'll get a screen full!
 

TheShniz

Guru
Joined
Nov 15, 2007
Messages
560
Reaction score
2
This is an interesting 'lil report/page, but I have a question of how the calls are tabulated... the numbers seem to be accurate for each range I've put in w/ the exception of march.

You see in march, my wiffle orchestrated a surprise birthday party for me which I found out about ahead of time... and so to 'put one over' on everyone, I put a whole bunch of peoples' cell numbers (that I knew were going to be there) in a ring group at work (which played a very funny announcement which I pieced together). The point being, a minute before I walked through the door, I rang everyone's cell phones and played this message... then I busted through the doors :)

Well....... I put more telephone numbers that I had lines @ work, so the way Asterisk works is to keep trying until one becomes available, and this artificially raised the max simultaneous calls. Now I've not looked @ the script itself, but is there any way to filter that only calls that are connected/answered are included?

MWUHAAAAAAAAaaaaaaaaaaaaaaaaaaaa...

:party:

...this is what happens when you're married 2 a telecom-guy.:biggrinjester:
 

Boolah

Guru
Joined
Nov 16, 2007
Messages
331
Reaction score
20
The script should only look at calls which actually connect. This is filtered through the SQL query which only retrieves records where billsec > 0 (if a call doesn't connect, billsec = 0, even though duration might be > 0).
 

deano

Member
Joined
May 26, 2008
Messages
212
Reaction score
7
boolah,

You are correct. What I want to know is when and how long within the time frame I specify my FXO lines were maxed out. That way i can determine if I need more lines. Right now, the default is lets me see only an hour at a time. But this is pretty good.

for example, if at 3-5pm I have 25 times that my lines are maxed out for over 3 minutes, then I think this is an issue since my lines are are returning a busy to potential clients.

I have set the max outbound calls to 3 so that people can't tie up all of the lines. But it would still be possible to lock these up if the inbound was exceeded. Not to good for business.

So, Ideally, I would like to see a # times over the selection time period, then the top longest 10 and thier durations(so the top ten in the period and what the longest time was in which the lines were unavailable to new inbound calls.).

Not much to ask right?

Thanks, I am just hoping that others can see this need. It would be a great way to either sell more services to the client or provide a work around.

Thanks
 

Boolah

Guru
Joined
Nov 16, 2007
Messages
331
Reaction score
20
New Version

There's a new version of this script available. The two big changes are the script is now a FreePBX module so it can be uploaded right into FreePBX (thanks, Joe) and the data is now displayed in a CDR-style graph.

The new module can be downloaded from here.
 

Boolah

Guru
Joined
Nov 16, 2007
Messages
331
Reaction score
20
deano:

I see what you're saying now. I'll add this into the next version.
 

Members online

No members online now.

Forum statistics

Threads
25,825
Messages
167,849
Members
19,250
Latest member
mark-curtis
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top