Bug 1883195 - /etc/multipath/conf.d is not copied correctly
Summary: /etc/multipath/conf.d is not copied correctly
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: imgbased
Classification: oVirt
Component: General
Version: 1.2.12
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ovirt-4.4.3
: 1.2.13
Assignee: Nir Levy
QA Contact: peyu
URL:
Whiteboard:
Depends On:
Blocks: 1889738
TreeView+ depends on / blocked
 
Reported: 2020-09-28 11:54 UTC by Jean-Louis Dupond
Modified: 2021-06-09 09:11 UTC (History)
11 users (show)

Fixed In Version: imgbased-1.2.13
Doc Type: Bug Fix
Doc Text:
Previously, when performing an upgrade of the Red Hat Virtualization Host, the directory holding configuration files on the Manager was not created correctly. In this release, the directory is created correctly during an upgrade.
Clone Of:
Environment:
Last Closed: 2020-11-11 06:41:40 UTC
oVirt Team: Node
Embargoed:
pm-rhel: ovirt-4.4+
peyu: testing_plan_complete+
peyu: testing_ack+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 111495 0 master MERGED osupdater: migrate_etc, copy folders to correct dirname 2021-01-10 07:29:02 UTC
oVirt gerrit 111740 0 ovirt-4.3 MERGED osupdater: migrate_etc, copy folders to correct dirname 2021-01-10 07:29:02 UTC

Description Jean-Louis Dupond 2020-09-28 11:54:11 UTC
Description of problem:
When upgrading oVirt, I noticed /etc/multipath/conf.d files were not copied correctly.

Instead of having the file in /etc/multipath/conf.d it ended up in /etc/multipath/conf.d/conf.d/


How reproducible:
Every upgade


Steps to Reproduce:
1. Put something in /etc/multipath/conf.d/
2. Upgrade oVirt
3. Files are now in /etc/multipath/conf.d/conf.d/

Expected results:
Should be in /etc/multipath/conf.d/


Additional info:

The cp is not correct, as it causes to copy the folder (and not the content of it) in the conf.d folder. So you end up with conf.d/conf.d/conf.d after upgrades :)

imgbased.log:2020-09-28 12:55:57,430 [DEBUG] (migrate_etc) Calling: (['cp', '-a', '-r', '/tmp/mnt.G9iGb///etc/multipath/conf.d', '/tmp/mnt.cM6Nj///etc/multipath/conf.d'],) {'close_fds': True, 'stderr': -2}

Comment 1 peyu 2020-09-29 05:16:58 UTC
QE can reproduce this bug.

Test versions:
RHVH: redhat-virtualization-host-4.4.1-20200722.0.el8_2
      redhat-virtualization-host-4.4.2-20200918.0.el8_2

Test steps:
1. Install RHVH-4.4-20200722.1-RHVH-x86_64-dvd1.iso
2. Add host to RHVM
3. Create a directory under /etc and put a file in it
~~~~~~
# cd /etc/
# mkdir bug1883195
# cd /etc/bug1883195/
# vi reproducebug.txt
# cat /etc/bug1883195/reproducebug.txt 
reproduce bug-1883195 2020-09-29 02
~~~~~~
4. Setup local repos and point to "redhat-virtualization-host-4.4.2-20200918.0.el8_2"
5. Upgrade host via RHVM
6. Check the directories and files created in step 3

Test results:
1. The folder created by user in /etc is not copied correctly.
~~~~~~
# cd /etc/bug1883195/
# ll
total 4
drwxr-xr-x. 2 root root 30 Sep 29 04:15 bug1883195
-rw-r--r--. 1 root root 36 Sep 29 04:27 reproducebug.txt


# ll /etc/bug1883195/bug1883195/
total 4
-rw-r--r--. 1 root root 36 Sep 29 04:15 reproducebug.txt
~~~~~~

As you can see the folder "bug1883195" was copied to its own directory.

The existing test cases only test the copy of the files in the /etc directory. I will add a new test case for directory copy.

Comment 2 Sandro Bonazzola 2020-09-29 14:43:51 UTC
Was this happening also before 4.4.2? Or is this a regression we introduced in 4.4.2?

Comment 3 peyu 2020-09-30 02:19:18 UTC
This issue also occurs when upgrading RHVH from 4.3.10 to 4.3.11.

Comment 6 RHEL Program Management 2020-10-20 07:48:28 UTC
The documentation text flag should only be set after 'doc text' field is provided. Please provide the documentation text and set the flag to '?' again.

Comment 7 peyu 2020-10-26 02:54:23 UTC
This issue has been resolved on "redhat-virtualization-host-4.4.3-20201008.0.el8_3".

Move the bug status to "VERIFIED".

Comment 8 Sandro Bonazzola 2020-11-11 06:41:40 UTC
This bugzilla is included in oVirt 4.4.3 release, published on November 10th 2020.

Since the problem described in this bug report should be resolved in oVirt 4.4.3 release, it has been closed with a resolution of CURRENT RELEASE.

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


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