Bug 1557957 - TypeError: __init__() got an unexpected keyword argument 'wwn'
Summary: TypeError: __init__() got an unexpected keyword argument 'wwn'
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: python-blivet
Version: 28
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Blivet Maintenance Team
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:1116bc4a03dcde07589c7bd7c05...
Depends On:
Blocks: F28BetaBlocker
TreeView+ depends on / blocked
 
Reported: 2018-03-19 11:23 UTC by Kamil Páral
Modified: 2018-03-26 22:29 UTC (History)
17 users (show)

Fixed In Version: python-blivet-3.0.0-0.6.b1.fc28
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-03-26 22:29:41 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
File: anaconda-tb (455.99 KB, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: anaconda.log (7.77 KB, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: dbus.log (2.77 KB, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: environ (616 bytes, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: journalctl (271.54 KB, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: lsblk_output (2.27 KB, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: nmcli_dev_list (2.05 KB, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: os_info (596 bytes, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: program.log (40.76 KB, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: storage.log (90.11 KB, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details
File: ifcfg.log (2.14 KB, text/plain)
2018-03-19 11:23 UTC, Kamil Páral
no flags Details

Description Kamil Páral 2018-03-19 11:23:15 UTC
Description of problem:
Anaconda crashes immediately on startup when I have 3 disks in my PC, sda is a standard drive, and sdb+sdc are put into RAID0. All disks were completely wiped using dd (beginning and end of each disk) before creating the RAID volume and booting into LiveCD, so this bug should not be caused by any leftover data from previous installations.

Version-Release number of selected component:
anaconda-core-28.22.2-3.fc28.x86_64

The following was filed automatically by anaconda:
anaconda 28.22.2 exception report
Traceback (most recent call first):
  File "/usr/lib/python3.6/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/blivet/devices/md.py", line 681, in __init__
    super(MDBiosRaidArrayDevice, self).__init__(name, **kwargs)
  File "/usr/lib/python3.6/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/blivet/populator/helpers/disk.py", line 71, in run
    device = self._device_class(name, **kwargs)
  File "/usr/lib/python3.6/site-packages/blivet/populator/populator.py", line 263, in handle_device
    device = helper_class(self, info).run()
  File "/usr/lib/python3.6/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/blivet/populator/populator.py", line 462, in _populate
    self.handle_device(dev)
  File "/usr/lib/python3.6/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/blivet/populator/populator.py", line 412, in populate
    self._populate()
  File "/usr/lib/python3.6/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/blivet/blivet.py", line 161, in reset
    self.devicetree.populate(cleanup_only=cleanup_only)
  File "/usr/lib/python3.6/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib64/python3.6/site-packages/pyanaconda/storage/osinstall.py", line 1665, in reset
    super().reset(cleanup_only=cleanup_only)
  File "/usr/lib/python3.6/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib64/python3.6/site-packages/pyanaconda/storage/osinstall.py", line 2186, in storage_initialize
    storage.reset()
  File "/usr/lib64/python3.6/threading.py", line 864, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/lib64/python3.6/site-packages/pyanaconda/threading.py", line 291, in run
    threading.Thread.run(self)
TypeError: __init__() got an unexpected keyword argument 'wwn'

Additional info:
addons:         com_redhat_kdump
cmdline:        /usr/bin/python3  /sbin/anaconda --liveinst --method=livecd:///dev/mapper/live-base
cmdline_file:   BOOT_IMAGE=/images/pxeboot/vmlinuz root=live:CDLABEL=Fedora-WS-Live-28-20180318-n-0 rd.live.image quiet
executable:     /sbin/anaconda
hashmarkername: anaconda
kernel:         4.16.0-0.rc4.git0.1.fc28.x86_64
other involved packages: python3-libs-3.6.4-16.fc28.x86_64, python3-blivet-3.0.0-0.4.b1.fc28.noarch
product:        Fedora
release:        Fedora release 28 (Twenty Eight)
type:           anaconda
version:        28

Potential duplicate: bug 1557270

Comment 1 Kamil Páral 2018-03-19 11:23:23 UTC
Created attachment 1409815 [details]
File: anaconda-tb

Comment 2 Kamil Páral 2018-03-19 11:23:25 UTC
Created attachment 1409816 [details]
File: anaconda.log

Comment 3 Kamil Páral 2018-03-19 11:23:27 UTC
Created attachment 1409817 [details]
File: dbus.log

Comment 4 Kamil Páral 2018-03-19 11:23:28 UTC
Created attachment 1409818 [details]
File: environ

Comment 5 Kamil Páral 2018-03-19 11:23:31 UTC
Created attachment 1409819 [details]
File: journalctl

Comment 6 Kamil Páral 2018-03-19 11:23:32 UTC
Created attachment 1409820 [details]
File: lsblk_output

Comment 7 Kamil Páral 2018-03-19 11:23:34 UTC
Created attachment 1409821 [details]
File: nmcli_dev_list

Comment 8 Kamil Páral 2018-03-19 11:23:35 UTC
Created attachment 1409822 [details]
File: os_info

Comment 9 Kamil Páral 2018-03-19 11:23:37 UTC
Created attachment 1409823 [details]
File: program.log

Comment 10 Kamil Páral 2018-03-19 11:23:39 UTC
Created attachment 1409824 [details]
File: storage.log

Comment 11 Kamil Páral 2018-03-19 11:23:41 UTC
Created attachment 1409825 [details]
File: ifcfg.log

Comment 12 Kamil Páral 2018-03-19 11:31:52 UTC
Proposing as a Beta blocker:
" The installer must be able to detect and install to hardware or firmware RAID storage devices."
https://fedoraproject.org/wiki/Fedora_28_Beta_Release_Criteria#Hardware_and_firmware_RAID

Comment 13 Vendula Poncova 2018-03-19 11:49:36 UTC
It looks to be a problem in the storage library, reassigning.

Comment 14 Adam Williamson 2018-03-19 21:23:46 UTC
Discussed at 2018-03-19 Fedora 28 blocker review meeting: https://meetbot-raw.fedoraproject.org/fedora-blocker-review/2018-03-19/f28-blocker-review.2018-03-19-16.02.html . Accepted as a blocker issue: this seems like a clear showstopper for installs to Intel firmware RAID sets, which is a violation of Beta criterion "The installer must be able to detect and install to hardware or firmware RAID storage devices".

Comment 15 Adam Williamson 2018-03-19 23:41:28 UTC
OK, so this is a bit twisty, but basically:

blivet/populator/helpers/disk.py defines a class DiskDevicePopulator , with a class attribute _device_class that's intended to be a Device subclass , and a method _get_kwargs() that - unless _device_class is DiskDevice - returns a dict with a 'wwn' key. It also has a 'run' method which does this:

        kwargs = self._get_kwargs()
        device = self._device_class(name, **kwargs)

There is a subclass of DiskDevicePopulator called MDBiosRaidDevicePopulator which defines _device_class as MDBiosRaidArrayDevice . That's a Device subclass - defined in blivet/blivet/devices/md.py - that takes **kwargs, but calls `super(MDBiosRaidArrayDevice, self).__init__(name, **kwargs)`. Its parent class is MDRaidArrayDevice, and *that* class - defined in the same file - does *not* take a 'wwn' kwarg.

MDBiosRaidDevicePopulator overrides the parent's (that's DiskDevicePopulator, remember) _get_kwargs(), but the child's method does start by calling the parent's:

    def _get_kwargs(self):
        kwargs = super(MDBiosRaidDevicePopulator, self)._get_kwargs()

it then does some stuff to *add* new kwargs, and later on it removes some:

        # remove some kwargs that don't make sense for md
        del kwargs["model"]
        del kwargs["serial"]
        del kwargs["vendor"]
        del kwargs["bus"]

but it does *not* remove wwn. Thus, ultimately, we wind up calling `MDRaidArrayDevice(wwn=something)` and we blow up.

Obvious fix: have MDBiosRaidDevicePopulator._get_kwargs() do:

        del kwargs["wwn"]

Also, check if there are any other cases where we should do this.

Comment 16 Adam Williamson 2018-03-19 23:52:39 UTC
https://github.com/storaged-project/blivet/pull/671 should fix this. If anyone wants to generate an updates.img and try it, go for it. Otherwise I'll try and post one later.

Comment 17 Fedora Update System 2018-03-20 21:37:04 UTC
python-blivet-3.0.0-0.6.b1.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2018-e6332fc675

Comment 18 Adam Williamson 2018-03-20 21:54:48 UTC
Here's an updates.img you can use to test the fix:

http://www.happyassassin.net/updates/1557957.0.img

can someone with an affected system please test an install of a recent F28 image with 'inst.updates=http://www.happyassassin.net/updates/1557957.0.img' ? I can't do it myself as I don't have an Intel fwraid motherboard any more :(

Comment 19 Lukas Ruzicka 2018-03-21 09:41:03 UTC
(In reply to Adam Williamson from comment #18)
> Here's an updates.img you can use to test the fix:
> 
> http://www.happyassassin.net/updates/1557957.0.img
> 
> can someone with an affected system please test an install of a recent F28
> image with 'inst.updates=http://www.happyassassin.net/updates/1557957.0.img'
> ? I can't do it myself as I don't have an Intel fwraid motherboard any more
> :(

Anaconda no longer crashes during start up so that problem seems to be fixed, but it still crashes later, during disk selection, see bug 1558906.

Comment 20 Fedora Update System 2018-03-21 14:13:56 UTC
python-blivet-3.0.0-0.6.b1.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-e6332fc675

Comment 21 Fedora Update System 2018-03-26 22:29:41 UTC
python-blivet-3.0.0-0.6.b1.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.


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