<div dir="ltr">That would be great if possible. or if you can expand auto_scaling to the whole socket=udp:* group, not per IP...</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Nov 3, 2020 at 1:11 PM Bogdan-Andrei Iancu <<a href="mailto:bogdan@opensips.org">bogdan@opensips.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Maybe we should consider (as future extension) the possibility to bundle <br>
multiple UDP listeners on the same worker. In this case, we can have a <br>
large number of listeners with a relatively small number of workers/ <br>
processes.<br>
<br>
Regards,<br>
<br>
Bogdan-Andrei Iancu<br>
<br>
OpenSIPS Founder and Developer<br>
<a href="https://www.opensips-solutions.com" rel="noreferrer" target="_blank">https://www.opensips-solutions.com</a><br>
OpenSIPS Bootcamp 2020 online<br>
<a href="https://opensips.org/training/OpenSIPS_eBootcamp_2020/" rel="noreferrer" target="_blank">https://opensips.org/training/OpenSIPS_eBootcamp_2020/</a><br>
<br>
On 11/3/20 10:10 AM, Răzvan Crainea wrote:<br>
> Hello!<br>
><br>
> No, there is no way to prevent OpenSIPS from opening connections for <br>
> each process. Did you try to start opensips with fewer workers, for <br>
> example just 1, or 3? Does it start properly?<br>
><br>
> Best regards,<br>
><br>
> Răzvan Crainea<br>
> OpenSIPS Core Developer<br>
> <a href="http://www.opensips-solutions.com" rel="noreferrer" target="_blank">http://www.opensips-solutions.com</a><br>
><br>
> On 11/2/20 1:55 PM, M S wrote:<br>
>> Thank you Bogdan. I actually use: socket=udp:*:5060 in config file.<br>
>> Is there a way to not open a process per interface, to not have 1200 <br>
>> or 600 workers? as I said in my previous email, I tried auto scaling <br>
>> and it didn't work.<br>
>> Also, I have increased MySQL max connections but it didn't fix <br>
>> the problem - I wonder if anybody has experience with this...<br>
>><br>
>> Thanks!<br>
>><br>
>> On Mon, Nov 2, 2020 at 9:24 AM Bogdan-Andrei Iancu <br>
>> <<a href="mailto:bogdan@opensips.org" target="_blank">bogdan@opensips.org</a> <mailto:<a href="mailto:bogdan@opensips.org" target="_blank">bogdan@opensips.org</a>>> wrote:<br>
>><br>
>> Hi OpenSIPer,<br>
>><br>
>> With 600 interfaces (btw , have actually listed the 600 sockets into<br>
>> the cfg or pointed the socket to the interface?) with 2 workers per<br>
>> socket -> 1200 workers / processes. That means 1200 connections to<br>
>> your DB server, which may be a bottle neck (by default, mysql<br>
>> accepts around 100 simultaneous connections).<br>
>><br>
>> I suspect your mysql server cannot cope with the 1200 conn,<br>
>> preventing OpenSIPS to properly start.<br>
>><br>
>> Regards,<br>
>><br>
>> Bogdan-Andrei Iancu<br>
>><br>
>> OpenSIPS Founder and Developer<br>
>> <a href="https://www.opensips-solutions.com" rel="noreferrer" target="_blank">https://www.opensips-solutions.com</a><br>
>> OpenSIPS Bootcamp 2020 online<br>
>> <a href="https://opensips.org/training/OpenSIPS_eBootcamp_2020/" rel="noreferrer" target="_blank">https://opensips.org/training/OpenSIPS_eBootcamp_2020/</a><br>
>><br>
>> On 11/2/20 1:23 AM, M S wrote:<br>
>>> Hi all,<br>
>>> I have a machine with 600 subinterfaces. when I start opensips<br>
>>> with 2 udp workers per interface, it doesn't start and keeps<br>
>>> restarting.<br>
>>> First error message was about too many connections to Mysql which<br>
>>> I fixed by increasing max_connections, but now I am getting:<br>
>>><br>
>>> ERROR:db_mysql:db_mysql_new_connection: initial connect failed<br>
>>> ERROR:core:db_do_init: could not add connection to the pool<br>
>>> ERROR:sql_cacher:child_init: Cannot connect to SQL DB from child<br>
>>> ERROR:core:init_mod_child: failed to initializing module<br>
>>> sql_cacher, rank 683<br>
>>> ERROR:core:send_status_code: write(-1) failed (-1): 32, Broken pipe<br>
>>> ERROR:core:udp_start_processes: failed to send -1 status code<br>
>>> ERROR:db_mysql:db_mysql_connect: driver error(2002): Can't connect<br>
>>> to local MySQL server through socket '/var/lib/mysql/mysql.sock' <br>
>>> (11)<br>
>>><br>
>>> and:<br>
>>><br>
>>> ERROR:core:send_status_code: write(-1) failed (-1): 32, Broken pipe<br>
>>> ERROR:core:udp_start_processes: failed to send -1 status code<br>
>>><br>
>>> Any ideas how I can fix this?<br>
>>> Also, can I just limit number of opensips forked processes, to run<br>
>>> just a certain number process instead of x numbers per interface?<br>
>>> I tried using auto_scaling but it did not help. in my<br>
>>> opensips.conf, I have:<br>
>>> socket=udp:*:5060<br>
>>> and adding an autoscaling profile in front of it seems to limit<br>
>>> the processes per interface again, not all...<br>
>>><br>
>>> Any help is appreciated.<br>
>>><br>
>>> Thanks!<br>
>>><br>
>>> _______________________________________________<br>
>>> Users mailing list<br>
>>> <a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a> <mailto:<a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a>><br>
>>> <a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
>><br>
>><br>
>> _______________________________________________<br>
>> Users mailing list<br>
>> <a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a><br>
>> <a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
>><br>
><br>
> _______________________________________________<br>
> Users mailing list<br>
> <a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a><br>
> <a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
<br>
<br>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a><br>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" rel="noreferrer" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
</blockquote></div>