[Serusers] LCR question

Steve Blair blairs at isc.upenn.edu
Fri Sep 8 19:49:38 CEST 2006



Juha Heinanen wrote:

>Steve Blair writes:
>
> > I would like to use LCR so that outbound calls from my domain may try 
> > one of several gateways in sequence. The callers (from uri) will not be 
> > authenticated or registered to the proxy doing the LCR. Will LCR work in 
> > this type of environment? A few test calls have failed so far.
>
>i don't see any reason why lcr module would not work for you.  you just
>define from_uri so that it matches everything.
>
>  
>
In the lcr table from_uri field I use the "%" wildcard character to 
indicate any from uri. I also have the following code fragment in route 
block 0.

     if (!load_gws()) {
          sl_send_reply("500", "Server Internal Error - Cannot load 
gateways");
          return;
       } else {
          xlog("L_INFO", "\n[SER]: Load Gateways passed\n");
       };

       t_on_failure("2");          # if gateway unavail go to 4
       xlog("L_INFO", "\n[SER] : Relay to first gateway\n");
       t_relay();

failure_route[2] {
      xlog("L_INFO", "\n[SER]: Unavailable Gateway. \n");
    if (!next_gw()) {
        xlog("L_CRIT","No more gateways\n");
        t_reply("503", "Service not available - No more gateways");
        return;
    } else {
        t_on_failure("4");
        t_relay();
        return;
    }
}

>-- juha
>
>  
>

-- 
  
ISC Network Engineering
The University of Pennsylvania
3401 Walnut Street, Suite 221A
Philadelphia, PA 19104  


voice: 215-573-8396 

       215-746-8001

fax: 215-898-9348    

sip:blairs at net.isc.upenn.edu




More information about the sr-users mailing list