check-sanity fails if any of BASE_SERVICES are disabled

Bug #1355499 reported by Adam Gandelman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
grenade
Fix Released
Undecided
Adam Gandelman

Bug Description

check-sanity attempts to confirm a set of services are running post-upgrade. This list of services is currently hard-coded in grenaderc as BASE_SERVICES/TARGET_SERVICES. If any of these services are disabled via devstack (ie, Cinder), check-sanity will still query running processes of those services listed in the hard-coded list. This makes it impossible to check-sanity against a cloud with a non-standard list of services running.

There are TODOs in grenaderc and I'm sure this is a known thing. I assume the reason for this is that devstack's Is_running() receives a process name (ie, nova-api), while devstack's ENABLED_SERVICES / is_service_enabled() use the abbreviated forms (i,e n-api). If this was standardized or mapped better in devstack, grenade's check-sanity could simply do something like:

for name in $TARGET_SERVICES; do
   if is_service_enabled $name && ! is_running $name ; then
       NOT_RUNNING="$name"
   fi
done

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to grenade (master)

Fix proposed to branch: master
Review: https://review.openstack.org/113405

Changed in grenade:
assignee: nobody → Adam Gandelman (gandelman-a)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to grenade (master)

Reviewed: https://review.openstack.org/113405
Committed: https://git.openstack.org/cgit/openstack-dev/grenade/commit/?id=376e301d485194259527ad9d5db5d89f347ef8ab
Submitter: Jenkins
Branch: master

commit 376e301d485194259527ad9d5db5d89f347ef8ab
Author: Adam Gandelman <email address hidden>
Date: Mon Aug 11 16:38:55 2014 -0700

    Fix check-sanity + save-state /w disabled services

    This adds a mapping for all process names described in BASE_SERVICES
    and TARGET_SERVICES, allowing check-sanity to skip checking for running
    processes of services that are disabled according to ENABLED_SERVICES.
    It also updates grenade.sh and save-state to only dump databases that
    exist. These changes allow grenade to pass against deployments that
    have disabled non-essential services in devstack.

    Change-Id: Ic4b2bab88b12f33f939b9bf7aca47e930d799f3f
    Closes-bug: #1355499

Changed in grenade:
status: In Progress → Fix Committed
Sean Dague (sdague)
Changed in grenade:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.