If i call a mobil number: t: sip:+4917625251111@sip.heissa.de.
i get 404, but would expect rewrite to carrier route: sip:+4917625251111@sip.nexxtmobile.de Is there a way to print out all variables at this moment?
########################################################### if ( is_method("ACK") ) { if ( t_check_trans() ) { # no loose-route, but stateful ACK; # must be an ACK after a 487 # or e.g. 404 from upstream server route(RELAY); exit; } else { # ACK without matching transaction ... ignore and discard exit; } } sl_send_reply("404", "Not here"); #How to print out all variables in case we reach this line??? exit; ###########################################################
If i call a mobil number: t: sip:+4917625251111@sip.heissa.de.
i get 404, but would expect rewrite to carrier route: sip:+4917625251111@sip.nexxtmobile.de Is there a way to print out all variables at this moment?
########################################################### if ( is_method("ACK") ) { if ( t_check_trans() ) { # no loose-route, but stateful ACK; # must be an ACK after a 487 # or e.g. 404 from upstream server route(RELAY); exit; } else { # ACK without matching transaction ... ignore and discard exit; } } sl_send_reply("404", "Not here"); #How to print out all variables in case we reach this line??? exit; ###########################################################
Hi all, if i use xlog (Version 5.0.1) to print out some variables: xlog("L_NOTICE", "$fU time [$Tf] method ($rm) r-uri ($ru) 2nd via ($hdr(via[1]))\n");
I get: Apr 16 10:22:51 sip kamailio: DEBUG: <core> [core/route_struct.c:524]: print_action(): , "L_NOTICE"
Is that the expected result?
Best regards Georg
This sounds like you have debug=3 or higher, and so are seeing debug statements related to the internals of logging itself, in addition to the log entry.
I suggest you set debug=2 and try again.
On Sun, Apr 16, 2017 at 12:34:53PM +0200, gh wrote:
Hi all, if i use xlog (Version 5.0.1) to print out some variables: xlog("L_NOTICE", "$fU time [$Tf] method ($rm) r-uri ($ru) 2nd via ($hdr(via[1]))\n");
I get: Apr 16 10:22:51 sip kamailio: DEBUG: <core> [core/route_struct.c:524]: print_action(): , "L_NOTICE"
Is that the expected result?
Best regards Georg
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
Hi Alex,
thanks but with debug=2 xlog() does not print anything.
It seems in /usr/src/kamailio-5.0.1/src/core/route_struct.c
case ACTIONS_ST work not as expected:
#######################################################
switch(t->val[2].type){ case NOSUBTYPE: break; case STRING_ST: DBG(", "%s"", ZSW(t->val[2].u.string)); break; case NUMBER_ST: DBG(", %lu",t->val[2].u.number); break; case EXPR_ST: print_expr((struct expr*)t->val[2].u.data); break; case ACTIONS_ST: print_actions((struct action*)t->val[2].u.data); break; case SOCKID_ST: #######################################################
On 16.04.2017 12:42, Alex Balashov wrote:
This sounds like you have debug=3 or higher, and so are seeing debug statements related to the internals of logging itself, in addition to the log entry.
I suggest you set debug=2 and try again.
On Sun, Apr 16, 2017 at 12:34:53PM +0200, gh wrote:
Hi all, if i use xlog (Version 5.0.1) to print out some variables: xlog("L_NOTICE", "$fU time [$Tf] method ($rm) r-uri ($ru) 2nd via ($hdr(via[1]))\n");
I get: Apr 16 10:22:51 sip kamailio: DEBUG: <core> [core/route_struct.c:524]: print_action(): , "L_NOTICE"
Is that the expected result?
Best regards Georg
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
Hello,
again, as written in the previous email, you are looking at the wrong step, which is happening in the kamailio startup process, as opposite to runtime processing.
I could bet a lot of money that when xlog() is broken, there will be a lot of reports from many people.
Have you received sip traffic in kamailio and the xlog was not printing anything? Just add an xlog() as first line inside 'request_route { ... }' and you should see it for each request received by kamailio. If not, be sure you don't have a firewall blocking sip traffic.
Cheers, Daniel
On 16.04.17 14:01, gh wrote:
Hi Alex,
thanks but with debug=2 xlog() does not print anything.
It seems in /usr/src/kamailio-5.0.1/src/core/route_struct.c
case ACTIONS_ST work not as expected:
#######################################################
switch(t->val[2].type){ case NOSUBTYPE: break; case STRING_ST: DBG(", "%s"", ZSW(t->val[2].u.string)); break; case NUMBER_ST: DBG(", %lu",t->val[2].u.number); break; case EXPR_ST: print_expr((struct expr*)t->val[2].u.data); break; case ACTIONS_ST: print_actions((struct action*)t->val[2].u.data); break; case SOCKID_ST: #######################################################
On 16.04.2017 12:42, Alex Balashov wrote:
This sounds like you have debug=3 or higher, and so are seeing debug statements related to the internals of logging itself, in addition to the log entry.
I suggest you set debug=2 and try again.
On Sun, Apr 16, 2017 at 12:34:53PM +0200, gh wrote:
Hi all, if i use xlog (Version 5.0.1) to print out some variables: xlog("L_NOTICE", "$fU time [$Tf] method ($rm) r-uri ($ru) 2nd via ($hdr(via[1]))\n");
I get: Apr 16 10:22:51 sip kamailio: DEBUG: <core> [core/route_struct.c:524]: print_action(): , "L_NOTICE"
Is that the expected result?
Best regards Georg
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
Solved!
Thanks a lot Daniel, you are right i've placed the xlog at the wrong line in kamailio.cfg.
Cheers, Georg
Hello,
again, as written in the previous email, you are looking at the wrong step, which is happening in the kamailio startup process, as opposite to runtime processing.
I could bet a lot of money that when xlog() is broken, there will be a lot of reports from many people.
Have you received sip traffic in kamailio and the xlog was not printing anything? Just add an xlog() as first line inside 'request_route { ... }' and you should see it for each request received by kamailio. If not, be sure you don't have a firewall blocking sip traffic.
Cheers, Daniel
On 16.04.17 14:01, gh wrote:
Hi Alex,
thanks but with debug=2 xlog() does not print anything.
It seems in /usr/src/kamailio-5.0.1/src/core/route_struct.c
case ACTIONS_ST work not as expected:
#######################################################
switch(t->val[2].type){ case NOSUBTYPE: break; case STRING_ST: DBG(", "%s"", ZSW(t->val[2].u.string)); break; case NUMBER_ST: DBG(", %lu",t->val[2].u.number); break; case EXPR_ST: print_expr((struct expr*)t->val[2].u.data); break; case ACTIONS_ST: print_actions((struct action*)t->val[2].u.data); break; case SOCKID_ST: #######################################################
On 16.04.2017 12:42, Alex Balashov wrote:
This sounds like you have debug=3 or higher, and so are seeing debug statements related to the internals of logging itself, in addition to the log entry.
I suggest you set debug=2 and try again.
On Sun, Apr 16, 2017 at 12:34:53PM +0200, gh wrote:
Hi all, if i use xlog (Version 5.0.1) to print out some variables: xlog("L_NOTICE", "$fU time [$Tf] method ($rm) r-uri ($ru) 2nd via ($hdr(via[1]))\n");
I get: Apr 16 10:22:51 sip kamailio: DEBUG: <core> [core/route_struct.c:524]: print_action(): , "L_NOTICE"
Is that the expected result?
Best regards Georg
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
-- Daniel-Constantin Mierla www.twitter.com/miconda -- www.linkedin.com/in/miconda Kamailio Advanced Training - May 22-24 (USA) - www.asipto.com Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
Hi Daniel, can you give me an example how to use the xlog() function/in an embedded interpreter via KEMI/ (lua) then i will try to convert my native route script.
b.t.w Thanks for KEMI, may be it will make life easier!
Hello,
see next link for a large Lua script for use with Kamailio via kemi:
- https://github.com/kamailio/kamailio/blob/master/misc/examples/kemi/kamailio...
Cheers, Daniel
On 16.04.17 15:37, gh wrote:
Hi Daniel, can you give me an example how to use the xlog() function/in an embedded interpreter via KEMI/ (lua) then i will try to convert my native route script.
b.t.w Thanks for KEMI, may be it will make life easier!
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
OK, i see you are using KSR.dbg() instead of xlog. I will try that.
Cheers, Georg
Hello,
see next link for a large Lua script for use with Kamailio via kemi:
https://github.com/kamailio/kamailio/blob/master/misc/examples/kemi/kamailio...
Cheers, Daniel
On 16.04.17 15:37, gh wrote:
Hi Daniel, can you give me an example how to use the xlog() function/in an embedded interpreter via KEMI/ (lua) then i will try to convert my native route script.
b.t.w Thanks for KEMI, may be it will make life easier!
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
-- Daniel-Constantin Mierla www.twitter.com/miconda -- www.linkedin.com/in/miconda Kamailio Advanced Training - May 22-24 (USA) - www.asipto.com Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
By the way,
in 2012 p2pnext Project was able to earn 19.500.000 Euro, see: http://cordis.europa.eu/docs/projects/cnect/7/216217/080/deliverables/001-p2...
http://cordis.europa.eu/project/rcn/85326_en.html
one small part of p2pnext was the development of SIP SIMPLE Client SDK.
I think Kamailio should also ask for EU budget because until now it's a success story :-)
Hello,
see next link for a large Lua script for use with Kamailio via kemi:
https://github.com/kamailio/kamailio/blob/master/misc/examples/kemi/kamailio...
Cheers, Daniel
On 16.04.17 15:37, gh wrote:
Hi Daniel, can you give me an example how to use the xlog() function/in an embedded interpreter via KEMI/ (lua) then i will try to convert my native route script.
b.t.w Thanks for KEMI, may be it will make life easier!
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
-- Daniel-Constantin Mierla www.twitter.com/miconda -- www.linkedin.com/in/miconda Kamailio Advanced Training - May 22-24 (USA) - www.asipto.com Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
Hello,
On 16.04.17 12:34, gh wrote:
Hi all, if i use xlog (Version 5.0.1) to print out some variables: xlog("L_NOTICE", "$fU time [$Tf] method ($rm) r-uri ($ru) 2nd via ($hdr(via[1]))\n");
I get: Apr 16 10:22:51 sip kamailio: DEBUG: <core> [core/route_struct.c:524]: print_action(): , "L_NOTICE"
this is printed at startup, when dumping the details of loading the configuration file script.
Your log message should appear when there is SIP traffic processed by kamailio.
Cheers, Daniel