Bug 984841

Summary: installation crash : "DeviceTreeError: parent device not in tree" while unlocking an encrypted PV
Product: [Fedora] Fedora Reporter: Cedric Buissart <cbuissar>
Component: anacondaAssignee: David Lehman <dlehman>
Status: CLOSED EOL QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 19CC: anaconda-maint-list, dshea, g.kaviyarasu, jonathan, mkolman, sbueno, sschaefer, vanmeeuwen+fedora
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-02-17 16:10:52 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Anaconda crash details none

Description Cedric Buissart 2013-07-16 07:35:38 UTC
Created attachment 774052 [details]
Anaconda crash details

>> Description of problem:

My environment is slightly specific :
* I boot from grub1 and load F19's vmlinuz & initrd, with `repo=` to point to the usual F19's ISO.

* I install Fedora on a VG that is made of 1 encrypted PV

While configuring the installer, anaconda crashes when I unlock my encrypted PV.

>> Version-Release number of selected component (if applicable): 
* Fedora 19


>> How reproducible:
100% (crashed twice in 2 attempts)

>> Steps to Reproduce:
1. create an encrypted PV
2. installer environmnent : put the ISO in a USB disk, in /media/F19
3. install grub on that disk, and put F19's initrd & vmlinuz (taken from the isolinux folder)
4. boot on F19's initrd, with repo=hd:sdb1:/media/F19/
5. go to the disk layout, and attempt to unlock the encrypted PV

>> Actual results:

----8<----
anaconda 19.30.13-1 exception report
Traceback (most recent call first):
  File "/usr/lib/python2.7/site-packages/blivet/devicetree.py", line 266, in _addDevice
    raise DeviceTreeError("parent device not in tree")
  File "/usr/lib64/python2.7/site-packages/pyanaconda/ui/gui/spokes/custom.py", line 2786, in on_unlock_clicked
    self.__storage.devicetree._addDevice(luks_dev)
DeviceTreeError: parent device not in tree
---->8----

>> Expected results:
PV unlocked and presenting the VG's LVs.

>> Additional info:

* I have not tried that with Fedora 18. However, that was definitely working fine with the previous installer (I was doing the same with Fedora 15, 16 & 17)

Comment 1 Cedric Buissart 2013-07-16 08:12:22 UTC
Actually, at second glance, both crashes looks different (both crashes happened while unlocking but backtrace really looked different).

environment & action were identical

Comment 2 Cedric Buissart 2013-07-16 12:09:28 UTC
Simple Reproducer

-> preparation :
create a 2 MSDOS partition disk :
sda1 : ext4 FS
sda2 : luks device with a VG

-> Boot the standard F19 ISO

-> Installation destination : the disk above
-> Click "Done" and "Custom Partitioning"
-> Click "+", add a storage ( 50GB on / [anything bigger than available space]) and click "add mount point"; Anaconda will put a "Fail" message, normal 

-> Now try to unlock sda2, Anaconda will crash with the failure above.

=> It will not crash if you dont attempt to create the mount point first.

Comment 3 Cedric Buissart 2013-07-22 16:19:57 UTC
Logically speaking, I would tend to believe that the exception handler of the on_add_clicked event (event started when I attempt to create a file system to big to be handled) unexpectedly messes with the devicetree structure

Unfortunately, I am not too familiar with anaconda, nor python.

I am using `updates` to modify the usr/lib64/python2.7/site-packages/pyanaconda/ui/gui/spokes/custom.py file to dump self.__storage.devicetree from time to time to try to see where it is modified.

... but I am unsure how to print that layout.

What I would like to debug is :
-> In usr/lib64/python2.7/site-packages/pyanaconda/ui/gui/spokes/custom.py
Class CustomPartitioningSpoke -> function : on_add_clicked(self, button)

dump in the logs the full content of self.__storage.devicetree

Comment 4 Fedora End Of Life 2015-01-09 18:56:30 UTC
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 5 Fedora End Of Life 2015-02-17 16:10:52 UTC
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.