hacluster: Use nodename to align with nova service names
For Masakari and HACluster to work properly, the hostnames used in HACluster need to match with the hostnames used in Nova. Change-Id: Iac917ef4471905caab591cd64eab379e150a8524
This commit is contained in:
parent
b1e5a97028
commit
e1ae8223f9
@ -15,12 +15,12 @@
|
||||
{{ kolla_container_engine }} exec {{ pacemaker_service.container_name }}
|
||||
cibadmin --modify --scope resources -X '
|
||||
<resources>
|
||||
<primitive id="{{ ansible_facts.hostname }}" class="ocf" provider="pacemaker" type="remote">
|
||||
<instance_attributes id="{{ ansible_facts.hostname }}-instance_attributes">
|
||||
<nvpair id="{{ ansible_facts.hostname }}-instance_attributes-server" name="server" value="{{ 'api' | kolla_address }}"/>
|
||||
<primitive id="{{ ansible_facts.nodename }}" class="ocf" provider="pacemaker" type="remote">
|
||||
<instance_attributes id="{{ ansible_facts.nodename }}-instance_attributes">
|
||||
<nvpair id="{{ ansible_facts.nodename }}-instance_attributes-server" name="server" value="{{ 'api' | kolla_address }}"/>
|
||||
</instance_attributes>
|
||||
<operations>
|
||||
<op id="{{ ansible_facts.hostname }}-monitor" name="monitor" interval="60" timeout="30"/>
|
||||
<op id="{{ ansible_facts.nodename }}-monitor" name="monitor" interval="60" timeout="30"/>
|
||||
</operations>
|
||||
</primitive>
|
||||
</resources>
|
||||
|
@ -13,7 +13,7 @@ nodelist {
|
||||
{% for host in groups['hacluster'] | sort %}
|
||||
node {
|
||||
ring0_addr: {{ 'api' | kolla_address(host) }}
|
||||
name: {{ hostvars[host].ansible_facts.hostname }}
|
||||
name: {{ hostvars[host].ansible_facts.nodename }}
|
||||
nodeid: {{ loop.index }}
|
||||
}
|
||||
{% endfor %}
|
||||
|
Loading…
Reference in New Issue
Block a user