<div dir="ltr"><div>what you can try, is to call another route in the time route. <br></div><div>And then in that route, you execute the lua script. <br></div><div>maybe (just a myabe) that will work. <br></div><div><br></div><div>wkr, <br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Op do 3 dec. 2020 om 12:23 schreef Mark Allen <<a href="mailto:mark@allenclan.co.uk">mark@allenclan.co.uk</a>>:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi Johan<div><br></div><div>In the documentation for 3.1 lua module - TIMER_ROUTE is not one of the routes available to lua_exec. If I include it in a TIMER route, OpenSIPS fails to start with syntax error and the log error is:</div><div><br></div><div>    CRITICAL:core:yyerror: parse error in /etc/opensips/opensips.cfg:265:19-20: Command <lua_exec> cannot be used in the block#012<br></div><div><br></div><div>If I move the lua_exec command into main route{ it works fine</div><div><br></div><div>I also encounter the problem running a cache_remove_chunk in a TIMER route although the documentation doesn't say that it's not valid for TIMER route. It fails on startup with the error:</div><div><br></div><div>    CRITICAL:core:yyerror: parse error in /etc/opensips/opensips.cfg:266:33-34: Command <cache_remove_chunk> cannot be used in the block#012<br></div><div><br></div><div>Again - if I run the command in main route{ the command works fine</div><div><br></div><div><br></div><div>cheers,</div><div><br></div><div>Mark</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, 3 Dec 2020 at 11:01, Johan De Clercq <<a href="mailto:Johan@democon.be" target="_blank">Johan@democon.be</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"><div dir="ltr"><div>It for sure does not run in async mode. <br></div><div>Did you try executing a script in timer route ? <br></div><div>What's the output in the log ? <br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Op do 3 dec. 2020 om 11:56 schreef Mark Allen <<a href="mailto:mark@allenclan.co.uk" target="_blank">mark@allenclan.co.uk</a>>:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Is there a way to run a lua_exec from a timer route?</div>
_______________________________________________<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>
_______________________________________________<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>
_______________________________________________<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>