Unable to find operation matching: monitor:Master
Closed this issue · 4 comments
zaitsxl commented
Hi all,
after #233 was merged the following code:
cs_primitive { 'pgsql':
primitive_class => 'ocf',
primitive_type => 'pgsql',
provided_by => 'heartbeat',
promotable => 'true',
parameters => { 'pgctl' => '/bin/pg_ctl', 'psql' => '/bin/psql', 'pgdata' => '/var/lib/pgsql/data/', 'rep_mode' => 'sync', 'node_list' => inline_template("<%= @node_list %>"), 'restore_command' => 'cp /var/lib/pgsql/pg_archive/%f %p', 'primary_conninfo_opt' => 'keepalives_idle=60 keepalives_interval=5 keepalives_count=5', 'master_ip' => inline_template("<%= @vip_slave %>"), 'restart_on_promote' => 'true' },
operations => {
'start' => { 'interval' => '0s', 'timeout' => '60s', 'on-fail' => 'restart' },
'monitor' => { 'interval' => '4s', 'timeout' => '60s', 'on-fail' => 'restart' },
'monitor' => { 'interval' => '3s', 'timeout' => '60s', 'on-fail' => 'restart', 'role' => 'Master' },
'promote' => { 'interval' => '0s', 'timeout' => '60s', 'on-fail' => 'restart' },
'demote' => { 'interval' => '0s', 'timeout' => '60s', 'on-fail' => 'stop' },
'stop' => { 'interval' => '0s', 'timeout' => '60s', 'on-fail' => 'block' },
'notify' => { 'interval' => '0s', 'timeout' => '60s' },
},
ms_metadata => { 'master-max' => '1', 'master-node-max' => '1', 'clone-max' => '2', 'clone-node-max' => '1', 'notify' => 'true' },
require => Cs_primitive['vip-master','vip-slave'],
}
throws the following error:
Error: /Stage[main]/Profile::Db::Bi_db/Cs_primitive[pgsql]: Could not evaluate: Execution of '/sbin/pcs resource op remove pgsql monitor:Master interval=3s on-fail=restart timeout=60s' returned 1: Error: Unable to find operation matching: monitor:Master interval=3s on-fail=restart timeout=60s
roidelapluie commented
can you try
'monitor' => { 'interval' => '4s', 'timeout' => '60s', 'on-fail' => 'restart' },
'monitor:Master' => { 'interval' => '3s', 'timeout' => '60s', 'on-fail' => 'restart', 'role' => 'Master' },
zaitsxl commented
Tried, the same error
roidelapluie commented
roidelapluie commented
@zaitsxl can you try now?