[OpenSIPS-Users] permissions module: subnet_table_insert: subnet table is full

2013-05-23 Thread Carlos Oliva
Hello:

I'm Using Opensips-1.6.4 with permissions module to classify clients in
different groups depending of the source IP. Everything works fine but
today, after inserting a new subnet in table address and doing opensipsctl
address reload i saw in the log the message:

CRITICAL:permissions:subnet_table_insert: subnet table is full

In address table I have 178 hosts (mask 32) and 129 networks (mask != 32)

Doing opensipsctl fifo address_dump y saw 178 host entries (all OK), but
doing the command opensipsctl fifo subnet_dump shows only 128 entries.

Checking the sources I saw the filter in hash.c

count = table[PERM_MAX_SUBNETS].grp;

if (count == PERM_MAX_SUBNETS) {
LM_CRIT(subnet table is full\n);
return 0;
}

and the value of PERM_MAX_SUBNETS in hash.h is 128

I didn't found anything about this limit in module Readme.

Looking at sources of 1.8.3 seems to have the same limit (#define
PERM_MAX_SUBNETS 128 in hash.h)

My questions are:

¿Is this networks limit real? ¿Can I increase it? ¿how?


Thanks

Carlos Oliva
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] permissions module: subnet_table_insert: subnet table is full

2013-05-23 Thread Saúl Ibarra Corretgé

On May 23, 2013, at 10:24 AM, Carlos Oliva wrote:

 Hello:
 
 I'm Using Opensips-1.6.4 with permissions module to classify clients in 
 different groups depending of the source IP. Everything works fine but today, 
 after inserting a new subnet in table address and doing opensipsctl address 
 reload i saw in the log the message:
 
 CRITICAL:permissions:subnet_table_insert: subnet table is full
 
 In address table I have 178 hosts (mask 32) and 129 networks (mask != 32)
 
 Doing opensipsctl fifo address_dump y saw 178 host entries (all OK), but 
 doing the command opensipsctl fifo subnet_dump shows only 128 entries.
 
 Checking the sources I saw the filter in hash.c
 
 count = table[PERM_MAX_SUBNETS].grp;
 
 if (count == PERM_MAX_SUBNETS) {
 LM_CRIT(subnet table is full\n);
 return 0;
 }
 
 and the value of PERM_MAX_SUBNETS in hash.h is 128 
 
 I didn't found anything about this limit in module Readme.
 
 Looking at sources of 1.8.3 seems to have the same limit (#define 
 PERM_MAX_SUBNETS 128 in hash.h)
 
 My questions are:
 
 ¿Is this networks limit real? ¿Can I increase it? ¿how?
 

I feel your pain, I hate compile time limitations with a passion. Right now the 
only way around is to modify that define to a higher value and recompile. FWIW 
I increased it to an absurdly high value (1 IIRC) and that did the job.

--
Saúl Ibarra Corretgé
AG Projects




___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users