From 6d335056a39f8ee33a708f5b9556fc7663e5023e Mon Sep 17 00:00:00 2001 From: Michele Baldessari Date: Fri, 8 Jan 2021 11:37:57 +0100 Subject: [PATCH] Fix manila-share with ceph-nfs backend Currently when you deploy manila-share with a ceph-nfs backend we get the following error: Error: pcs -f /var/lib/pacemaker/cib/puppet-cib-backup20210107-48280-1y4rwmx constraint colocation add openstack-manila-share with ceph-nfs INFINITY failed: Error: Resource 'ceph-nfs' does not exist. Too many tries The reason for it is that we moved the pcs resource creation to the host and outside containers https://review.opendev.org/q/topic:%22pcs_host3%22+(status:open%20OR%20status:merged) But when the ceph-nfs pcmk resource gets created at step 5, the manila-share puppet code has already been invoked and since it requires the ceph-nfs resource to be available it fails like above. Let's move the ceph-nfs creation to step4 to solve this. Closes-Bug: #1910732 Change-Id: Ifb81d155cbb4598a311c8e6fe90be951a8e7e656 (cherry picked from commit 06e131882b563576da55886d2bd5ffe769df41e5) --- manifests/profile/pacemaker/ceph_nfs.pp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/manifests/profile/pacemaker/ceph_nfs.pp b/manifests/profile/pacemaker/ceph_nfs.pp index 6ddf8985b..0fa3326da 100644 --- a/manifests/profile/pacemaker/ceph_nfs.pp +++ b/manifests/profile/pacemaker/ceph_nfs.pp @@ -91,7 +91,10 @@ class tripleo::profile::pacemaker::ceph_nfs ( } } - if $step >= 5 and $pacemaker_master { + # When we create manila-share resource at step 5 we need the ceph-nfs pcmk resource up + # and running. But since we moved to pcs commands invoked on host, manila-share at step5 + # gets created *before* ceph-nfs (as it is invoked via step_config vs docker_config) + if $step >= 4 and $pacemaker_master { pacemaker::resource::service { 'ceph-nfs' : service_name => 'ceph-nfs@pacemaker', op_params => 'start timeout=200s stop timeout=200s',