Bug 851838 - Anaconda selects wrong logical volume if there are more Fedora installs in VG
Anaconda selects wrong logical volume if there are more Fedora installs in VG
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: anaconda (Show other bugs)
17
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Anaconda Maintenance Team
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-26 07:05 EDT by Adam Pribyl
Modified: 2012-12-14 12:26 EST (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-12-14 12:26:10 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)
screenshot showing error "Unable to read package metadata." (26.43 KB, image/png)
2012-09-13 00:55 EDT, Steve Tyler
no flags Details
anaconda-tb-Fw3szi (319.67 KB, text/plain)
2012-09-13 01:06 EDT, Steve Tyler
no flags Details

  None (edit)
Description Adam Pribyl 2012-08-26 07:05:03 EDT
Description of problem:

Using preupgrade to upgrade F16 to F17 on a system where in VG are two LVs.

First with F16, second with another Fedora install (this case F17). 
The preupgrade was run from F16 install. After reboot and selection of the "Upgrade to F17" from GRUB, the anaconda selects as a partition to mount to /mnt/sysimage the LV from existing F17 install, instead the LV the preupgrade was started on and mounts in to /mnt/sysimage. This causes the install to fail as it can not find a preupgrade repo.

There should be and option in anaconda set in the "Upgrade to" GRUB option, to select proper partition to be mounted as /mnt/sysimage. If it exist (I did not found it), this should be moved to preupgrade to include this option in the GRUB menu.
Comment 1 Steve Tyler 2012-09-13 00:55:30 EDT
Created attachment 612348 [details]
screenshot showing error "Unable to read package metadata."

I believe this happened to me too when I used preupgrade to upgrade from F16 to F17. In my case, the incorrectly mounted file systems were on their own partitions on a second hard drive. My work-around was to unplug the second hard drive, complete the upgrade, and then replug the hard drive. I have reproduced a similar scenario using two VM disk images. The attached screenshot shows the error message when the incorrect file systems are mounted.

Procedure:
1. Create two VM disk images:
   f16-test-1.img
   f16-test-2.img
2. Partition f16-test-2.img without logical volumes and install a minimal F16.
   Use the default partitioning on f16-test-1.img and install F16 with a graphical desktop.
   yum update
   reboot
   yum install preupgrade
   preupgrade
   (To speed installation, install only base, X, gnome, fonts.)
3. Reboot and choose preupgrade from the grub menu.

Command line:
$ qemu-kvm -m 1024 -hda f16-test-1.img -hdb f16-test-2.img -cdrom ~/xfr/fedora/F16/Fedora-16-x86_64-DVD.iso -boot menu=on
Comment 2 Steve Tyler 2012-09-13 01:06:32 EDT
Created attachment 612349 [details]
anaconda-tb-Fw3szi
Comment 3 Steve Tyler 2012-09-13 14:00:50 EDT
For the record:

[root@phobos ~]# parted /dev/sda print
Model: ATA QEMU HARDDISK (scsi)
Disk /dev/sda: 12.9GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number  Start   End     Size    File system  Name  Flags
 1      1049kB  2097kB  1049kB                     bios_grub
 2      2097kB  526MB   524MB   ext4         ext4  boot
 3      526MB   12.9GB  12.4GB                     lvm

[root@phobos ~]# parted /dev/sdb print
Model: ATA QEMU HARDDISK (scsi)
Disk /dev/sdb: 6442MB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number  Start   End     Size    File system     Name  Flags
 1      1049kB  2097kB  1049kB                        bios_grub
 2      2097kB  526MB   524MB   ext4            ext4  boot
 3      526MB   1600MB  1074MB  linux-swap(v1)
 4      1600MB  6441MB  4841MB  ext4

[root@phobos ~]# blkid | sort
/dev/mapper/vg_phobos-lv_root: UUID="68baf222-22c6-41ad-a12d-6ebf5e0a71c2" TYPE="ext4" 
/dev/mapper/vg_phobos-lv_swap: UUID="25a7aa00-611c-4026-b1c9-b94c481847f6" TYPE="swap" 
/dev/sda2: UUID="323e4778-960e-43c5-8660-42da7bb90390" TYPE="ext4" 
/dev/sda3: UUID="i5DU2n-x8pn-VCvR-p2Dp-9vb8-sPXi-P6ll76" TYPE="LVM2_member" 
/dev/sdb2: UUID="5ed6a149-fa73-4d45-ad72-2e8081d93f5c" TYPE="ext4" 
/dev/sdb3: UUID="107cc39f-e31c-4805-b9ec-28d493e58452" TYPE="swap" 
/dev/sdb4: UUID="80dd1128-11a2-4038-897f-4d39c0e8c2dc" TYPE="ext4" 
/dev/sr0: LABEL="Fedora 16 x86_64 DVD" TYPE="iso9660" 
[root@phobos ~]# 

Command line:
$ qemu-kvm -m 1024 -hda f16-test-1.img -hdb f16-test-2.img -cdrom ~/xfr/fedora/F16/Fedora-16-x86_64-DVD.iso -boot menu=on
Comment 4 Chris Lumens 2012-12-14 12:26:10 EST
For F18, anaconda is no longer in the upgrade business, and preupgrade is no longer a usable tool for performing upgrades.  We're now recommending fedup, and it does not use anaconda at all.  Thus, this code is not involved anymore and this bug report should no longer be applicable.  If you are continuing to see upgrade problems for F18, please file a new bug against fedup.  Thanks for the report.

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