<HTML>
<HEAD>
<TITLE>Re: [Freeswitch-users] Strange problem with sessions-per-second - requires hard coding - wtf?</TITLE>
</HEAD>
<BODY>
<FONT FACE="Monaco, Courier New"><SPAN STYLE='font-size:11pt'>fsctl sps NEW_LIMIT <BR>
>From fs_cli to change it while the switch is running...<BR>
<BR>
<BR>
<BR>
<BR>
On 10/30/12 8:16 AM, &quot;Muhammad Bhatti&quot; &lt;<a href="nbhatti@gmail.com">nbhatti@gmail.com</a>&gt; wrote:<BR>
<BR>
</SPAN></FONT><BLOCKQUOTE><FONT FACE="Monaco, Courier New"><SPAN STYLE='font-size:11pt'><BR>
Did you restart FreeSWITCH after changing this param in switch.conf?<BR>
<BR>
</SPAN></FONT><FONT FACE="Helvetica, Verdana, Arial"><SPAN STYLE='font-size:12pt'><BR>
Thanks,<BR>
--<BR>
Muhammad Naseer Bhatti<BR>
<BR>
</SPAN></FONT><FONT FACE="Monaco, Courier New"><SPAN STYLE='font-size:11pt'><BR>
<BR>
On Oct 30, 2012, at 7:43 AM, &quot;Cal Leeming [Simplicity Media Ltd]&quot; &lt;<a href="cal.leeming@simplicitymedialtd.co.uk">cal.leeming@simplicitymedialtd.co.uk</a>&gt; wrote:<BR>
<BR>
</SPAN></FONT><BLOCKQUOTE><FONT FACE="Monaco, Courier New"><SPAN STYLE='font-size:11pt'>Hello all,<BR>
<BR>
Attempting to increase 'sessions-per-second' to 100 does not appear to make any difference.<BR>
<BR>
Inside switch.conf, I have the following;<BR>
<BR>
&lt;param name=&quot;max-sessions&quot; value=&quot;1000&quot;/&gt;<BR>
&lt;param name=&quot;sessions-per-second&quot; value=&quot;100&quot;/&gt;<BR>
<BR>
And yet for some reason, I still get this;<BR>
2012-10-30 04:20:22.205003 [CRIT] switch_core_session.c:2038 Throttle Error! 99<BR>
2012-10-30 04:20:22.224956 [CRIT] switch_core_session.c:2038 Throttle Error! 99<BR>
2012-10-30 04:20:22.244981 [CRIT] switch_core_session.c:2038 Throttle Error! 99<BR>
2012-10-30 04:20:22.265109 [CRIT] switch_core_session.c:2038 Throttle Error! 99<BR>
2012-10-30 04:20:22.309297 [CRIT] switch_time.c:997 Over Session Rate of 30!<BR>
<BR>
Which then eventually leads to this;<BR>
<BR>
2012-10-30 04:29:42.284991 [CRIT] switch_time.c:997 Over Session Rate of 30!<BR>
VAL: tried to access cart in -4784 type val<BR>
<BR>
After looking through the source code, I found only a few places where this is referenced;<BR>
<BR>
./src/switch_core.c: &nbsp;&nbsp;&nbsp;runtime.sps_total = 30;<BR>
./src/switch_core.c: &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;runtime.sps_total = oldintval;<BR>
./src/switch_core.c: &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;newintval = runtime.sps_total;<BR>
./src/include/private/switch_core_pvt.h: &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;uint32_t sps_total;<BR>
./src/switch_time.c: &nbsp;&nbsp;&nbsp;runtime.sps = runtime.sps_total;<BR>
./src/switch_time.c: &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, &quot;Over Session Rate of %d!\n&quot;, runtime.sps_total);<BR>
./src/switch_time.c: &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;runtime.sps_last = runtime.sps_total - runtime.sps;<BR>
./src/switch_time.c: &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;runtime.sps = runtime.sps_total;<BR>
./src/switch_core_session.c: &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;runtime.sps_total = new_limit;<BR>
./src/switch_core_session.c: &nbsp;&nbsp;&nbsp;return runtime.sps_total;<BR>
<BR>
So for shits and giggles, I changed runtime.sps_total from 30 to 101 in the code, and low and behold it worked fine - wtf? lol.<BR>
<BR>
2012-10-30 04:42:02.084961 [CRIT] switch_core_session.c:2038 Throttle Error! 972<BR>
2012-10-30 04:42:02.084961 [CRIT] switch_core_session.c:2038 Throttle Error! 972<BR>
2012-10-30 04:42:02.104969 [CRIT] switch_time.c:997 Over Session Rate of 101!<BR>
<BR>
Does anyone know why FS seems to be ignoring the &quot;sessions-per-second&quot; value?<BR>
<BR>
Thanks<BR>
<BR>
Cal<BR>
_________________________________________________________________________<BR>
Professional FreeSWITCH Consulting Services:<BR>
<a href="consulting@freeswitch.org">consulting@freeswitch.org</a><BR>
<a href="http://www.freeswitchsolutions.com">http://www.freeswitchsolutions.com</a><BR>
<BR>
FreeSWITCH-powered IP PBX: The CudaTel Communication Server<BR>
<a href="http://www.cudatel.com">http://www.cudatel.com</a><BR>
<BR>
Official FreeSWITCH Sites<BR>
<a href="http://www.freeswitch.org">http://www.freeswitch.org</a><BR>
<a href="http://wiki.freeswitch.org">http://wiki.freeswitch.org</a><BR>
<a href="http://www.cluecon.com">http://www.cluecon.com</a><BR>
<BR>
FreeSWITCH-users mailing list<BR>
<a href="FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><BR>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><BR>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><BR>
<a href="http://www.freeswitch.org">http://www.freeswitch.org</a><BR>
</SPAN></FONT></BLOCKQUOTE><FONT FACE="Monaco, Courier New"><SPAN STYLE='font-size:11pt'><BR>
<BR>
<HR ALIGN=CENTER SIZE="3" WIDTH="95%"></SPAN></FONT><FONT SIZE="2"><FONT FACE="Consolas, Courier New, Courier"><SPAN STYLE='font-size:10pt'>_________________________________________________________________________<BR>
Professional FreeSWITCH Consulting Services:<BR>
<a href="consulting@freeswitch.org">consulting@freeswitch.org</a><BR>
<a href="http://www.freeswitchsolutions.com">http://www.freeswitchsolutions.com</a><BR>
<BR>
FreeSWITCH-powered IP PBX: The CudaTel Communication Server<BR>
<a href="http://www.cudatel.com">http://www.cudatel.com</a><BR>
<BR>
Official FreeSWITCH Sites<BR>
<a href="http://www.freeswitch.org">http://www.freeswitch.org</a><BR>
<a href="http://wiki.freeswitch.org">http://wiki.freeswitch.org</a><BR>
<a href="http://www.cluecon.com">http://www.cluecon.com</a><BR>
<BR>
FreeSWITCH-users mailing list<BR>
<a href="FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><BR>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><BR>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><BR>
<a href="http://www.freeswitch.org">http://www.freeswitch.org</a><BR>
</SPAN></FONT></FONT></BLOCKQUOTE><FONT SIZE="2"><FONT FACE="Consolas, Courier New, Courier"><SPAN STYLE='font-size:10pt'><BR>
</SPAN></FONT></FONT><FONT FACE="Monaco, Courier New"><SPAN STYLE='font-size:11pt'>-- <BR>
Ken<BR>
<FONT COLOR="#0000FF"><U><a href="http://www.FreeSWITCH.org">http://www.FreeSWITCH.org</a><BR>
<a href="http://www.ClueCon.com">http://www.ClueCon.com</a><BR>
<a href="http://www.OSTAG.org">http://www.OSTAG.org</a><BR>
</U></FONT>irc.freenode.net #freeswitch<BR>
</SPAN></FONT>
</BODY>
</HTML>