Call File Pacing

FreePBX/Asterisk 14


I’ve had some great success using call files thanks to Dave and dicko on this forum. I’m at a point where I’d like to experiment with different callfile applications. As I expand I’m worried about the total number of concurrent call files being processed.

I’m wonder if the group has any insights or recommendations on how to approach this? I don’t want the call file to fail (aka hard limit), so I was thinking some sort of job that watches a folder and moves 10 files from /tmp/ to the outgoing call folder every 10 minutes.

I’m just not sure if there is a better approach for this.

Any insights would be appreciated! Thanks!

In general the trick is to ‘touch’ the files with a random timestamp that is within the concurrent call capacity of your system, the length of the calls and the timlyness of such calls.

Helpful bashism

echo $(($RANDOM % 60)) # generates a random number between 0 and 60

touch FILE -d “now + $(($RANDOM % 60 )) minutes”

f the files are being generated asynchronously, then if they dated in the future you can put them straight in outgoing directory. If they are generated by a process you can’t control, look at using incron

1 Like