Bug 988685 - yum leaves empty directory when upgrading rhevm-setup
yum leaves empty directory when upgrading rhevm-setup
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine-setup (Show other bugs)
Unspecified Unspecified
urgent Severity high
: ---
: 3.3.0
Assigned To: Alon Bar-Lev
sefi litmanovich
Depends On:
  Show dependency treegraph
Reported: 2013-07-26 02:51 EDT by Jiri Belka
Modified: 2015-09-22 09 EDT (History)
11 users (show)

See Also:
Fixed In Version: is8
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
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
oVirt gerrit 17377 None None None Never

  None (edit)
Description Jiri Belka 2013-07-26 02:51:05 EDT
Description of problem:

# engine-upgrade 
++ readlink -f /usr/bin/engine-upgrade
+ script=/usr/share/ovirt-engine/setup/bin/ovirt-engine-setup
++ dirname /usr/share/ovirt-engine/setup/bin/ovirt-engine-setup
+ scriptdir=/usr/share/ovirt-engine/setup/bin
+ . /usr/share/ovirt-engine/setup/bin/ovirt-engine-setup.env
++ ENV=/etc/ovirt-engine-setup.env.d
+++ '[' -d /etc/ovirt-engine-setup.env.d ']'
+++ readlink -f /usr/bin/engine-upgrade
++ script=/usr/share/ovirt-engine/setup/bin/ovirt-engine-setup
+++ dirname /usr/share/ovirt-engine/setup/bin/ovirt-engine-setup
++ scriptdir=/usr/share/ovirt-engine/setup/bin
++ extraenv=
++ '[' -z '' ']'
++ '[' -n '' ']'
++ '[' -x /usr/share/ovirt-engine/setup/bin/otopi ']'
++ otopidir=/usr/sbin
+++ cd /usr/share/ovirt-engine/setup/bin
+++ pwd
++ export PYTHONPATH=/usr/share/ovirt-engine/setup/bin/..::
++ PYTHONPATH=/usr/share/ovirt-engine/setup/bin/..::
+ baseenv='"APPEND:BASE/pluginPath=str:/usr/share/ovirt-engine/setup/bin/../plugins" APPEND:BASE/pluginGroups=str:ovirt-engine-common:ovirt-engine-setup'
+ otopienv=
+ environment=
+ '[' -n '' ']'
+ exec /usr/sbin/otopi '"APPEND:BASE/pluginPath=str:/usr/share/ovirt-engine/setup/bin/../plugins" APPEND:BASE/pluginGroups=str:ovirt-engine-common:ovirt-engine-setup  '
***L:ERROR Internal error: No module named releasepreview

# rpm -qf /usr/share/ovirt-engine/setup/bin/../plugins/ovirt-engine-setup/releasepreview/
file /usr/share/ovirt-engine/setup/plugins/ovirt-engine-setup/releasepreview is not owned by any package

Version-Release number of selected component (if applicable):
is6 -> is7

How reproducible:

Steps to Reproduce:
1. try to upgrade from is6 to is7

Actual results:

Expected results:

Additional info:
Comment 1 Jiri Belka 2013-07-26 03:00:07 EDT
# ls -l /usr/share/ovirt-engine/setup/bin/../plugins/ovirt-engine-setup/releasepreview/
total 0
Comment 2 Lukas Svaty 2013-07-26 04:59:27 EDT
same behaviour with clean installation:

my steps:
1. engine-upgrade: Failed
2. engine-cleanup: Success
3. engine-setup: Failed
Comment 3 yeylon@redhat.com 2013-07-26 06:42:57 EDT
workaround - one can use old engine-upgrade.py directly instead of new
redesigned ovirt-engine-setup.

* works for upgrade:


* broken (new upgrade style):

# ls -l `which engine-upgrade`
lrwxrwxrwx. 1 root root 52 Jul 26 11:00 /usr/bin/engine-upgrade -> /usr/share/ovirt-engine/setup/bin/ovirt-engine-setup
Comment 4 Itamar Heim 2013-07-28 03:30:54 EDT
alon, similar to http://lists.ovirt.org/pipermail/users/2013-July/015436.html ?
Comment 5 Alon Bar-Lev 2013-07-28 03:49:00 EDT
(In reply to Itamar Heim from comment #4)
> alon, similar to
> http://lists.ovirt.org/pipermail/users/2013-July/015436.html ?

yes. I don't understand why yum do not cleanup files properly. files were in package then are not, they should have been removed.

jiri, you can just remove manually:


I will try to find some workaround for yum.
Comment 6 Alon Bar-Lev 2013-07-28 05:07:22 EDT
I can confirm that this happens with rhevm-setup, I cannot reproduce this with my own specs.

Attempting to understand the root cause.
Comment 7 Alon Bar-Lev 2013-07-28 07:41:36 EDT
So we have this issue with is6, and we cannot fix it in is7 as it already out... and even so, not sure it worth to fix issues from unstable to unstable.

But definitely this issue is important for future.
Comment 8 Alon Bar-Lev 2013-07-28 07:41:55 EDT
packaging: spec: setup: do not leave empty directories on remove

when installing files via wildcards, for example:

rpm does not record the directory within his archive, so upon removal
this directory is left, while the files are removed.

we do want to avoid the need to specify each file within the spec file,
as source tree is organized properly, we can add the top level.

however, in future if we have the need to split the directory structure
into two packages, we will have to work a bit harder while maintaining
the spec file, we may consider to generate it(?).

Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=988685
Change-Id: I63fe12c6f29ff82588dfabb5df93eaca12154c12
Signed-off-by: Alon Bar-Lev <alonbl@redhat.com>
Comment 9 Alon Bar-Lev 2013-08-01 05:25:16 EDT

As this is fixed in is8, verify can only be done at is9 or using custom build.
Comment 10 sefi litmanovich 2013-09-03 10:43:40 EDT
Upgrede from is11 to is12 works fine.
Proccess has changed and is done so:

1. Update REPO files
2. engine-upgrade-check
3. yum update rhevm-setup
4. engine-setup

No empty directory is left.
Comment 13 Itamar Heim 2014-01-21 17:30:24 EST
Closing - RHEV 3.3 Released
Comment 14 Itamar Heim 2014-01-21 17:30:30 EST
Closing - RHEV 3.3 Released
Comment 15 Itamar Heim 2014-01-21 17:33:29 EST
Closing - RHEV 3.3 Released

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