I finally got everything set up for asterisk to process calls as a dialer. However, when I drop a bunch of .call files into the /var/spool/asterisk/outgoing directory they all initialize at the same time.
My .call file looks like this:
Channel: IAX2/4444
MaxRetries: 2
RetryTime: 60
WaitTime: 180
Extension: 1234
Priority: 2
I was expecting the calls to initialize and dial one at a time… But instead they all went active.
All I have on the extension 1234 is an automated message right now. This eventually will be a custom application I’m working on. Anyone know why I’m experiencing this issue?
If I initialize the call to an extension and that extension is in use; shouldn’t it be “busy”?
More over, right now I’m only doing internal calls. I’ll be trying to a VOIP termination service shortly… If there are only a certain amount of lines open then what can I expect?
So I need to be in control of how many calls are going out at one time then…?
If that’s the case I’ll need to look at how many files exist in the outgoing directory and have a daemon service watching it and adding call files. Unless there’s an easier way?
Trying to monitor the number of .call files in the folder will almost always show you zero since asterisk processes them very fast until all available channels are used at which time they will start to back up. I have seen asterisk grab all the channels on a 4 x T1 system in under 5 seconds.
A better approach IMHO is to write your code so it checks the availability of channels before dropping call files into the stream. You can/should also set limits in you code so that it does not take over your entire resources.
I found out that I can set a number of active channels in the iax configuration. I’m going to play with that a bit and see what kind of effect that offers on the /outbound queue directory.
You should look at AsterCrm, it will take care of setting how many calls should go out. It is easy to setup and the writer of the app will answer any questions quickly on the fcrum. It sure beats writing your own app.