<p dir="ltr">I guess the short answer is, "because that's the way it works". I am just guessing here but scoring infinity on a location doesn't mean it's impossible to start the resource elsewhere. If the nodes involved in the locations defined are unavailable, the cluster will still try to place it somewhere. This somewhere might be anywhere in an optin cluster, and is "nowhere" in an opt out cluster... At least that's how I understand it.<br>
Of you really don't want opt out cluster, you might need to define resource location in order to avoid unwanted resource placement (-inf:). IMHO, asymmetrical=true of your best choice.</p>
<div class="gmail_quote">Le 11 nov. 2014 16:39, "Hauke Homburg" <<a href="mailto:hhomburg@w3-creative.de">hhomburg@w3-creative.de</a>> a écrit :<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
Am 11.11.2014 16:25, schrieb Andrei Borzenkov:
<blockquote type="cite">
<pre>В Tue, 11 Nov 2014 16:19:56 +0100
Hauke Homburg <a href="mailto:hhomburg@w3-creative.de" target="_blank"><hhomburg@w3-creative.de></a> пишет:
</pre>
<blockquote type="cite">
<pre>Am 11.11.2014 13:34, schrieb Alexandre:
</pre>
<blockquote type="cite">
<pre>
You should use an opt out cluster. Set the cluster option
symmetrical=false. This will tell corosync not to place a resource
anywhere on the cluster, unless a location rule explicitly tell the
cluster where it should run.
Corosync will still monitor sql resources on www hosts and return rc 5
but this is expected and works.
Le 11 nov. 2014 13:22, "Hauke Homburg" <<a href="mailto:hhomburg@w3-creative.de" target="_blank">hhomburg@w3-creative.de</a>
<a href="mailto:hhomburg@w3-creative.de" target="_blank"><mailto:hhomburg@w3-creative.de></a>> a écrit :
Hello,
I am installing a 6 Node pacemaker CLuster. 3 Nodes for Apache, 3
Nodes for Postgres.
My Cluster Config is
node kvm-node1
node sql-node1
node sql-node2
node sql-node3
node www-node1
node www-node2
node www-node3
primitive pri_kvm_ip ocf:heartbeat:IPaddr2 \
params ip="10.0.6.41" cidr_netmask="255.255.255.0" \
op monitor interval="10s" timeout="20s"
primitive pri_sql_ip ocf:heartbeat:IPaddr2 \
params ip="10.0.6.31" cidr_netmask="255.255.255.0" \
op monitor interval="10s" timeout="20s"
primitive pri_www_ip ocf:heartbeat:IPaddr2 \
params ip="10.0.6.21" cidr_netmask="255.255.255.0" \
op monitor interval="10s" timeout="20s"
primitive res_apache ocf:heartbeat:apache \
params configfile="/etc/apache2/apache2.conf" \
op start interval="0" timeout="40" \
op stop interval="0" timeout="60" \
op monitor interval="60" timeout="120" start-delay="0" \
meta target-role="Started"
primitive res_pgsql ocf:heartbeat:pgsql \
params pgctl="/usr/lib/postgresql/9.1/bin/pg_ctl"
psql="/usr/bin/psql" start_opt=""
pgdata="/var/lib/postgresql/9.1/main"
config="/etc/postgresql/9.1/main/postgresql.conf" pgdba="postgres" \
op start interval="0" timeout="120s" \
op stop interval="0" timeout="120s" \
op monitor interval="30s" timeout="30s" depth="0"
location loc_kvm_ip_node1 pri_kvm_ip 10001: kvm-node1
location loc_sql_ip_node1 pri_sql_ip inf: sql-node1
location loc_sql_ip_node2 pri_sql_ip inf: sql-node2
location loc_sql_ip_node3 pri_sql_ip inf: sql-node3
location loc_sql_srv_node1 res_pgsql inf: sql-node1
location loc_sql_srv_node2 res_pgsql inf: sql-node2
location loc_sql_srv_node3 res_pgsql inf: sql-node3
location loc_www_ip_node1 pri_www_ip inf: www-node1
location loc_www_ip_node2 pri_www_ip inf: www-node2
location loc_www_ip_node3 pri_www_ip inf: www-node3
location loc_www_srv_node1 res_apache inf: www-node1
location loc_www_srv_node2 res_apache inf: www-node2
location loc_www_srv_node3 res_apache inf: www-node3
property $id="cib-bootstrap-options" \
dc-version="1.1.7-ee0730e13d124c3d58f00016c3376a1de5323cff" \
cluster-infrastructurFailed actions:
Why do i see in crm_mon the following output?
res_pgsql_start_0 (node=www-node1, call=16, rc=5,
status=complete): not installed
res_pgsql_start_0 (node=www-node2, call=13, rc=5,
status=complete): not installed
pri_www_ip_monitor_10000 (node=www-node3, call=22, rc=7,
status=complete): not running
res_pgsql_start_0 (node=www-node3, call=13, rc=5,
status=complete): not installed
res_apache_start_0 (node=sql-node2, call=18, rc=5,
status=complete): not installed
res_pgsql_start_0 (node=sql-node2, call=12, rc=5,
status=complete): not installed
res_apache_start_0 (node=sql-node3, call=12, rc=5,
status=complete): not installed
res_pgsql_start_0 (node=sql-node3, call=10, rc=5,
status=complete): not installed
res_apache_start_0 (node=kvm-node1, call=12, rc=5,
status=complete): not installed
res_pgsql_start_0 (node=kvm-node1, call=20, rc=5,
status=complete): not installede="openais" \
expected-quorum-votes="7" \
stonith-enabled="false"
I set the infinity for pgsql on all 3 sql nodes, but not! on the
www nodes. Why tries Pacemaker to start the Postgres SQL Server on
the www Node? In example?
Thank for your Help
greetings
Hauke
_______________________________________________
Pacemaker mailing list: <a href="mailto:Pacemaker@oss.clusterlabs.org" target="_blank">Pacemaker@oss.clusterlabs.org</a>
<a href="mailto:Pacemaker@oss.clusterlabs.org" target="_blank"><mailto:Pacemaker@oss.clusterlabs.org></a>
<a href="http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target="_blank">http://oss.clusterlabs.org/mailman/listinfo/pacemaker</a>
Project Home: <a href="http://www.clusterlabs.org" target="_blank">http://www.clusterlabs.org</a>
Getting started:
<a href="http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf" target="_blank">http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf</a>
Bugs: <a href="http://bugs.clusterlabs.org" target="_blank">http://bugs.clusterlabs.org</a>
_______________________________________________
Pacemaker mailing list: <a href="mailto:Pacemaker@oss.clusterlabs.org" target="_blank">Pacemaker@oss.clusterlabs.org</a>
<a href="http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target="_blank">http://oss.clusterlabs.org/mailman/listinfo/pacemaker</a>
Project Home: <a href="http://www.clusterlabs.org" target="_blank">http://www.clusterlabs.org</a>
Getting started: <a href="http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf" target="_blank">http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf</a>
Bugs: <a href="http://bugs.clusterlabs.org" target="_blank">http://bugs.clusterlabs.org</a>
</pre>
</blockquote>
<pre>Hello Alexandre,
Why can't i set the infinity for the SQL servernodes to start the SQL
Daemon only on the sql-nodes? I thought that has to be all?
</pre>
</blockquote>
<pre>
<a href="http://clusterlabs.org/doc/en-US/Pacemaker/1.0/html/Pacemaker_Explained/s-resource-location.html" target="_blank">http://clusterlabs.org/doc/en-US/Pacemaker/1.0/html/Pacemaker_Explained/s-resource-location.html</a>
</pre>
<blockquote type="cite">
<pre>Greetings
Hauke
</pre>
</blockquote>
<pre>
</pre>
</blockquote>
You are right.<br>
<br>
The Page says score: Values of +/- <code>INFINITY</code>
change "can" to "must".<br>
<br>
I have set location loc_sql_srv_node1 res_pgsql inf: sql-node1. But
not to www-node1. So i am wondering.<br>
<br>
Greetings<br>
</div>
<br>_______________________________________________<br>
Pacemaker mailing list: <a href="mailto:Pacemaker@oss.clusterlabs.org">Pacemaker@oss.clusterlabs.org</a><br>
<a href="http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target="_blank">http://oss.clusterlabs.org/mailman/listinfo/pacemaker</a><br>
<br>
Project Home: <a href="http://www.clusterlabs.org" target="_blank">http://www.clusterlabs.org</a><br>
Getting started: <a href="http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf" target="_blank">http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf</a><br>
Bugs: <a href="http://bugs.clusterlabs.org" target="_blank">http://bugs.clusterlabs.org</a><br>
<br></blockquote></div>