<p dir="ltr">Well I understand but what I observe is that JACK has unpredictable amount of total clients which is an issue, regardless if it's closer to 10 than 1000.</p>
<p dir="ltr">I have found out at least 3 conditions that affect this:</p>
<p dir="ltr">- compilation flags, which by the way may cause jack to segfault if they are set too high</p>
<p dir="ltr">- parameter to jackd</p>
<p dir="ltr">- MAX_SHM_ID</p>
<p dir="ltr">I suggest integrating this into one runtime command line parameter. </p>
<p dir="ltr">M. </p>
<div class="gmail_quote">09.06.2016 1:39 PM "Paul Davis" <<a href="mailto:paul@linuxaudiosystems.com">paul@linuxaudiosystems.com</a>> napisał(a):<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>shared memory is not a very malleable resource. you can't just arbitrarily increase the size of it like you can with heap memory. <br><br></div>But running 250 JACK clients is not a viable workflow either. It doesn't scale in that way unless you're not interested in latency, in which case use PulseAudio.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jun 9, 2016 at 6:32 AM, <a href="mailto:marcin@saepia.net" target="_blank">marcin@saepia.net</a> <span dir="ltr"><<a href="mailto:marcin@saepia.net" target="_blank">marcin@saepia.net</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"><div><div><div><div>Hello,<br><br></div>I've found a piece of code that can be responsible for this:<br><br>#<span>define</span> <span>MAX_SHM_ID</span> <span>256</span> <span><br><br></span></div><span>This is used to determine size of the registry.<br><br></span></div><span>What is rationale for hardcoding this like this?<span><font color="#888888"><br><br></font></span></span></div><span><font color="#888888"><span>m.<br></span></font></span></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">2016-06-09 12:02 GMT+02:00 <a href="mailto:marcin@saepia.net" target="_blank">marcin@saepia.net</a> <span dir="ltr"><<a href="mailto:marcin@saepia.net" target="_blank">marcin@saepia.net</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div>Hello,<br><br>at some point I am getting the following errors from JACK<br><br>Jun  9 11:57:19 001-can1-plumber jackd[21110]: shm registry full<br>Jun  9 11:57:19 001-can1-plumber jackd[21110]: Cannot create shared memory segment of size = 422<br>Jun  9 11:57:19 001-can1-plumber jackd[21110]: JackShmMem::new bad alloc<br>Jun  9 11:57:19 001-can1-plumber jackd[21110]: Cannot open client<br>Jun  9 11:57:19 001-can1-plumber jackd[21110]: Cannot create new client<br><br></div>Max locked memory for this process is set to 134217728 while launching JACK via systemd.<br><br></div>It effectively causes JACK to hang.<br><br></div><div>I am using 1.9.10 (commit 1ed50c92) on ubuntu 16.04.<br></div><div><br></div><div>The configure flags are --clients=500 --ports-per-application=4 (I am not reaching 500 clients limit when that occurs, they are around 250).<br></div><div><br></div><div>JACK is started with dummy driver, and --port-max set to 2000.<br><br></div>What is the reason for hitting SHM limit? Can I overcome this in any way?<span><font color="#888888"><br><br></font></span></div><span><font color="#888888">m.<br></font></span></div>
</blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
Jack-Devel mailing list<br>
<a href="mailto:Jack-Devel@lists.jackaudio.org" target="_blank">Jack-Devel@lists.jackaudio.org</a><br>
<a href="http://lists.jackaudio.org/listinfo.cgi/jack-devel-jackaudio.org" rel="noreferrer" target="_blank">http://lists.jackaudio.org/listinfo.cgi/jack-devel-jackaudio.org</a><br>
<br></blockquote></div><br></div>
</blockquote></div>