28 lines
1.2 KiB
Plaintext
28 lines
1.2 KiB
Plaintext
HA Cluster (pacemaker/corosync) Charm
|
|
======================================
|
|
* Peer-relations
|
|
- make sure node was added to the cluster
|
|
- make sure node has been removed from the cluster (when deleting unit)
|
|
* One thing that can be done is to:
|
|
1. ha-relation-joined puts node in standby.
|
|
2. ha-relation-joined makes HA configuration
|
|
3. on hanode-relation-joined (2 or more nodes)
|
|
- services are stopped from upstart/lsb
|
|
- nodes are put in online mode
|
|
- services are loaded by cluster
|
|
- this way is not in HA until we have a second node.
|
|
* Needs to communicate the VIP to the top service
|
|
* TODO: Fix Disable upstart jobs
|
|
- sudo sh -c "echo 'manual' > /etc/init/SERVICE.override"
|
|
|
|
update-rc.d -f pacemaker remove
|
|
update-rc.d pacemaker start 50 1 2 3 4 5 . stop 01 0 6 .
|
|
|
|
TODO: Problem seems to be that peer-relation gets executed before the subordinate relation.
|
|
|
|
In that case, peer relation would have to put nodes in standby and then the subordinate relation
|
|
will have to put the nodes online and configure the services. Or probably not use it at all.
|
|
|
|
Hanode-relation puts node in standby.
|
|
ha-relation counts nodes in hanode-relation and if >2 then we online them and setup cluster.
|