Bug 806494

Summary: KeyError: '/boot/efi'; UEFI fresh install crashes and destroys existing UEFI boot
Product: [Fedora] Fedora Reporter: John Reiser <jreiser>
Component: anacondaAssignee: Anaconda Maintenance Team <anaconda-maint-list>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 17CC: anaconda-maint-list, awilliam, g.kaviyarasu, jonathan, robatino, vanmeeuwen+fedora
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-03-24 20:51:36 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 752649    
Attachments:
Description Flags
anaconda traceback and debug info
none
storage.log
none
anaconda.log
none
program.log
none
syslog none

Description John Reiser 2012-03-24 04:27:56 UTC
Created attachment 572397 [details]
anaconda traceback and debug info

Description of problem: On a box that already has an existing UEFI grub2 boot of Fedora 17, then fresh install of Fedora-17-Beta-RC1-x86_64-DVD onto another existing [empty] partition crashes, and makes the box unbootable.


Version-Release number of selected component (if applicable):
anaconda-17.14

How reproducible: haven't tried


Steps to Reproduce:
1. Fresh install Fedora-17-Beta-RC1-x86_64-DVD onto an existing empty partition on a box which already has another Fedora 17 system.
2.
3.
  
Actual results:
anaconda 17.14 exception report
Traceback (most recent call first):
  File "/usr/lib64/python2.7/site-packages/pyanaconda/bootloader.py", line 1514, in add_efi_boot_target
    boot_efi = self.storage.mountpoints["/boot/efi"]
  File "/usr/lib64/python2.7/site-packages/pyanaconda/bootloader.py", line 1535, in install
    self.add_efi_boot_target()
  File "/usr/lib64/python2.7/site-packages/pyanaconda/bootloader.py", line 1551, in write
    self.install()
  File "/usr/lib64/python2.7/site-packages/pyanaconda/bootloader.py", line 2337, in writeBootloader
    anaconda.bootloader.write()
  File "/usr/lib64/python2.7/site-packages/pyanaconda/dispatch.py", line 383, in dispatch
    self.dir = self.steps[self.step].target(self.anaconda)
  File "/usr/lib64/python2.7/site-packages/pyanaconda/dispatch.py", line 247, in go_forward
    self.dispatch()
  File "/usr/lib64/python2.7/site-packages/pyanaconda/gui.py", line 1201, in nextClicked
    self.anaconda.dispatch.go_forward()
  File "/usr/lib64/python2.7/site-packages/pyanaconda/iw/progress_gui.py", line 79, in renderCallback
    self.intf.icw.nextClicked()
  File "/usr/lib64/python2.7/site-packages/pyanaconda/gui.py", line 1221, in handleRenderCallback
    self.currentWindow.renderCallback()
KeyError: '/boot/efi'

and attempting to re-boot the box hangs without bringing up grub2.

Expected results: success: box with two bootable systems (each on own partition)


Additional info:

Comment 1 John Reiser 2012-03-24 04:28:38 UTC
Created attachment 572398 [details]
storage.log

Comment 2 John Reiser 2012-03-24 04:29:08 UTC
Created attachment 572399 [details]
anaconda.log

Comment 3 John Reiser 2012-03-24 04:29:35 UTC
Created attachment 572400 [details]
program.log

Comment 4 John Reiser 2012-03-24 04:29:59 UTC
Created attachment 572401 [details]
syslog

Comment 5 John Reiser 2012-03-24 04:37:14 UTC
If reproducible, then I suggest that either this bug blocks F17 Beta, or the Release Notes carries a big warning about data destruction.

Comment 6 Adam Williamson 2012-03-24 05:02:05 UTC
What kind of partition layout did you select? Did you choose manual partitioning or one of the automatic options? If automatic, which one? If manual, what layout did you go with? Thanks!



-- 
Fedora Bugzappers volunteer triage team
https://fedoraproject.org/wiki/BugZappers

Comment 7 John Reiser 2012-03-24 14:06:53 UTC
Custom layout, choose existing 15GiB partition as root (/), no other partitions chosen for processing by anaconda.  [The .log files should confirm this?]

The [one only] drive has a GPT partition table, and the layout is approximately [from my memory; current damaged state hinders access]:
    partition 1   200MB  FAT[16 ?]  EFI System Partition
    partition 2    60GB  FAT32  [empty; space for that other OS]
    partition 3     1GB  swap
    partition 4    15GB  ext4  old Fedora 17
    partition 5    15GB  ext4  new Fedora 17
followed by about 400GB of unallocated space.  There is some unallocated space, usually small, between some of the partitions due to alignment, room for expansion, etc.

The new partition 5 was created by gparted running under the old Fedora 17.  I pre-allocate partitions (and then use the installer to format them only) because in years gone by this was a convenient way to get exact size and alignment.

Comment 8 Adam Williamson 2012-03-24 20:50:16 UTC
You need an EFI system partition to have a valid EFI install. A single / partition is not a valid layout for an EFI install. I think we already have a bug for adjusting manual partitioning to enforce this, somewhere...



-- 
Fedora Bugzappers volunteer triage team
https://fedoraproject.org/wiki/BugZappers

Comment 9 Adam Williamson 2012-03-24 20:51:36 UTC
The fact that anaconda doesn't create a new EFI bootloader entry for multiple Fedora EFI installs, but instead overwrites the previous one, is https://bugzilla.redhat.com/show_bug.cgi?id=759303 . You hit a combination of #748209 and #759303, I believe.

*** This bug has been marked as a duplicate of bug 748209 ***