<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:12pt"><div style="RIGHT: auto"><SPAN style="RIGHT: auto">I have removed the order and colocation statements but I am still getting the same results.&nbsp;Asterisk keeps restarting on the same server, how can I switch to the other server when asterisk fails? I used those statements to make sure that both services are running on the same server and to make sure that the virtual IP is started before asterisk.<VAR id=yui-ie-cursor></VAR><BR style="RIGHT: auto" class=yui-cursor></SPAN></div>
<div><BR></div>
<DIV style="FONT-FAMILY: times new roman, new york, times, serif; FONT-SIZE: 12pt">
<DIV style="FONT-FAMILY: times new roman, new york, times, serif; FONT-SIZE: 12pt">
<DIV style="RIGHT: auto" dir=ltr><FONT size=2 face=Arial>----- Forwarded Message -----<BR><B><SPAN style="FONT-WEIGHT: bold">From:</SPAN></B> Jake Smith &lt;jsmith@argotec.com&gt;<BR><B><SPAN style="FONT-WEIGHT: bold">To:</SPAN></B> Tommy Cooper &lt;tomcooper83@yahoo.com&gt;; The Pacemaker cluster resource manager &lt;pacemaker@oss.clusterlabs.org&gt; <BR><B><SPAN style="FONT-WEIGHT: bold">Sent:</SPAN></B> Monday, March 4, 2013 10:00 PM<BR><B><SPAN style="FONT-WEIGHT: bold">Subject:</SPAN></B> Re: [Pacemaker] Fw: Cluster resources failing to move<BR></FONT></DIV><BR><BR>----- Original Message -----<BR>&gt; From: "Tommy Cooper" &lt;<A href="mailto:tomcooper83@yahoo.com" ymailto="mailto:tomcooper83@yahoo.com">tomcooper83@yahoo.com</A>&gt;<BR>&gt; To: <A style="RIGHT: auto" href="mailto:pacemaker@oss.clusterlabs.org" ymailto="mailto:pacemaker@oss.clusterlabs.org">pacemaker@oss.clusterlabs.org</A><BR>&gt; Sent: Monday, March 4, 2013 3:51:03 PM<BR>&gt;
 Subject: [Pacemaker] Fw:&nbsp; Cluster resources failing to move<BR>&gt; <BR>&gt; <BR>&gt; <BR>&gt; <BR>&gt; Thank you for your prompt reply. I actually wanted to create an<BR>&gt; active/passive cluster, so if either the network or Asterisk fails<BR>&gt; these services could be migrated to the other server. As I already<BR>&gt; stated earlier, the current config notifies me if asterisk is down<BR>&gt; but does not start asterisk on the other server.<BR><BR>Did asterisk restart on the same server? &lt;- this is what I would expect pacemaker to do.<BR><BR>Removing the colocation (and order) statements didn't have any effect?<BR><BR>&gt; <BR>&gt; <BR>&gt; ----- Forwarded Message -----<BR>&gt; From: Jake Smith &lt;<A href="mailto:jsmith@argotec.com" ymailto="mailto:jsmith@argotec.com">jsmith@argotec.com</A>&gt;<BR>&gt; To: Tommy Cooper &lt;<A href="mailto:tomcooper83@yahoo.com" ymailto="mailto:tomcooper83@yahoo.com">tomcooper83@yahoo.com</A>&gt;; The
 Pacemaker cluster<BR>&gt; resource manager &lt;<A href="mailto:pacemaker@oss.clusterlabs.org" ymailto="mailto:pacemaker@oss.clusterlabs.org">pacemaker@oss.clusterlabs.org</A>&gt;<BR>&gt; Sent: Monday, March 4, 2013 9:29 PM<BR>&gt; Subject: Re: [Pacemaker] Cluster resources failing to move<BR>&gt; <BR>&gt; <BR>&gt; ----- Original Message -----<BR>&gt; &gt; From: "Tommy Cooper" &lt; <A href="mailto:tomcooper83@yahoo.com" ymailto="mailto:tomcooper83@yahoo.com">tomcooper83@yahoo.com</A> &gt;<BR>&gt; &gt; To: <A href="mailto:pacemaker@oss.clusterlabs.org" ymailto="mailto:pacemaker@oss.clusterlabs.org">pacemaker@oss.clusterlabs.org</A><BR>&gt; &gt; Sent: Monday, March 4, 2013 2:19:22 PM<BR>&gt; &gt; Subject: [Pacemaker] Cluster resources failing to move<BR>&gt; &gt; <BR>&gt; &gt; <BR>&gt; &gt; <BR>&gt; &gt; <BR>&gt; &gt; Hi,<BR>&gt; &gt; <BR>&gt; &gt; <BR>&gt; &gt; I am trying to configure a 2 node cluster using pac emaker 1.1.7<BR>&gt; &gt; and<BR>&gt; &gt;
 corosync 1.4.1. I. I want pacemaker to provide the virual IP<BR>&gt; &gt; (192.168.1.115), monitor Asterisk (PBX) and failover to the othe<BR>&gt; &gt; server. If I switch off pacemaker and/or corosync the cluster<BR>&gt; &gt; resources switch to the other node. I have also configured<BR>&gt; &gt; <A href="http://res_corosync.so/" target=_blank>res_corosync.so</A> module in Asterisk However if i either switch off<BR>&gt; &gt; asterisk using service *service name* stop, the following error is<BR>&gt; &gt; shown: Failed actions:<BR>&gt; &gt; p_asterisk_monitor_10000 (node=node1.localdomain, call=10, rc=7,<BR>&gt; &gt; status=complete): not running<BR>&gt; &gt; <BR>&gt; <BR>&gt; What do you want/expect to happen when you stop asterisk that<BR>&gt; doesn't? The monitor showing not running (failed) is expected if<BR>&gt; some outside event stopped the resource.<BR>&gt; <BR>&gt; &gt; Corosync configuration:<BR>&gt; &gt; <BR>&gt; &gt; compatibility:
 whitetank<BR>&gt; &gt; totem {<BR>&gt; &gt; version: 2<BR>&gt; &gt; secauth: off<BR>&gt; &gt; interface {<BR>&gt; &gt; member {<BR>&gt; &gt; memberaddr: 192.168.1.113<BR>&gt; &gt; }<BR>&gt; &gt; member {<BR>&gt; &gt; memberaddr: 192.168.1.114<BR>&gt; &gt; }<BR>&gt; &gt; ringnumber: 0<BR>&gt; &gt; bindnetaddr: 192.168.1.0<BR>&gt; &gt; mcastport: 5405<BR>&gt; &gt; ttl: 1<BR>&gt; &gt; }<BR>&gt; &gt; transport: udpu<BR>&gt; &gt; }<BR>&gt; &gt; logging {<BR>&gt; &gt; fileline: off<BR>&gt; &gt; to_logfile: yes<BR>&gt; &gt; to_syslog: yes<BR>&gt; &gt; debug: on<BR>&gt; &gt; logfile: /var/log/cluster/corosync.log<BR>&gt; &gt; debug: off<BR>&gt; &gt; timestamp: on<BR>&gt; &gt; logger_subsys {<BR>&gt; &gt; subsys: AMF<BR>&gt; &gt; debug: off<BR>&gt; &gt; }<BR>&gt; &gt; }<BR>&gt; &gt; <BR>&gt; &gt; amf {<BR>&gt; &gt; mode: disabled<BR>&gt; &gt; }<BR>&gt; &gt; quorum {<BR>&gt; &gt; provider: corosync_votequorum<BR>&gt; &gt; expected_votes: 3<BR>&gt; &gt; }<BR>&gt;
 &gt; <BR>&gt; &gt; crm configure status:<BR>&gt; &gt; <BR>&gt; &gt; node node1.localdomain<BR>&gt; &gt; node node2.localdomain<BR>&gt; &gt; primitive failover-ip ocf:heartbeat:IPaddr2 \<BR>&gt; &gt; params ip="192.168.1.115" cidr_netmask="24" nic="eth6" \<BR>&gt; &gt; op start interval="0" timeout="30" \<BR>&gt; &gt; op monitor interval="1s" timeout="30" start-delay="0" \<BR>&gt; &gt; op stop interval="0" timeout="30s" \<BR>&gt; &gt; meta target-role="started"<BR>&gt; &gt; primitive p_asterisk ocf:heartbeat:asterisk \<BR>&gt; &gt; params user="root" group="root" maxfiles="65536" \<BR>&gt; &gt; op start interval="0" timeout="30s" \<BR>&gt; &gt; op monitor interval="10s" timeout="30s" \<BR>&gt; &gt; op stop interval="0" timeout="30s"<BR>&gt; &gt; group voip failover-ip p_asterisk<BR>&gt; <BR>&gt; You don't need these colocation and order statements if you have the<BR>&gt; resources grouped - remove them. The group is a syntax shortcut for<BR>&gt; writing
 order and colocation statements so the above is enforcing an<BR>&gt; order of ip then asterisk and a colocation of asterisk with ip. Also<BR>&gt; the colocation below is backwards and *might* be causing your<BR>&gt; issues.<BR>&gt; <BR>&gt; HTH<BR>&gt; Jake<BR>&gt; <BR>&gt; &gt; colocation asterisk_cluster inf: failover-ip p_asterisk<BR>&gt; &gt; order start_order inf: failover-ip p_asterisk<BR>&gt; &gt; property $id="cib-bootstrap-options" \<BR>&gt; &gt; dc-version="1.1.7-6.el6-148fccfd5985c5590cc601123c6c16e966b85d14" \<BR>&gt; &gt; cluster-infrastructure="openais" \<BR>&gt; &gt; expected-quorum-votes="2" \<BR>&gt; &gt; stonith-enabled="false" \<BR>&gt; &gt; no-quorum-policy="ignore"<BR>&gt; &gt; rsc_defaults $id="rsc-options" \<BR>&gt; &gt; resource-stickiness="100"<BR>&gt; &gt; <BR>&gt; &gt; <BR>&gt; &gt; <BR>&gt; &gt; <BR>&gt; &gt; <BR>&gt; &gt; _______________________________________________<BR>&gt; &gt; Pacemaker mailing list: <A
 href="mailto:Pacemaker@oss.clusterlabs.org" ymailto="mailto:Pacemaker@oss.clusterlabs.org">Pacemaker@oss.clusterlabs.org</A><BR>&gt; &gt; <A href="http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target=_blank>http://oss.clusterlabs.org/mailman/listinfo/pacemaker</A><BR>&gt; &gt; <BR>&gt; &gt; Project Home: <A href="http://www.clusterlabs.org/" target=_blank>http://www.clusterlabs.org/</A><BR>&gt; &gt; Getting started:<BR>&gt; &gt; <A href="http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf" target=_blank>http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf</A><BR>&gt; &gt; Bugs: <A href="http://bugs.clusterlabs.org/" target=_blank>http://bugs.clusterlabs.org/</A><BR>&gt; &gt; <BR>&gt; <BR>&gt; <BR>&gt; <BR>&gt; _______________________________________________<BR>&gt; Pacemaker mailing list: <A href="mailto:Pacemaker@oss.clusterlabs.org" ymailto="mailto:Pacemaker@oss.clusterlabs.org">Pacemaker@oss.clusterlabs.org</A><BR>&gt; <A
 href="http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target=_blank>http://oss.clusterlabs.org/mailman/listinfo/pacemaker</A><BR>&gt; <BR>&gt; Project Home: <A href="http://www.clusterlabs.org/" target=_blank>http://www.clusterlabs.org/</A><BR>&gt; Getting started:<BR>&gt; <A href="http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf" target=_blank>http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf</A><BR>&gt; Bugs: <A href="http://bugs.clusterlabs.org/" target=_blank>http://bugs.clusterlabs.org/</A><BR>&gt; <BR><BR><BR></DIV></DIV></div></body></html>