[Users] Openser- parser error for openser.cfg

Bogdan-Andrei Iancu bogdan at voice-system.ro
Fri Feb 16 13:06:01 CET 2007


Hi,

the syntax of forward() changed in 1.1.x. See:
    
http://openser.org/dokuwiki/doku.php/core-cookbook:1.1.x#forward_destination

you should do:

forward_tcp(4.4.4.4, 5060); => forward("tpc:4.4.4.4:5060");
forward_udp(1.1.1.1, 5060); => forward("udp:1.1.1.1:5060");

regards,
bogdan

K Biju wrote:
> Hi All,
>
> I have installed openser version 1.1.1-notls(i386/linux).
> I am trying to configure the openser to route all calls to a gateway. 
> For this I have added the following rules in openser.cfg
> route { 
>        if (!mf_process_maxfwd_header("10")) { 
>                sl_send_reply("483","Too Many Hops"); 
>                break; 
>        } 
>        record_route(); 
>        if (src_ip==1.1.1.1) { 
>                forward_tcp(4.4.4.4, 5060); 
>        } 
>        else { 
>                forward_udp(1.1.1.1, 5060); 
>        } 
> } 
>
> Now when I bring up the server I get the following error
> [root at localhost openser-1.1.1-notls]# /usr/local/sbin/openser -n 1 -ddddd -E -l tcp:47.100.105.195:5060
>
>  -l
> udp:47.100.105.195:5060
> 0(18381) read 3133282016 from /dev/urandom
> 0(18381) seeding PRNG with 9917133
> 0(18381) test random number 521145638
> 0(18381) parse error (27,46-50): parse error
> 0(18381) parse error (27,50-51): bad arguments
> 0(18381) parse error (30,28-29): parse error
> 0(18381) parse error (30,41-42): bad arguments
> ERROR: bad config file (4 errors)
>
> What is wrong with the syntax or am I missing any modules ?
>
> Thanks in advance
> -Biju
>
> ------------------------------------------------------------------------
> Need Mail bonding?
> Go to the Yahoo! Mail Q&A 
> <http://answers.yahoo.com/dir/index;_ylc=X3oDMTFvbGNhMGE3BF9TAzM5NjU0NTEwOARfcwMzOTY1NDUxMDMEc2VjA21haWxfdGFnbGluZQRzbGsDbWFpbF90YWcx?link=ask&sid=396546091> 
> for great tips from Yahoo! Answers 
> <http://answers.yahoo.com/dir/index;_ylc=X3oDMTFvbGNhMGE3BF9TAzM5NjU0NTEwOARfcwMzOTY1NDUxMDMEc2VjA21haWxfdGFnbGluZQRzbGsDbWFpbF90YWcx?link=ask&sid=396546091> 
> users.
> ------------------------------------------------------------------------
>
> _______________________________________________
> Users mailing list
> Users at openser.org
> http://openser.org/cgi-bin/mailman/listinfo/users
>   





More information about the Users mailing list