<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
</head>
<body class='hmmessage'><div dir='ltr'>
<br>



<div><style>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:Tahoma;}

</style>

<div dir="ltr">
<br>



<div><style>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:Tahoma;}
</style>

<div dir="ltr">


<style>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:Tahoma;}
</style>
<div dir="ltr">

<style>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:Tahoma;}
</style>
<div dir="ltr">Thanks Juha<br>I populated the lcr tables by hand. This is how they look now, I have 2 lcr_ids [1 and 2], each instance has its own gw. And each instance has its own prefix to match for [4444 and 5555].<br>The idea is that a call comes in with R-URI 444413051234567, it should match the lcr_id= 200, then it should go out using gw 192.168.169.200 etc<br><br>mysql&gt; select * from lcr_gw;<br>+----+--------+------------+-----------------+-------------------+------+--------+------------+-----------+-------+------+-------+---------+<br>| id | lcr_id | gw_name&nbsp;&nbsp;&nbsp; | ip_addr&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | hostname&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | port | params | uri_scheme | transport | strip | tag&nbsp; | flags | defunct |<br>+----+--------+------------+-----------------+-------------------+------+--------+------------+-----------+-------+------+-------+---------+<br>|&nbsp; 1 |&nbsp;&nbsp;&nbsp; 200 | switchvox&nbsp; | 192.168.169.200 | pbx1.mydomain.com | 5060 | none&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1 |&nbsp;&nbsp;&nbsp;&nbsp; 0 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp; 0 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0 |<br>|&nbsp; 2 |&nbsp;&nbsp;&nbsp; 201 | switchvox2 | 192.168.169.201 | pbx1.mydomain.net | 5060 | none&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1 |&nbsp;&nbsp;&nbsp;&nbsp; 0 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp; 0 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0 |<br>+----+--------+------------+-----------------+-------------------+------+--------+------------+-----------+-------+------+-------+---------+<br>mysql&gt; select * from lcr_rule;<br>+----+--------+--------+----------+---------+---------+<br>| id | lcr_id | prefix | from_uri | stopper | enabled |<br>+----+--------+--------+----------+---------+---------+<br>|&nbsp; 1 |&nbsp;&nbsp;&nbsp; 200 | 4444&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1 |<br>|&nbsp; 2 |&nbsp;&nbsp;&nbsp; 201 | 5555&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1 |<br>+----+--------+--------+----------+---------+---------+<br>mysql&gt; select * from lcr_rule_target;<br>+----+--------+---------+-------+----------+--------+<br>| id | lcr_id | rule_id | gw_id | priority | weight |<br>+----+--------+---------+-------+----------+--------+<br>|&nbsp; 1 |&nbsp;&nbsp;&nbsp; 200 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1 |&nbsp;&nbsp;&nbsp;&nbsp; 1 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 5 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1 |<br>|&nbsp; 2 |&nbsp;&nbsp;&nbsp; 201 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2 |&nbsp;&nbsp;&nbsp;&nbsp; 2 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 5 |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1 |<br>+----+--------+---------+-------+----------+--------+<br><br>Then I tried the sercmd commands to reload and dump and I do not see the contents o the screen. Is this how is supposed to work now?. How do I know that the new values are being loaded into memory w/o restarting kamailio?<br><br><pre><i>I am trying to port our setup from kamailio 1.4.3 to 3.1.4 and I see<br></i>&gt;<i> huge differences on the LCR module.<br></i><br>there is a script somewhere (read wiki) that upgrades the tables.<br><br>&gt;<i> I have these main questions:<br></i>&gt;<i> <br></i>&gt;<i> 1- does lcr_id replaces the grp_id?<br></i><br>not really.  lcr_ids denote independent lcr instances.<br><br>&gt;<i> 2- what happened to the fifo commands to add gws etc:<br></i><br>fifo commands to manipulate lcr tables are not supported by me.<br><br>-- juha<br></pre><br><br><div>
<div>&nbsp;</div></div><br><br><div><hr id="ecxstopSpelling">From: fborot@hotmail.com<br>To: sr-users@lists.sip-router.org<br>Subject: Questions about LCR module<br>Date: Mon, 27 Jun 2011 17:23:05 -0400<br><br>



<style>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:Tahoma;}
</style>

<div dir="ltr">
<br>I am trying to port our setup from kamailio 1.4.3 to 3.1.4 and I see huge differences on the LCR module.<br>I have these main questions:<br><br>1- does lcr_id replaces the grp_id?<br>2- what happened to the fifo commands to add gws etc:<br><br>&nbsp;lcr addgw &lt;gw_name&gt; &lt;ip&gt; &lt;port&gt; &lt;scheme&gt; &lt;transport&gt; &lt;grp_id&gt; &lt;flags&gt; &lt;tag&gt; &lt;strip&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ............... add a gateway with flags, tag and strip ............<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ................(flags, tag, and strip are optional arguments) .....<br>&nbsp;lcr rmgw&nbsp; &lt;gw_name&gt; ..........................................................<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ............... delete a gateway<br>&nbsp;lcr addroute &lt;prefix&gt; &lt;from&gt; &lt;grp_id&gt; &lt;prio&gt; .................................<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; .............. add a route ( use '' to match anything in &lt;from&gt; )<br>&nbsp;lcr rmroute&nbsp; &lt;prefix&gt; &lt;from&gt; &lt;grp_id&gt; &lt;prio&gt; .................................<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; .............. delete a route<br><br><br>3- it looks like the kamctl fifo lcr reload can not be used anymore, instead I found that there is a sercmd command that can be used to "show" and "reload"&nbsp; only the lcr tables<br><br>What would be the best way to use this module on this version?<br><br>Any help/hint would be greatly appreciated.<br>thank you<br><br>fborot<br><br><br><br><br><div>
<div>&nbsp;</div></div>                                               </div></div></div></div>                                               </div></div>                                               </div></div>                                               </div></body>
</html>