Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1353049 - [RFE] failed update and/or upgrade attempt should return non 0 value.
[RFE] failed update and/or upgrade attempt should return non 0 value.
Status: CLOSED ERRATA
Product: Red Hat OpenStack
Classification: Red Hat
Component: python-tripleoclient (Show other bugs)
9.0 (Mitaka)
Unspecified Unspecified
high Severity unspecified
: Upstream M3
: 11.0 (Ocata)
Assigned To: Brad P. Crochet
Ola Pavlenko
: FutureFeature, Triaged
Depends On:
Blocks: 1461498
  Show dependency treegraph
 
Reported: 2016-07-05 18:21 EDT by Alexander Chuzhoy
Modified: 2017-06-14 11:16 EDT (History)
20 users (show)

See Also:
Fixed In Version: python-tripleoclient-6.0.1-0.20170127055753.8ea289c.el7ost
Doc Type: Bug Fix
Doc Text:
Previously, a failed update or upgrade would return an exit value of 0, so it was not possible to test for success based upon this value. With this update, a failed update or upgrade will throw an exception to signify to OpenStackClient that there is an error condition. As a result, OpenStackClient will only return an exit value of 0 on success, and a non-zero value after an error.
Story Points: ---
Clone Of:
: 1461498 (view as bug list)
Environment:
Last Closed: 2017-05-17 15:31:40 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Launchpad 1599872 None None None 2017-02-08 08:47 EST
OpenStack gerrit 339048 None None None 2016-07-07 11:08 EDT
OpenStack gerrit 370742 None None None 2016-12-13 06:57 EST
Red Hat Product Errata RHEA-2017:1245 normal SHIPPED_LIVE Red Hat OpenStack Platform 11.0 Bug Fix and Enhancement Advisory 2017-05-17 19:01:50 EDT

  None (edit)
Description Alexander Chuzhoy 2016-07-05 18:21:34 EDT
rhel-osp-director:  [RFE] failed update and/or upgrade attempt should return non 0 value.

Currently , once the update or upgrade fails:
IN_PROGRESS
FAILED
update finished with status FAILED


The exit value is 0, so we can't test result based on it.


Expected:
The exit value should be 0 only when the update/upgrade succeeded.
Comment 2 Jay Dobies 2016-07-07 09:09:24 EDT
Brad - Can you see if this is a reasonably quick fix to include in 9?
Comment 3 Brad P. Crochet 2016-07-07 09:16:17 EDT
What command(s) is this referring to? openstack overcloud deploy? openstack overcloud update?
Comment 4 Alexander Chuzhoy 2016-07-07 09:54:06 EDT
openstack overcloud update stack overcloud -i with arguments.
Comment 5 Alexander Chuzhoy 2016-07-07 09:55:24 EDT
Upstream bug:
https://bugs.launchpad.net/tripleo/+bug/1599872
Comment 6 Jaromir Coufal 2016-09-30 03:54:44 EDT
Can you please update the BZ, please? Seems that upstream bug was merged back.
Comment 7 Jaromir Coufal 2016-10-04 16:10:56 EDT
Sasha, did you notice if this is included in OSP10 while testing upgrades?
Comment 8 Alexander Chuzhoy 2016-10-04 18:38:45 EDT
[stack@instack ~]$ openstack overcloud update stack overcloud -i --templates -e /usr/share/openstack-tripleo-heat-templates/overcloud-resource-registry-puppet.yaml -e /usr/share/openstack-tripleo-heat-templates/environments/puppet-pacemaker.yaml -e /usr/share/openstack-tripleo-heat-templates/environments/storage-environment.yaml -e /usr/share/openstack-tripleo-heat-templates/environments/network-isolation.yaml -e network-environment.yaml
starting package update on stack overcloud
<urlopen error [Errno 2] No such file or directory: '/usr/share/openstack-tripleo-heat-templates/overcloud-without-mergepy.yaml'>

[stack@instack ~]$ echo $?
1
Comment 9 Jaromir Coufal 2016-10-09 19:29:18 EDT
Thank you, Sasha. Adding as an RFE for 11.
Comment 10 Jaromir Coufal 2016-10-18 10:23:30 EDT
Brad, this still seems not working, could you have a look, please?
Comment 11 Ola Pavlenko 2016-12-13 06:57:22 EST
fix was merged upstream in stable/newton on Sep 20.
Moving to Modified
Comment 12 Ola Pavlenko 2016-12-13 06:58:10 EST
See comment#11
Comment 14 Julie Pichon 2017-02-08 08:47:55 EST
Updating NVR and component. Target release is set to 11 so, even though the fix was backported I'm setting "Fixed in version" according to the 11 puddle.
Comment 16 Udi 2017-04-13 02:05:02 EDT
Verified for puddle 2017-04-06.
Comment 17 errata-xmlrpc 2017-05-17 15:31:40 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2017:1245

Note You need to log in before you can comment on or make changes to this bug.