[SR-Users] implemented specifiers not processed

Daniel-Constantin Mierla miconda at gmail.com
Mon Nov 11 08:54:14 CET 2013


Hello,

you are using the (old) SER-style specfiers. There are two options:
- replace % with %, load pv and xlog modules, replace selects @name with 
$sel(name), avps with $avp(name)
- use xprint module and replace xlog() with appropriate new function name

Cheers,
Daniel

On 11/10/13 1:01 PM, Oliver Roth wrote:
>
> Hi all
>
> Having some problems with the following part of the script in a timer:
>
> We have some kamailios running doing more or less the same job -- they 
> are used by a loadbalancer kamailio.
>
> Actually I wanted to check the ip or systemname of the current system 
> do perform some actions depending on the used kamailio -- based on a 
> timer
>
> route[CDRS] {
>
> sql_query("ca","call kamailio_cdrs()","rb");
>
> sql_query("ca","call kamailio_rating()","rb");
>
> xlog("timer routine: time is %TF\n");
>
> xlog("L_ERR", "time [%Tf] method <%rm> r-uri <%ru> 2nd via 
> <%{via[1]}>\n");
>
> xlog("L_INFO", "CDRS- rated Host %Hi");
>
> if %Hi = ipOfGateway1 then do something
>
>                 else if %Hi = ipOfGateway2 then do something different
>
> }
>
> What I get in log
>
> Nov 10 12:54:12 sipgw21 /usr/sbin/kamailio[16231]: ERROR: <script>: 
> timer routine: time is %TF
>
> Nov 10 12:54:12 sipgw21 /usr/sbin/kamailio[16231]: ERROR: <script>: 
> time [%Tf] method <%rm> r-uri <%ru> 2nd via <%{via[1]}>
>
> Nov 10 12:54:24 sipgw21 /usr/sbin/kamailio[16231]: INFO: <script>: 
> CDRS- rated Host %Hi
>
> The %-variables are not processed ... what am I doing wrong??
>
> Thanks
>
> Oli
>
>
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla - http://www.asipto.com
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio Advanced Trainings - Berlin, Nov 25-28
   - more details about Kamailio trainings at http://www.asipto.com -

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20131111/d09f2b00/attachment.html>


More information about the sr-users mailing list