Update introspection command to introspect only manageable nodes

With the Newton and later releases, it is possible to introspect
only nodes in the manageable state rather than run bulk
introspection that would work on all imported nodes.

Change-Id: Ic36dea3f93e84ab49731996a69a9d3c28f973e86
This commit is contained in:
Ronelle Landy 2017-02-02 09:24:44 -05:00
parent 37ddaa3529
commit 91a190da14
1 changed files with 16 additions and 1 deletions

View File

@ -90,8 +90,23 @@ sudo mistral-db-manage populate
## * Introspect hardware attributes of nodes.
## ::
{% if release == 'mitaka' %}
openstack baremetal introspection bulk start
{% else %}
# Note: Unlike the legacy bulk command, overcloud node
# introspect will only run on nodes in the 'manageable'
# provisioning state.
for node in $(openstack baremetal node list --fields uuid -f value) ; do
openstack baremetal node manage $node ;
done
openstack overcloud node introspect --all-manageable
openstack overcloud node provide --all-manageable
{% endif %}
{% endif %}