Bug 1688478

Summary: [RHEL8][anaconda] Anaconda crashing when LVM part is in ignoredisk
Product: Red Hat Enterprise Linux 8 Reporter: PaulB <pbunyan>
Component: anacondaAssignee: Vladimír Slávik <vslavik>
Status: CLOSED ERRATA QA Contact: Release Test Team <release-test-team-automation>
Severity: high Docs Contact: Alexandra Nikandrova <anikandr>
Priority: high    
Version: 8.0CC: azelinka, bugproxy, dlehman, hannsj_uhl, jbastian, jfeeney, jikortus, jkonecny, jrusz, jstodola, mhavrila, pbunyan, rvykydal, sbueno, sjalgaon, vslavik
Target Milestone: rc   
Target Release: 8.3   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: anaconda-33.16.3.1-2 Doc Type: Bug Fix
Doc Text:
.Anaconda now cancels the installation with an error message when there are storage devices, that back up volume group and are ignored for the installation Previously, Anaconda did not verify if all storage devices and physical volumes (PVs), which were part of LVM volume group (VG), were accessible to the installer. That meant the Kickstart `ignoredisk` command was used to ignore disks and partitions which contained part of the VG. As a consequence, LVM forbade such setup and Anaconda would crash. With this update, Anaconda now checks whether the disks are not ignored for the installation, and in case they are, it cancels the installation with an error message. As a result, Anaconda no longer crashes when PVs of a VG are placed on the `ignoredisk` by the Kickstart file.
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-11-04 03:22:50 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:
Bug Depends On:    
Bug Blocks: 1515824, 1746605, 1776265, 1794767    
Attachments:
Description Flags
installer logs none

Description PaulB 2019-03-13 19:50:45 UTC
Description of problem:
Testing target system listed in  comment #1,
 ignoredisk not working as expected 

Version-Release number of selected component (if applicable):
distro: RHEL-8.0.0-20190228.1
kernel: 4.18.0-77.el8 
anaconda: 29.19.0.36-1.el8

How reproducible:
consistently

Steps to Reproduce:
1. Install target system listed in comment #1 with RHEL-8.0.0-20190228.1
   with   ignoredisk --drives=nvme0n1
2.


Actual results:
job: 
https://beaker.engineering.redhat.com/jobs/3410821

job kickstart: 
https://beaker.engineering.redhat.com/kickstart/5245468
---<-snip->---
ignoredisk --drives=nvme0n1
zerombr
clearpart --all --initlabel
---<-snip->---

job console log:
http://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2019/03/34108/3410821/6616991/console.log

anaconda.log:
http://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2019/03/34108/3410821/6616991/anaconda.log
---<-snip->---
  File "/usr/lib/python3.6/site-packages/blivet/formats/__init__.py", line 559, in _pre_destroy
    raise DeviceFormatError("device is active")

blivet.errors.DeviceFormatError: device is active
---<-snip->---

anaconda exception report:
https://beaker.engineering.redhat.com/recipes/6616991/logs/anaconda-tb-hcvr_y0b


Expected results:
 Successful installation of system


Additional info:

Comment 1 PaulB 2019-03-13 19:57:31 UTC
All,
This issue was seen while testing the following system:
 host: cav-sabre-cn99xx-01
 hostfirmware:  BIOS Date: 01/18/2019 16:19:21 Ver: 0ACKL025

-------------------------------------------
We see the system can successfully install:
-------------------------------------------
distro: RHEL-8.0.0-20190228.1
kernel: 4.18.0-77.el8 
https://beaker.engineering.redhat.com/jobs/3411202
http://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2019/03/34112/3411202/6617620/console.log
---<-snip->---
Creating disklabel on /dev/nvme0n1         
Creating lvmpv on /dev/nvme0n1p1       
Creating disklabel on /dev/sda           
Creating xfs on /dev/sda2         
---<-snip->---

Kernel 4.18.0-77.el8.aarch64 on an aarch64 
cav-sabre-cn99xx-01 login:
---<-snip->---


We see that the system has an NVMe device from both the above install as well as the system Beaker inventory:
https://beaker.engineering.redhat.com/view/cav-sabre-cn99xx-01.khw3.lab.eng.bos.redhat.com#details
PCIe Data Center SSD 	STORAGE 	pci 	nvme 	8086 	0953 	8086 	370a 


I wanted to AVOID installation on the NVMe on target system:
  host: cav-sabre-cn99xx-01

--------------------------------------------------------
Here is a reproducer using   ignoredisk --drives=nvme0n1
--------------------------------------------------------
job: 
https://beaker.engineering.redhat.com/jobs/3410818

job kickstart: 
https://beaker.engineering.redhat.com/kickstart/5245432
---<-snip->---
ignoredisk --drives=nvme0n1
zerombr
clearpart --all --initlabel
---<-snip->---

job console log:
http://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2019/03/34108/3410818/6616987/console.log

anaconda.log:
http://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2019/03/34108/3410818/6616987/anaconda.log

anaconda exception report:
http://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2019/03/34108/3410818/6616987/anaconda-tb-uqromjo8

--------------------------------------------------------
Here is a reproducer using   ignoredisk --only-use=sda
--------------------------------------------------------
job: 
https://beaker.engineering.redhat.com/jobs/3411116

job kickstart: 
https://beaker.engineering.redhat.com/kickstart/5245797
---<-snip->---
ignoredisk --only-use=sda
zerombr
clearpart --all --initlabel
---<-snip->---

job console log:
http://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2019/03/34111/3411116/6617427/console.log

anaconda.log:
http://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2019/03/34111/3411116/6617427/anaconda.log

anaconda exception report:
http://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2019/03/34111/3411116/6617427/anaconda-tb-xij5etxf


Best,
-pbunyan

Comment 2 PaulB 2019-03-13 19:58:47 UTC
All,
I would reference the following doc:
https://docs.fedoraproject.org/en-US/Fedora/html/Installation_Guide/sect-kickstart-commands-ignoredisk.html

Am I over looking something here?

Best,
-pbunyan

Comment 6 John Feeney 2020-01-09 23:14:10 UTC
Any status on this?

Comment 15 Vladimír Slávik 2020-03-02 15:55:08 UTC
*** Bug 1584729 has been marked as a duplicate of this bug. ***

Comment 16 Vladimír Slávik 2020-03-02 15:58:10 UTC
*** Bug 1698570 has been marked as a duplicate of this bug. ***

Comment 19 Jan Stodola 2020-04-16 13:48:47 UTC
*** Bug 1797488 has been marked as a duplicate of this bug. ***

Comment 20 IBM Bug Proxy 2020-04-16 16:00:51 UTC
Created attachment 1679430 [details]
installer logs

Comment 26 Marek Havrila 2020-07-15 10:16:14 UTC
Verified on RHEL-8.3.0-20200701.2 and anaconda-33.16.3.10-1.el8.x86_64.

Comment 33 Jiri Konecny 2020-09-16 09:21:42 UTC
*** Bug 1754547 has been marked as a duplicate of this bug. ***

Comment 36 errata-xmlrpc 2020-11-04 03:22:50 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (anaconda bug fix and enhancement update), and where to find the updated
files, follow the link below.

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

https://access.redhat.com/errata/RHBA-2020:4729