[fuel-devops] Changing of boot device on baremetal nodes must be optional

Bug #1588279 reported by Artem Panchenko
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Committed
High
Anton Studenov

Bug Description

Some hardware vendors (in our case HP ProLiant) do not allow users with 'operator' privileges to override device boot order, while all power management functions are available. In such cases hypdid kvm+baremetal deployment using fuel-devops fails while starting BM slaves:

2016-06-02 09:41:08,413 - ERROR decorators.py:127 -- Traceback (most recent call last):
  File "/home/jenkins/workspace/9.0.fuel.baremetal.alpha/fuelweb_test/helpers/decorators.py", line 121, in wrapper
    result = func(*args, **kwargs)
  File "/home/jenkins/workspace/9.0.fuel.baremetal.alpha/fuelweb_test/tests/base_test_case.py", line 449, in prepare_slaves_3
    skip_timesync=True)
  File "/home/jenkins/workspace/9.0.fuel.baremetal.alpha/fuelweb_test/models/environment.py", line 117, in bootstrap_nodes
    node.start()
  File "/home/jenkins/fuel-devops-3/local/lib/python2.7/site-packages/devops/driver/baremetal/ipmi_driver.py", line 125, in start
    self.conn.chassis_set_boot('pxe')
  File "/home/jenkins/fuel-devops-3/local/lib/python2.7/site-packages/devops/driver/baremetal/ipmi_client.py", line 342, in chassis_set_boot
    device, 'options=persistent'])
  File "/home/jenkins/fuel-devops-3/local/lib/python2.7/site-packages/devops/driver/baremetal/ipmi_client.py", line 171, in __run_ipmi
    cmd, err))
DevopsError: Node:slave-01 Remote:cz7961-kvm.host-telecom.com ipmitool command [['chassis', 'bootdev', 'pxe', 'options=persistent']] has failed with the message: Set Chassis Boot Parameter 5 failed: Insufficient privilege level

Workaround:

remove the following line:

https://github.com/openstack/fuel-devops/blob/master/devops/driver/baremetal/ipmi_driver.py#L125

I propose to add an option 'ipmi_force_pxe_boot' into devops template inside [node]->[params] and don't execute chassis_set_boot('pxe') if it's set to False

Tags: area-qa
Ilya Kutukov (ikutukov)
Changed in fuel:
status: New → Confirmed
Changed in fuel:
assignee: Fuel QA Team (fuel-qa) → Anton Studenov (astudenov)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-devops (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-devops (master)

Reviewed: https://review.openstack.org/332104
Committed: https://git.openstack.org/cgit/openstack/fuel-devops/commit/?id=e2035682747e45a6514328c2f40f3a5186e71abe
Submitter: Jenkins
Branch: master

commit e2035682747e45a6514328c2f40f3a5186e71abe
Author: Anton Studenov <email address hidden>
Date: Tue Jun 21 14:56:16 2016 +0300

    Add force_set_boot to IpmiNode

    - Now chassis_set_boot is called only if force_set_boot is set to True
      Note: force_set_boot is True by default
    - Use IpmiNode.boot parameter in chassis_set_boot instead of
      hardcoded 'pxe' string
    - Removed redundant IpmiNode.create and erase methods
    - Added wait for power off in the missing places
    - Added call for super methods in the missing places
    - Added unit test for IpmiNode

    Closes-Bug: #1588279
    Change-Id: I2c097d1dfaef107ff328749b9466a2096022e814

Changed in fuel:
status: In Progress → Fix Committed
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.