I thought that even working with realtime sip, SIP peers registration is kept in astDB (as running memory for asterisk), because I have a problem related to this - even with mysql databases synced with mysql replication, when my standby machine assumes production, none of my phones are known by the Asterisk running in the backup machine that assumes production, and so, I had to make a script to reboot all phones when the standby machine enters production so that they register with the backup server's Asterisk.
<br><br>Can this be done some other way? Is it DUNDI, regexten or regcontext usefull to avoid rebooting all phones so that they register again?<br><br>Thanks in advance,<br>Ricardo Carvalho.<br><br><br><br><br><div class="gmail_quote">
On Jan 9, 2008 9:46 AM, Johansson Olle E &lt;<a href="mailto:oej@edvina.net">oej@edvina.net</a>&gt; wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>9 jan 2008 kl. 10.42 skrev Yehavi Bourvine +972-8-9489444:<br><div><div></div><div class="Wj3C7c"><br>&gt; Hello,<br>&gt;<br>&gt; &nbsp;I know this is not a pure High Availability question, but I think<br>&gt; it is<br>&gt; related...
<br>&gt;<br>&gt; &nbsp;I would like to do &nbsp;load balancing between two Asterisk servers and<br>&gt; allow the<br>&gt; phones to use the other server as backup. Asterisk is installed on<br>&gt; both<br>&gt; systems, the users (extensions) are defined in MySQL database
<br>&gt; (realtime<br>&gt; Asterisk); the MySQL database is replicated on both systems.<br>&gt;<br>&gt; &nbsp;What I see is that only the server to which the phone registered<br>&gt; knows about<br>&gt; its location. The other server doesn&#39;t know it, and thinks that the
<br>&gt; phone is<br>&gt; offline (although I see its current address in the MySQL record).<br>&gt;<br>&gt; The realtime section of SIP.CONF is as follows:<br>&gt;<br>&gt; rtcachefriends=yes<br>&gt; rtsavesysname=yes<br>&gt; rtupdate=yes
<br>&gt; rtautoclear=yes<br>&gt; ignoreregexpire=yes<br>&gt;<br>&gt; I tried setting rtsavesysname=no but it didn&#39;t change the behaviour.<br>&gt; Any idea<br>&gt; what I am doing wrong, or how to do it?<br>&gt;<br>&gt; BTW, I tried to code &nbsp;the dialplan to check the sysname field in
<br>&gt; MySQL; if it<br>&gt; finds that the phone is on the other server then to direct the call<br>&gt; to there.<br>&gt; However, it then fails authentication (even if I set bith servers to<br>&gt; be<br>&gt; &quot;insecure&quot;) :-(
<br><br></div></div>This is why we have Dundi :-) and the regexten= parameter in channel<br>drivers.<br><br>I don&#39;t understand why you fail authentication between the servers,<br>but that&#39;s propably just<br>a configuration issue that you can solve.
<br><br>You can do a lookup in the Msyql table, since the server who receives<br>the registration will store it in the database. In newer versions of<br>Asterisk, you also have the option of storing the system name of the
<br>server, so that you can redirect the call through that server out to<br>the client. With NAT, you have to send the call from the same IP<br>address in order to reach the client.<br><font color="#888888"><br>/O<br></font>
<div><div></div><div class="Wj3C7c"><br>_______________________________________________<br>--Bandwidth and Colocation Provided by <a href="http://www.api-digital.com--" target="_blank">http://www.api-digital.com--</a><br>
<br>asterisk-ha-clustering mailing list<br>To UNSUBSCRIBE or update options visit:<br> &nbsp; <a href="http://lists.digium.com/mailman/listinfo/asterisk-ha-clustering" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-ha-clustering
</a><br></div></div></blockquote></div><br>