In asterisk there is the option to select r0 instead of g0 when configuring a trunk which must use group 0 - the r makes it use the lines in the group in a round-robin fashion instead of ascending (G or R reverses the order)
In freepbx there is only a drop-down which only allows ascending or descending use of a group - this is a problem where you have lots of channels which have committed usage on them from your telco.
Is there any way for me to set this manually?
FreePBX Distro 3.211.63 - asterisk 11
Thanks in advance.
just create the trunk r0, it will “know” .
Years I have been at this and never knew the round robin prefix for DAHDI, thanks.
You can do this with a Custom Trunk within FreePBX, use a custom dial string of:
Yes and also G0 if you want to avoid glare.
thanks for the help guys - the custom trunk makes sense - don’t like things that just “know” without me telling them…
I had already modified my extensions_additional.conf and changed the relevant lines to OUT_1 = DAHDI/r0 - works a treat except won’t withstand a reload. I will implement the custom trunks.
As I said, make a dahdi trunk with the “dahdi Identifier” as r0. Dahdi “knows” about G,g,r and R. That way it will survive a restart.
for the interest of others searching on this - I did try the creation of the trunk r0 and it didn’t work for me - so went the route of the custom trunk which works brilliantly.
I also am working on quite a busy system so this is a little difficult to test so I rather queried the mysql asteriskcdrdb database with the following which gives you a good picture of how well things are being balanced.
SELECT IF((LENGTH(dstchannel) - LENGTH(REPLACE(dstchannel,"/",""))) > 1,
SUBSTRING(dstchannel,1,LENGTH(dstchannel) - LOCATE("/",REVERSE(dstchannel))),
dstchannel) as dstchannel, count(*) as cnt FROM `cdr`
WHERE SUBSTRING(dstchannel,1,5) = "DAHDI" AND `calldate` > "2013-05-21 16:00"
GROUP BY 1
Dicko, when using the latest Schmooze DAHDI config module, it hooks into the trunk config page and limits DAHDI trunk strings to options in a drop down menu. This menu does not present r/R as an option.
l0ft13, strongly suggest you submit a feature request to have this feature added to the DAHDI config module, particularly since it is not a well known option.
*edit* already done http://www.freepbx.org/trac/ticket/6585
That is not in the dahdiconfig module, it is in the “add dahdi trunk” bit where the identifier is free-form and complete with a help button., if you don’t create it it can’t be used
(well, it can be used as you guys have discovered,as it is intrinsic in the Dahdi driver, but only in the custom context, adding the r0 trunk makes it universally available as needed)
You are missing my point. Once installed and activated, the “DAHDI Config Module” alters the DAHDI Trunk Create/Edit page, removes the free form field entry and replaces it with a drop down menu.
I don’t use the dahdiconfig module, as it only handles very generic cases, and apparently not this case so you are probably right, I would suggest that that is a definite lack of function in that module but if you remove that module, my guess is that it would then work as it has for the last 8 years.
Checked to work on FreePBX 126.96.36.199 on a client machine with the dahdiconfig module “disabled”
My personal opinion is the DAHDI config module is more trouble that it is worth. There are simply too many permutations of DAHDI config (like a reverse signalling PRI for B2B trunking).
I am sure many find it a lifesaver but when the first thing I do on a system with the module installed is to check the DAHDI configs it generated something is wrong.
In the OP posters case, frankly if he can write that elegant a SQL query he should be able to figure out DAHDI in 10 minutes. Scrap the module and put the r in the trunk where it belongs.
Dicko’s choice of terms was unfortunate, there is no magic to the option and it is fully documented in the DAHDI docs sample config files.
Thanks for the comments Scott (I thought my sql was rather elegant myself - it never crossed my mind to simply kill the module and do the config myself - have been tearing my hair out over a couple of other issues with the DAHDI config so I think I will give this a go.
From a developer’s standpoint it’d be sure nice to know what is making you “tear your hair out”
but I digress
considering schmooze invested heavily in the dahdi config module it’s unfortunate that you’ve said your opinions in the public here instead of directing it to us.
Andrew, I didn’t put much thought into the soci/political ramifications of the concept and it wasn’t directed at the work product or the module itself. Certainly I know how much work was involved just to get it functional. I also know that it was your effort so please don’t take it personal.
There is such a vast universe of DAHDI cards, odd orders of startup etc. Getting the hardware to play well with the software seems to me to be a tough automation task.
Speaking generally in principals, these web interfaces to system configs cause more havoc than they are worth. I was installing the latest Proxmox today on a system with 3 network interfaces. I was able to configure directly in about 20 minutes. It took me half the day to get the GUI to configure the network cards the way I wanted them. Similarly the network module in Sysadmin can lead down some dark paths. When I use ifconfig to modify and interface I don’t have the same concerns.
So certainly my apologies to you and the team. I am sure there are many users that have benefited and I will refrain from making such sweeping generalities.
Have a great holiday weekend.