<div dir="ltr">I have lua &#39;background&#39; script that wake up every few seconds, and check to perform specific task, one of it to established call.</div><div dir="ltr">Calls are then initiated then transfer to some extension in dialplan. The scripts has been running and works as expected.</div>
<div dir="ltr">But after session ended(hangup), channels is not released and can be seen using cli &quot;show channels&quot;. and trying to kill such channel result in &quot;-ERR No Such Channel!&quot;</div><div dir="ltr">
<br></div><div dir="ltr">This seems being reported before, but I can&#39;t seems to find any resolution.</div><div dir="ltr"><br></div><div dir="ltr">Following simple script could replicate the issues : </div><div dir="ltr">
<br></div><div dir="ltr">freeswitch&gt; luarun SimpleDialer.lua</div><div dir="ltr"><br></div><div dir="ltr">=================== SimpleDialer.lua</div><div dir="ltr"><br></div><div dir="ltr">local threadName = &quot;SimpleDialer&quot;<br>
<div><br></div><div><div>while true do                             </div><div>                                                                                                       </div>
<div>        freeswitch.consoleLog(&quot;info&quot;, threadName..&quot; ticking\n&quot;)                                                                                                    </div><div>        -- task run here</div>
<div>        local new_session = freeswitch.Session(&#39;sofia/gateway/vox/<a href="tel:%2B15085895115" value="+15085895115" target="_blank">+150</a>88888888&#39;)</div>
<div>        new_session:transfer(&quot;echo&quot;, &quot;XML&quot;, &quot;default&quot;)</div><div><br></div><div>        freeswitch.msleep(60000)</div>
<div>end</div>
</div><div><br></div><div>============= dialplan entry</div><div><br></div><div><div>    &lt;extension name=&quot;echo&quot;&gt;</div><div>      &lt;condition field=&quot;destination_number&quot; expression=&quot;^echo$&quot;&gt;</div>
<div>              &lt;action application=&quot;echo&quot; data=&quot;&quot;/&gt;</div><div>      &lt;/condition&gt;</div><div>    &lt;/extension&gt;        </div></div><div><br></div></div>