aboutsummaryrefslogtreecommitdiffstats
path: root/extraconfig/tasks/major_upgrade_pacemaker_migrations.sh
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2016-03-24 17:51:42 +0000
committerGerrit Code Review <review@openstack.org>2016-03-24 17:51:43 +0000
commit19e44d2a61d31982b76e3ac9d0e8bb90f9ca57e1 (patch)
tree5a4d2be3503d7cff423bc6b630e2aa68033d74ea /extraconfig/tasks/major_upgrade_pacemaker_migrations.sh
parent1697dc1a54ed8daa43e346bd563de9ae9a051710 (diff)
parent2018c38ed41fe4ffcdc128081218ee6e688bd4fc (diff)
Merge "Deploy Aodh services, replacing Ceilometer Alarm"
Diffstat (limited to 'extraconfig/tasks/major_upgrade_pacemaker_migrations.sh')
-rw-r--r--extraconfig/tasks/major_upgrade_pacemaker_migrations.sh25
1 files changed, 25 insertions, 0 deletions
diff --git a/extraconfig/tasks/major_upgrade_pacemaker_migrations.sh b/extraconfig/tasks/major_upgrade_pacemaker_migrations.sh
index 7fd26945..1f420b32 100644
--- a/extraconfig/tasks/major_upgrade_pacemaker_migrations.sh
+++ b/extraconfig/tasks/major_upgrade_pacemaker_migrations.sh
@@ -12,3 +12,28 @@
# The migration functions should be idempotent. If the migration has
# been already applied, it should be possible to call the function
# again without damaging the deployment or failing the upgrade.
+
+function remove_ceilometer_alarm {
+ if pcs status | grep openstack-ceilometer-alarm; then
+ # Disable pacemaker resources for ceilometer-alarms
+ pcs resource disable openstack-ceilometer-alarm-evaluator
+ check_resource openstack-ceilometer-alarm-evaluator stopped 600
+ pcs resource delete openstack-ceilometer-alarm-evaluator
+ pcs resource disable openstack-ceilometer-alarm-notifier
+ check_resource openstack-ceilometer-alarm-notifier stopped 600
+ pcs resource delete openstack-ceilometer-alarm-notifier
+
+ # remove constraints
+ pcs constraint remove ceilometer-delay-then-ceilometer-alarm-evaluator-constraint
+ pcs constraint remove ceilometer-alarm-evaluator-with-ceilometer-delay-colocation
+ pcs constraint remove ceilometer-alarm-evaluator-then-ceilometer-alarm-notifier-constraint
+ pcs constraint remove ceilometer-alarm-notifier-with-ceilometer-alarm-evaluator-colocation
+ pcs constraint remove ceilometer-alarm-notifier-then-ceilometer-notification-constraint
+ pcs constraint remove ceilometer-notification-with-ceilometer-alarm-notifier-colocation
+
+ fi
+
+ # uninstall openstack-ceilometer-alarm package
+ yum -y remove openstack-ceilometer-alarm
+
+}