Hello Marc, > If I kill the node hosting postgresr2, postgresr2 migrates to another > node, but applisr1 and applisr3 aren't restarted. Is it normal ? What > could I do to solve this ?
the answer to your question is 'resource group'. A resource group is a container for resources. Every resource in a resource group is started and stopped in order and they always have to run on the same host. If you want to build a resource group by yourself, you need order and colocation constraints but more than the obvious. See this thread: http://article.gmane.org/gmane.linux.highavailability.user/21811 Example (from my postgres database): <group id="postgres-cluster"> <primitive class="ocf" provider="heartbeat" type="Filesystem" id="fs0"> <instance_attributes id="ia-fs0"> <attributes> <nvpair id="ia-fs0-1" name="fstype" value="ext3"/> <nvpair name="directory" id="ia-fs0-2" value="/srv/postgres"/> <nvpair id="ia-fs0-3" name="device" value="/dev/drbd0"/> </attributes> </instance_attributes> <operations> <op id="fs0-monitor0" name="monitor" interval="60s" timeout="120s" start_delay="1m"/> </operations> </primitive> <primitive class="ocf" provider="heartbeat" type="IPaddr2" id="ip0"> <instance_attributes id="ia-ip0"> <attributes> <nvpair id="ia-ip0-1" name="ip" value="172.17.0.20"/> <nvpair id="ia-ip0-2" name="cidr_netmask" value="24"/> <nvpair id="ia-ip0-3" name="nic" value="eth0.2"/> </attributes> </instance_attributes> <operations> <op id="ip0-monitor0" name="monitor" interval="60s" timeout="120s" start_delay="1m"/> </operations> </primitive> <primitive class="ocf" provider="heartbeat" type="pgsql" id="pgsql0"> <instance_attributes id="ia-pgsql0"> <attributes> <nvpair id="ia-pgsql0-1" name="pgctl" value="/usr/lib/postgresql/8.1/bin/pg_ctl"/> <nvpair id="ia-pgsql0-2" name="start_opt" value="--config_file=/srv/postgres/etc/postgresql.conf"/> <nvpair id="ia-pgsql0-3" name="pgdata" value="/srv/postgres/data"/> <nvpair id="ia-pgsql0-4" name="logfile" value="/srv/postgres/postgresql.log"/> </attributes> </instance_attributes> <operations> <op id="pgsql0-monitor0" name="monitor" interval="60s" timeout="120s" start_delay="1m"/> <op id="pgsql0-start0" name="start" timeout="120s" prereq="nothing"/> </operations> </primitive> </group> Thomas _______________________________________________ Linux-HA mailing list [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
