Incominglimit & SIP realtime problem


#1

Hi,

I am trying to limit the number of outgoing calls a user can make at the same time. This seems to works fine when I put a statement like “incominglimit = 3” for a user in the sip.conf file, but it seems not to work with the asterisk realtime support.

We use a MYSQL database for our users using the MYSQL support provided in asterisk-addons. I have a column “incominglimit” defined which contains the call limits for each user. If I do a “sip show user xxx load” command in the CLI the correct call limit for the user as defined in the database is shown. However, asterisk does not limit the outgoing calls to the call limit displayed.

Any ideas?

Thanks,
Andy


#2

what version of asterisk?

in 1.2.3 and above, a bug that existed was fixed, so that call-limit works. incominglimit and outgoinglimit never really worked, to my knowledge, but i KNOW call limit works, as long as youre running 1.2.3 or above.

one thing that i keep forgetting is that call limit only works with type=peer. type=friend doesn’t for some reason.

as for realtime, i’m not sure how the call limits work - from the docs on voip-info, it looks like you could just add a ‘call-limit’ column. i’d try that.

let me know, we’re going to be migrating to realtime in a few months, and i’d be interested to hear the results and your thoughts in general.


#3

@whoiswes:

I’m using asterisk 1.2.4 …

AFAIK “incominglimit” is a (deprecated) synonym for “call-limit” (I looked into the source code a little and found that both are handled equally). Anyway, one should use “call-limit” in future applications. The reason I have started witch incominglimit is just because it was described in TFOT and call-limit was not.

Working with “incominglimit” and “friend” worked fine for me, if I do the configuration in sip.conf.

[testuser] type = friend host = dynamic md5secret = xxxxxxxxxxxxxxxxxxxxxxxxxx context = test canreinvite = no nat = yes incominglimit = 1
I have added a column named “incominglimit” to the MySQL table. The value in that column is shown as the “Call Limit” when I do a “sip show user testuser load” (load is needed for users defined in a RTDB). However, it is not used when I place calls :frowning:


#4

Just an idea because i’m looking on something related : maybe try with group…

Look here :

voip-info.org/wiki/index.php … d+SetGroup

and

voip-info.org/wiki/view/Superdial+macro