Bug 849315 - vdsm-upgrade exits with wrong exit code
vdsm-upgrade exits with wrong exit code
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: vdsm (Show other bugs)
6.3
Unspecified Unspecified
high Severity medium
: rc
: ---
Assigned To: Douglas Schilling Landgraf
Pavel Stehlik
infra,
: TestBlocker, ZStream
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-18 04:43 EDT by Alon Bar-Lev
Modified: 2016-04-26 09:31 EDT (History)
20 users (show)

See Also:
Fixed In Version: vdsm-4.9.6-31
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-12-04 14:07:38 EST
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)
attached engine.log (26.53 KB, text/x-log)
2012-09-21 08:05 EDT, haiyang,dong
no flags Details

  None (edit)
Description Alon Bar-Lev 2012-08-18 04:43:22 EDT
When vdsm-upgrade is exiting, it sets the wrong exit code (failure for success and success for failure).

This had not been discovered as:

1. ovirt-engine did not check for script exit code, this is going to be changed at ovirt-engine-3.1.

2. rhvm-h never exited the script waited for reboot, see bug#847103.

Provided (2) is fixed without (1), node upgrade successfully processed, however engine reports failure. Simply activating node will resume normal operation.

A fix is available[1].

[1] http://gerrit.ovirt.org/#/c/7279/
Comment 3 Alon Bar-Lev 2012-08-19 04:35:16 EDT
Version:

At least since vdsm-reg-4.9-113.1, which is bundled within:
---
Red Hat Enterprise Virtualization Hypervisor release 6.3 (20120710.0.el6_3)
---

This is from initial commit at upstream:
---
^8e53f0f vdsm_reg/vdsm-upgrade.py (Tabula Rasa 2011-06-15 23:26:19 +0300 170)     sys.exit(main())
---
Comment 4 Ilanit Stein 2012-09-03 02:58:30 EDT
This bug fails RHEV-H tests, involving upgrade. Marking it as testblocker.
Comment 7 Douglas Schilling Landgraf 2012-09-05 09:10:16 EDT
Hello Alon,

Thanks for the patches!

Cheers
Douglas
Comment 9 haiyang,dong 2012-09-21 06:38:24 EDT
Test version:
vdsm-4.9.6-34.0.el6_3.x86_64
ovirt-node-2.3.0-15.el6_3.7.noarch
rhev-hypervisor6-6.3-20120920.0.rhev31.el6_3
SI18.1 rhevm-3.1.0-16.el6ev.noarch.rpm

upgrade from rhev-h 6.3**** to rhevh-h 6.3*** via RHEVM ,
The test result was that the rhevh was rebooted and really upgraded, but the rhevm showes "Install failed".
So that the bug is not fixed now.
Comment 10 Alon Bar-Lev 2012-09-21 07:00:33 EDT
(In reply to comment #9)
> So that the bug is not fixed now.

engine.log please.
Comment 11 haiyang,dong 2012-09-21 08:05:08 EDT
Created attachment 615408 [details]
attached engine.log

upgrade from rhev-hypervisor6-6.3-20120910.0.rhev31.el6_3 to rhev-hypervisor6-6.3-20120920.0.rhev31.el6_3 via RHEVM
Comment 12 Alon Bar-Lev 2012-09-21 10:43:17 EDT
(In reply to comment #11)
> Created attachment 615408 [details]
> attached engine.log
> 
> upgrade from rhev-hypervisor6-6.3-20120910.0.rhev31.el6_3 to
> rhev-hypervisor6-6.3-20120920.0.rhev31.el6_3 via RHEVM

I can confirm that this is the same root cause.

This is expected, as the bug was not fixed in 20120910 as far as I know.

If you try to upgrade rhev-hypervisor6-6.3-20120920.0.rhev31.el6_3 to rhev-hypervisor6-6.3-20120920.0.rhev31.el6_3 do you get a failure?
Comment 13 haiyang,dong 2012-09-23 23:10:12 EDT
Try to upgrade rhev-hypervisor6-6.3-20120920.0.rhev31.el6_3 to rhev-hypervisor6-6.3-20120920.0.rhev31.el6_3.
Test result:
1.RHEVM shows that upgrade rhev-h successfully.
2012-Sep-24, 10:22:16 Detected new Host localhost.localdomain. Host state was set to Up.		
2012-Sep-24, 10:17:14 Host localhost.localdomain installed
2012-Sep-24, 10:17:14 Installing Host localhost.localdomain. Step: RHEV_INSTALL.
2012-Sep-24, 10:17:14 Installing Host localhost.localdomain. Step: umount; Details: umount Succeeded.
2012-Sep-24, 10:17:14 Installing Host localhost.localdomain. Step: doUpgrade; Details: Upgrade Succeeded. Rebooting.
2012-Sep-24, 10:17:14 Installing Host localhost.localdomain. Step: setMountPoint; Details: Mount succeeded..
2012-Sep-24, 10:16:27 Installing Host localhost.localdomain. Step: RHEV_INSTALL; Details: Connected to Host 10.66.11.139 with SSH key fingerprint: 75:59:4c:6c:78:66:f5:41:01:22:7c:8d:d3:95:68:50.
2012-Sep-24, 10:16:27 Host localhost.localdomain parameters were updated by admin@internal.
2012-Sep-24, 10:16:16 Host localhost.localdomain was switched to Maintenance mode by admin@internal.
2. But rhevh was not rebooted and upgraded,as far as i know,it didn't do anything about upgrade on rhevh side.After manual reboot RHEV-H,check that only one version can be selected to boot
Comment 20 haiyang,dong 2012-10-10 01:53:59 EDT
Version:
vdsm-4.9.6-36.0
rhev-hypervisor6-6.3-20121005.0.rhev31.el6_3

Try to upgrade rhev-hypervisor6-6.3-20121005.0.rhev31.el6_3 to rhev-hypervisor6-6.3-20121005.0.rhev31.el6_3  via rhevm.

Test result:
1.RHEVM shows that upgrade rhev-h successfully.
2.After upgrade successful, wait for a while,RHEV-H can automatic reboot.But on rhevh side,the grub.conf missed the content of the backup version after upgraded successfully via RHEVM, for this issue,has been reported BZ#863982 to track it.
Comment 23 Alon Bar-Lev 2012-10-24 11:10:16 EDT
*** Bug 869653 has been marked as a duplicate of this bug. ***
Comment 25 errata-xmlrpc 2012-12-04 14:07:38 EST
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.

http://rhn.redhat.com/errata/RHSA-2012-1508.html

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