Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1961944

Summary: Kickstart installations fail when a previous installation contains an lvm snapshot
Product: Red Hat Enterprise Linux 9 Reporter: Jan Stodola <jstodola>
Component: python-blivetAssignee: Blivet Maintenance Team <blivet-maint-list>
Status: CLOSED CURRENTRELEASE QA Contact: Release Test Team <release-test-team-automation>
Severity: high Docs Contact:
Priority: unspecified    
Version: 9.0CC: mlewando, vtrefny
Target Milestone: betaKeywords: Triaged
Target Release: ---Flags: pm-rhel: mirror+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: python-blivet-3.4.0-2.el9 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-12-07 21:24:13 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: 1942219    

Description Jan Stodola 2021-05-19 06:10:42 UTC
This bug was initially created as a copy of Bug #1961739

Anaconda fails to re-install a system with an existing LVM snapshot.

Error in storage.log:

ERROR:anaconda.modules.storage.installation:Failed to create storage layout: device path does not exist or is not writable
Traceback (most recent call last):
  File "/usr/lib64/python3.9/site-packages/pyanaconda/modules/storage/installation.py", line 82, in run
    self._turn_on_filesystems(
  File "/usr/lib64/python3.9/site-packages/pyanaconda/modules/storage/installation.py", line 162, in _turn_on_filesystems
    storage.do_it(callbacks)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/blivet.py", line 115, in do_it
    self.devicetree.actions.process(callbacks=callbacks, devices=self.devices)
  File "/usr/lib/python3.9/site-packages/blivet/actionlist.py", line 48, in wrapped_func
    return func(obj, *args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/actionlist.py", line 327, in process
    action.execute(callbacks)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/deviceaction.py", line 752, in execute
    self.format.destroy()
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/formats/__init__.py", line 552, in destroy
    self._pre_destroy(**kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/formats/__init__.py", line 565, in _pre_destroy
    raise DeviceFormatError("device path does not exist or is not writable")
blivet.errors.DeviceFormatError: device path does not exist or is not writable

Versions:
RHEL-9.0.0-20210518.3
anaconda-34.25.0.4-1.el9
python3-blivet-3.3.3-2.el9

Steps to reproduce:
1. create an LVM snapshot on an installed system
2. start a new kickstart installation with the following ks commands:

bootloader --location=mbr
zerombr
clearpart --all --initlabel
autopart

Actual results:
Installation fails.

Expected results:
Installation clears previous data and installs new system.