voxpupuli / puppet-corosync

Sets up and manages Corosync.
https://forge.puppet.com/puppet/corosync
Apache License 2.0
44 stars 161 forks source link

fails to create order with pacemaker 2.0.1 (Debian 10) #469

Open and0x000 opened 5 years ago

and0x000 commented 5 years ago

Affected Puppet, Ruby, OS and module versions/distributions

How to reproduce (e.g Puppet code you use)

On a 2 node cluster with stonith disabled, create 2 primitive resources and try to apply an order on them.

What are you seeing

Checking the pacemaker configuration (crm configure show) after a puppet run, the orders are not applied.

What behaviour did you expect instead

I expect the order to be applied.

Output log

Debug: Cs_order[redis_master_before_ip](provider=crm): Loading update: order redis_master_before_ip INFINITY: ms_redis_server:demote failover_ip:stop symmetrical=true
Debug: PuppetX::Voxpupuli::Corosync::Provider::Crmsh: Executing ["/sbin/crm", "configure", "load", "update", "/tmp/puppet_crm_update20190716-7369-13emwtd"] in the CIB
Debug: Executing: '/sbin/crm configure load update /tmp/puppet_crm_update20190716-7369-13emwtd'
Error: /Cs_order[redis_master_before_ip]: Could not evaluate: Execution of '/sbin/crm configure load update /tmp/puppet_crm_update20190716-7369-13emwtd' returned 1: ERROR: (unpack_config)     warning: Blind faith: not fencing unseen nodes
(get_ordering_type)     warning: Support for 'score' in rsc_order is deprecated and will be removed in a future release (use 'kind' instead)
Warnings found during check: config may not be valid

Any additional information you'd like to impart

Adding the generated order manually via crm configure edit results in an yes/no prompt after saving.

(get_ordering_type)     warning: Support for 'score' in rsc_order is deprecated and will be removed in a future release (use 'kind' instead)
Warnings found during check: config may not be valid
Do you still want to commit (y/n)? 

A quick and dirty workaround might be, to pipe yes to the command.

For a clean solution, the module could use the new syntax to avoid the deprecation warning.

XANi commented 4 years ago

temporary fix: doing

xsltproc /usr/share/pacemaker/upgrade-2.10.xsl /etc/corosync/cib_config.xml >/root/cib_config.xml

to the XML and then applying it as usual "works"