<div dir="ltr">In the git contrib there&#39;s /ledr/ha.d/ but it has a haresources file which isn&#39;t how I&#39;ve set up anything. Threre&#39;s a FSSofia batch file to use ESL to check if certain profile are running, but I don&#39;t get how it all fits together.<div>

I&#39;ve got the IPAddr2 but no integration into actual freeswitch.</div><div>The &quot;anything&quot; resource says it&#39;s supposed to be a bin file that keeps running, not just a script that exits.</div><div><br></div>

<div>-Avi<br><br><div class="gmail_quote">On Sun, Jan 2, 2011 at 6:27 PM, Steven Ayre <span dir="ltr">&lt;<a href="mailto:steveayre@gmail.com">steveayre@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

You would create a new fs resource agent<br>
<a href="http://www.linux-ha.org/wiki/Resource_Agents" target="_blank">http://www.linux-ha.org/wiki/Resource_Agents</a><br>
<br>
Essentially, they&#39;re programs (can be a shell script) given run with<br>
start stop etc arguments when an action needs to be done. You can run<br>
other commands such as fs_cli from there.<br>
<br>
I haven&#39;t written one from scratch myself though, I just use IPAddr2.<br>
Perhaps it would be useful for someone to create an example one in<br>
trunk or contrib?<br>
<br>
-Steve<br>
<div><div></div><div class="h5"><br>
<br>
On 2 January 2011 16:16, Avi Marcus &lt;<a href="mailto:Avi@amarcus.com">Avi@amarcus.com</a>&gt; wrote:<br>
&gt; Where would that go?<br>
&gt; /me is confused.<br>
&gt;<br>
&gt; On Sun, Jan 2, 2011 at 5:36 PM, Ghulam Mustafa &lt;<a href="http://mustafa.pk" target="_blank">mustafa.pk</a>@<a href="http://gmail.com" target="_blank">gmail.com</a>&gt; wrote:<br>
&gt;&gt;<br>
&gt;&gt; Hi, for testing purposes i modified IPaddr ocf script on both nodes<br>
&gt;&gt; and added following line at the end of start_ipaddr.<br>
&gt;&gt; /opt/switch/bin/fs_cli -x &quot;sofia recover&quot;<br>
&gt;&gt;<br>
&gt;&gt; On 1/2/11, Steven Ayre &lt;<a href="mailto:steveayre@gmail.com">steveayre@gmail.com</a>&gt; wrote:<br>
&gt;&gt; &gt; It&#39;s an API command that you can run via ESL. You can do that from a<br>
&gt;&gt; &gt; script using fs_cli and its -x/--execute option.<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; Something like this:<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; fs_cli --host=otherhost --password=secretpasswd --execute=&quot;sofia<br>
&gt;&gt; &gt; recover&quot;<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; -Steve<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; On 2 January 2011 09:43, Avi Marcus &lt;<a href="mailto:Avi@amarcus.com">Avi@amarcus.com</a>&gt; wrote:<br>
&gt;&gt; &gt;&gt; Thanks, I noticed the -nonat already.<br>
&gt;&gt; &gt;&gt; What do you mean by running sofia recover from my init script? I<br>
&gt;&gt; &gt;&gt; don&#39;t understand how that would be triggered by heartbeat/pacemaker.<br>
&gt;&gt; &gt;&gt; Any<br>
&gt;&gt; &gt;&gt; explanatory docs on the issue would be nice, but everything I&#39;ve seen<br>
&gt;&gt; &gt;&gt; was<br>
&gt;&gt; &gt;&gt; explaining exact parts and nothing ever seemed to explain the general<br>
&gt;&gt; &gt;&gt; syntax<br>
&gt;&gt; &gt;&gt; of everything.<br>
&gt;&gt; &gt;&gt; Does anyone have a working example that they can wikify and explain?<br>
&gt;&gt; &gt;&gt; Thanks,<br>
&gt;&gt; &gt;&gt; Avi<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; On Sun, Jan 2, 2011 at 4:06 AM, Seven Du &lt;<a href="mailto:dujinfang@gmail.com">dujinfang@gmail.com</a>&gt; wrote:<br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt; the wiki page already said you can start the spare FS ahead to speed<br>
&gt;&gt; &gt;&gt;&gt; switch over up.<br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt; it means if you use ip_nonlocal_bind and start the spare FS ahead, you<br>
&gt;&gt; &gt;&gt;&gt; only need to run sofia recover in you init script without waiting for<br>
&gt;&gt; &gt;&gt;&gt; the actually FS start process.<br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt; On Sun, Jan 2, 2011 at 7:58 AM, Steven Ayre &lt;<a href="mailto:steveayre@gmail.com">steveayre@gmail.com</a>&gt;<br>
&gt;&gt; &gt;&gt;&gt; wrote:<br>
&gt;&gt; &gt;&gt;&gt; &gt; 1) It seems freeswitch takes 8 seconds to restart. So if it crashes<br>
&gt;&gt; &gt;&gt;&gt; &gt; (unlikely) calls should immediately get shunted over to the other<br>
&gt;&gt; &gt;&gt;&gt; &gt; box.<br>
&gt;&gt; &gt;&gt;&gt; &gt; How<br>
&gt;&gt; &gt;&gt;&gt; &gt; do I set that up?<br>
&gt;&gt; &gt;&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;&gt; &gt; Just a tip, I start fs with -nonat and find that makes it start<br>
&gt;&gt; &gt;&gt;&gt; &gt; faster.<br>
&gt;&gt; &gt;&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;&gt; &gt; Steve on iPhone<br>
&gt;&gt; &gt;&gt;&gt; &gt; On 1 Jan 2011, at 20:20, Avi Marcus &lt;Avi@aMarcus.com&gt; wrote:<br>
&gt;&gt; &gt;&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;&gt; &gt; Hi - I&#39;m setting up 2 parallel computers for a HA setup. (low volume<br>
&gt;&gt; &gt;&gt;&gt; &gt; so<br>
&gt;&gt; &gt;&gt;&gt; &gt; far,<br>
&gt;&gt; &gt;&gt;&gt; &gt; no need to load balance.)<br>
&gt;&gt; &gt;&gt;&gt; &gt; I already have heartbeat able to grab the public IP if the first box<br>
&gt;&gt; &gt;&gt;&gt; &gt; goes<br>
&gt;&gt; &gt;&gt;&gt; &gt; down, but since I&#39;m basically completely unfamiar with pacemaker,<br>
&gt;&gt; &gt;&gt;&gt; &gt; I&#39;d<br>
&gt;&gt; &gt;&gt;&gt; &gt; like<br>
&gt;&gt; &gt;&gt;&gt; &gt; some help.<br>
&gt;&gt; &gt;&gt;&gt; &gt; I&#39;d imagine I&#39;m not the only one doing this, there should be no<br>
&gt;&gt; &gt;&gt;&gt; &gt; reason<br>
&gt;&gt; &gt;&gt;&gt; &gt; for<br>
&gt;&gt; &gt;&gt;&gt; &gt; me to recreate the wheel.<br>
&gt;&gt; &gt;&gt;&gt; &gt; Info should be on: <a href="http://wiki.freeswitch.org/wiki/Freeswitch_HA" target="_blank">http://wiki.freeswitch.org/wiki/Freeswitch_HA</a><br>
&gt;&gt; &gt;&gt;&gt; &gt; Specifically:<br>
&gt;&gt; &gt;&gt;&gt; &gt; 1) It seems freeswitch takes 8 seconds to restart. So if it crashes<br>
&gt;&gt; &gt;&gt;&gt; &gt; (unlikely) calls should immediately get shunted over to the other<br>
&gt;&gt; &gt;&gt;&gt; &gt; box.<br>
&gt;&gt; &gt;&gt;&gt; &gt; How<br>
&gt;&gt; &gt;&gt;&gt; &gt; do I set that up?<br>
&gt;&gt; &gt;&gt;&gt; &gt; 2) How do I automatically trigger a sofia recover? I know via<br>
&gt;&gt; &gt;&gt;&gt; &gt; commanline<br>
&gt;&gt; &gt;&gt;&gt; &gt; it&#39;s &quot;fs_cli -x &quot;sofia recover&quot; but where do I tell pacemaker to do<br>
&gt;&gt; &gt;&gt;&gt; &gt; that?<br>
&gt;&gt; &gt;&gt;&gt; &gt; And I suppose a reload_xml before (maybe after?) is a good idea,<br>
&gt;&gt; &gt;&gt;&gt; &gt; too.<br>
&gt;&gt; &gt;&gt;&gt; &gt; Also, can I put &lt;param name=&quot;track-calls&quot; value=&quot;true&quot;/&gt; in a global<br>
&gt;&gt; &gt;&gt;&gt; &gt; file,<br>
&gt;&gt; &gt;&gt;&gt; &gt; or does it need to be in the actual profile files?<br>
&gt;&gt; &gt;&gt;&gt; &gt; And anything else I may be overlooking.<br>
&gt;&gt; &gt;&gt;&gt; &gt; Thanks guys!<br>
&gt;&gt; &gt;&gt;&gt; &gt; -Avi Marcus<br>
&gt;&gt; &gt;&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;&gt; &gt; _______________________________________________<br>
&gt;&gt; &gt;&gt;&gt; &gt; FreeSWITCH-users mailing list<br>
&gt;&gt; &gt;&gt;&gt; &gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt;&gt; &gt;&gt;&gt; &gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt;&gt; &gt;&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;&gt; &gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt;&gt; &gt;&gt;&gt; &gt; <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
&gt;&gt; &gt;&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;&gt; &gt; _______________________________________________<br>
&gt;&gt; &gt;&gt;&gt; &gt; FreeSWITCH-users mailing list<br>
&gt;&gt; &gt;&gt;&gt; &gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt;&gt; &gt;&gt;&gt; &gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt;&gt; &gt;&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;&gt; &gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt;&gt; &gt;&gt;&gt; &gt; <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
&gt;&gt; &gt;&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt; --<br>
&gt;&gt; &gt;&gt;&gt; About: <a href="http://about.me/dujinfang" target="_blank">http://about.me/dujinfang</a><br>
&gt;&gt; &gt;&gt;&gt; Blog: <a href="http://www.dujinfang.com" target="_blank">http://www.dujinfang.com</a><br>
&gt;&gt; &gt;&gt;&gt; Proj:  <a href="http://www.freeswitch.org.cn" target="_blank">http://www.freeswitch.org.cn</a><br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt; _______________________________________________<br>
&gt;&gt; &gt;&gt;&gt; FreeSWITCH-users mailing list<br>
&gt;&gt; &gt;&gt;&gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt;&gt; &gt;&gt;&gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt;&gt; &gt;&gt;&gt;<br>
&gt;&gt; &gt;&gt;&gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt;&gt; &gt;&gt;&gt; <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; _______________________________________________<br>
&gt;&gt; &gt;&gt; FreeSWITCH-users mailing list<br>
&gt;&gt; &gt;&gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt;&gt; &gt;&gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt;&gt; &gt;&gt; <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; _______________________________________________<br>
&gt;&gt; &gt; FreeSWITCH-users mailing list<br>
&gt;&gt; &gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt;&gt; &gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt;&gt; &gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt;&gt; &gt; <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
&gt;&gt; &gt;<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; --<br>
&gt;&gt; Ghulam Mustafa<br>
&gt;&gt; cell: +92 333.611.7681<br>
&gt;&gt; sip: <a href="mailto:cyrenity@ekiga.net">cyrenity@ekiga.net</a><br>
&gt;&gt; mail: <a href="http://mustafa.pk" target="_blank">mustafa.pk</a>@<a href="http://gmail.com" target="_blank">gmail.com</a><br>
&gt;&gt; web: <a href="http://cyrenity.wordpress.com" target="_blank">cyrenity.wordpress.com</a><br>
&gt;&gt;<br>
&gt;&gt; _______________________________________________<br>
&gt;&gt; FreeSWITCH-users mailing list<br>
&gt;&gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt;&gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt;&gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt;&gt; <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
&gt;<br>
&gt;<br>
&gt; _______________________________________________<br>
&gt; FreeSWITCH-users mailing list<br>
&gt; <a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
&gt; <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
&gt; UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
&gt; <a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
&gt;<br>
&gt;<br>
<br>
_______________________________________________<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
</div></div></blockquote></div><br></div></div>