<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Arial,Helvetica,sans-serif;" dir="ltr">
<p><span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">Actually, I solved my problem accessing the file
</span><span style="color: rgb(34, 34, 34); font-size: 12pt; font-family: Calibri, Arial, Helvetica, sans-serif;">/etc/systemd/system/</span><span class="m_8867663118424613602gmail-skimlinks-unlinked" style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;"><span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">multi-</span><wbr><span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">user.target.wants/freeswitch.</span><wbr><span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">service,
adding this parameters:<br>
</span></span><span class="m_8867663118424613602gmail-skimlinks-unlinked" style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;"><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">TimeoutSec=45s</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">Restart=always</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">; exec</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">WorkingDirectory=/run/</span><wbr><span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">freeswitch</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">User=freeswitch</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">Group=daemon</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">LimitCORE=infinity</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">LimitNOFILE=100000</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">LimitNPROC=60000</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">;LimitSTACK=240</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">LimitRTPRIO=infinity</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">LimitRTTIME=7000000</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">IOSchedulingClass=realtime</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">IOSchedulingPriority=2</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">CPUSchedulingPolicy=rr</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">CPUSchedulingPriority=89</span><br>
<span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">UMask=0007</span></span></p>
<p><span class="m_8867663118424613602gmail-skimlinks-unlinked" style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;"><span style="font-family: Calibri, Arial, Helvetica, sans-serif;"><br>
</span></span></p>
<p><span class="m_8867663118424613602gmail-skimlinks-unlinked" style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8px;"><span style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;">Thanks.</span></span></p>
<br>
<br>
<div style="color: rgb(0, 0, 0);">
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> freeswitch-users-bounces@lists.freeswitch.org <freeswitch-users-bounces@lists.freeswitch.org> on behalf of Brian West <brian@freeswitch.org><br>
<b>Sent:</b> Tuesday, December 6, 2016 1:10 PM<br>
<b>To:</b> FreeSWITCH Users Help<br>
<b>Subject:</b> Re: [Freeswitch-users] Socket Error [Too many open files]</font>
<div> </div>
</div>
<div>
<div dir="ltr">Depends on how your system is setup, Can you execute this at fs_cli: system ulimit -a</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Tue, Dec 6, 2016 at 9:54 AM, Colin Morelli <span dir="ltr">
<<a href="mailto:colin.morelli@gmail.com" target="_blank">colin.morelli@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
<div dir="ltr">When you say "I set the configuration below" - did you set this by executing the ulimit command or by editing /etc/security/limits.conf (or the equivalent for your distro)? IIRC the ulimit commands only change the limits for the current shell
and its children. Depending on how FS is launched, it may very well not be a child of the current shell (or it's forking off as a different user), and as such those limits aren't applying.
<div><br>
</div>
<div>You can run "cat /proc/FS_PID/limits" to see the actual limits imposed on the FS process(es)</div>
<div><br>
</div>
<div>Best,</div>
<div>Colin</div>
</div>
<div class="HOEnZb">
<div class="h5">
<div class="gmail_extra"><br>
<div class="gmail_quote">On Tue, Dec 6, 2016 at 9:48 AM, Brian West <span dir="ltr">
<<a href="mailto:brian@freeswitch.org" target="_blank">brian@freeswitch.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
<div dir="ltr">I can only guess you've done something or are using something that isn't closing the FD, Can you elaborate on what kinds of elements you have in your call flow? Conference, files, lua or some other scripts that might access files?
<div><br>
</div>
<div>/b</div>
<div><br>
</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">
<div>
<div class="m_3873702434185394474h5">On Tue, Dec 6, 2016 at 9:44 AM, Caio Assis <span dir="ltr">
<<a href="mailto:caioebassis@hotmail.com" target="_blank">caioebassis@hotmail.com</a>></span> wrote:<br>
</div>
</div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
<div>
<div class="m_3873702434185394474h5">
<div dir="ltr">
<div id="m_3873702434185394474m_-3275391496874113167m_7626522348722027534divtagdefaultwrapper" dir="ltr">
<p style="color:rgb(0,0,0); font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">Good afternoon.</span></p>
<p style="color:rgb(0,0,0); font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
<br>
</p>
<p style="color:rgb(0,0,0); font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt">
Freeswitch info:</p>
<p><span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">Freeswitch version: Version 1.6.12 64bit</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">O.S: Centos 7</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">Processor: Xeon Six Core</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">RAM: 8GB</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">Disk: SSD samsung 850 pro</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">I've been facing a problem with freeswitch.</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">When I generate many calls (around 300 calls), Freeswitch service stops receiving socket connection after this error:</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">[ERR] mod_event_socket.c:3017 Error initilizing connection</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">[CRIT] mod_event_socket.c:235 Stateful Listener 0 has expired</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">[ERR] mod_event_socket.c:2975 Socket Error [Too many open files]</span><br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<br style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">
<span style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px">I set the configuration below, but the problem persists and I have to restart the service to get it back up.</span></p>
<div>
<pre style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px; white-space:pre-wrap">ulimit -c unlimited # The maximum size of core files created.
ulimit -d unlimited # The maximum size of a process's data segment.
ulimit -f unlimited # The maximum size of files created by the shell (default option)
ulimit -i unlimited # The maximum number of pending signals
ulimit -n 999999 # The maximum number of open file descriptors.
ulimit -q unlimited # The maximum POSIX message queue size
ulimit -u unlimited # The maximum number of processes available to a single user.
ulimit -v unlimited # The maximum amount of virtual memory available to the process.
ulimit -x unlimited # ???
ulimit -s 240 # The maximum stack size
ulimit -l unlimited # The maximum size that may be locked into memory.
ulimit -a # All current limits are reported.</pre>
<pre style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px; white-space:pre-wrap"><br></pre>
<pre style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px; white-space:pre-wrap">I can't execute any freeswitch command, fs_cli -x "show calls", fs_cli -r, they all return that socket error.</pre>
<pre style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px; white-space:pre-wrap"><br></pre>
<pre style="color:rgb(34,34,34); font-family:arial,sans-serif; font-size:12.8px; white-space:pre-wrap">Thanks.</pre>
</div>
<p></p>
</div>
</div>
<br>
</div>
</div>
______________________________<wbr>______________________________<wbr>_____________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org" target="_blank">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions<wbr>.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.o<wbr>rg</a><br>
<a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswi<wbr>tch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/ma<wbr>ilman/listinfo/freeswitch-user<wbr>s</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.frees<wbr>witch.org/mailman/options/free<wbr>switch-users</a><br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
</blockquote>
</div>
<br>
<br clear="all">
<div><br>
</div>
-- <br>
<div class="m_3873702434185394474m_-3275391496874113167gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<p><font face="courier new, monospace"><b><i><font size="4">Brian West</font></i></b><br>
<span style="font-size:x-small"><a href="mailto:brian@freeswitch.org" target="_blank">brian@freeswitch.org</a></span></font></p>
<p><font size="1" face="courier new, monospace"><img style="user-select: none;" src="http://billing.freeswitch.org/templates/default/img/whmcslogo.png"><br>
</font></p>
<p><font size="2" face="monospace, monospace"><b><i>Twitter: @FreeSWITCH , @briankwest</i></b><br>
<a href="http://www.freeswitchbook.com" target="_blank">http://www.freeswitchbook.com</a> <wbr>(50% Discount using code FreeSwitch50)<br>
<a href="http://www.freeswitchcookbook.com" target="_blank">http://www.freeswitchcookbook.<wbr>com</a> </font><span style="font-family:monospace,monospace; font-size:small">(50% Discount using code FreeSwitch50)</span><font size="2" face="monospace, monospace"><br>
</font><a href="https://www.gofundme.com/freeswitch_ubuntu" target="_blank" style="font-size:12.8px"><font face="monospace, monospace">https://www.gofundme.com/frees<wbr>witch_ubuntu</font></a></p>
<p><font face="monospace, monospace">Got Bugs? Report them <a href="https://freeswitch.org/jira" target="_blank">
here</a>! | Reddit: <a href="https://www.reddit.com/r/freeswitch" target="_blank">/r/freeswitch</a></font></p>
<p><font size="2" face="monospace, monospace"><b>T:</b><a href="tel:(918)%20420-9001" value="+19184209001" target="_blank">+19184209001</a> |
<b>F:</b><a href="tel:(918)%20420-9002" value="+19184209002" target="_blank">+19184209002</a> |
<b>M:</b>+1918424WEST (9378)<br>
<b>iNUM:</b>+883 5100 1420 9001 | <b>ISN:</b>410*543 | <b>Skype:</b>briankwest</font></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<br>
______________________________<wbr>______________________________<wbr>_____________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org" target="_blank">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions<wbr>.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.o<wbr>rg</a><br>
<a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswi<wbr>tch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/ma<wbr>ilman/listinfo/freeswitch-user<wbr>s</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.frees<wbr>witch.org/mailman/options/<wbr>freeswitch-users</a><br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
</blockquote>
</div>
<br>
</div>
</div>
</div>
<br>
______________________________<wbr>______________________________<wbr>_____________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.<wbr>freeswitchsolutions.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.<wbr>org</a><br>
<a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.<wbr>freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/<wbr>mailman/listinfo/freeswitch-<wbr>users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.<wbr>freeswitch.org/mailman/<wbr>options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
</blockquote>
</div>
<br>
<br clear="all">
<div><br>
</div>
-- <br>
<div class="gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<p><font face="courier new, monospace"><b><i><font size="4">Brian West</font></i></b><br>
<span style="font-size:x-small"><a href="mailto:brian@freeswitch.org" target="_blank">brian@freeswitch.org</a></span></font></p>
<p><font size="1" face="courier new, monospace"><img style="user-select: none;" src="http://billing.freeswitch.org/templates/default/img/whmcslogo.png"><br>
</font></p>
<p><font size="2" face="monospace, monospace"><b><i>Twitter: @FreeSWITCH , @briankwest</i></b><br>
<a href="http://www.freeswitchbook.com" target="_blank">http://www.freeswitchbook.com</a> (50% Discount using code FreeSwitch50)<br>
<a href="http://www.freeswitchcookbook.com" target="_blank">http://www.freeswitchcookbook.com</a> </font><span style="font-family:monospace,monospace; font-size:small">(50% Discount using code FreeSwitch50)</span><font size="2" face="monospace, monospace"><br>
</font><a href="https://www.gofundme.com/freeswitch_ubuntu" target="_blank" style="font-size:12.8px"><font face="monospace, monospace">https://www.gofundme.com/freeswitch_ubuntu</font></a></p>
<p><font face="monospace, monospace">Got Bugs? Report them <a href="https://freeswitch.org/jira" target="_blank">
here</a>! | Reddit: <a href="https://www.reddit.com/r/freeswitch" target="_blank">/r/freeswitch</a></font></p>
<p><font size="2" face="monospace, monospace"><b>T:</b>+19184209001 | <b>F:</b>+19184209002 |
<b>M:</b>+1918424WEST (9378)<br>
<b>iNUM:</b>+883 5100 1420 9001 | <b>ISN:</b>410*543 | <b>Skype:</b>briankwest</font></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>