!66 修复brtfs分区mount参数问题导致anaconda无法移除所有的brtfs分区
From: @chenxi-mao Reviewed-by: @t_feng Signed-off-by: @t_feng
This commit is contained in:
commit
bd10e288ac
@ -0,0 +1,36 @@
|
|||||||
|
From 0b672ff4527ccbb7b7527f1ab2394fa36738b27f Mon Sep 17 00:00:00 2001
|
||||||
|
From: Vojtech Trefny <vtrefny@redhat.com>
|
||||||
|
Date: Thu, 27 Jan 2022 17:53:06 +0100
|
||||||
|
Subject: [PATCH 1/1] Make sure we mount the top level subvolume when mounting
|
||||||
|
btrfs
|
||||||
|
|
||||||
|
If we don't specify the subvolid=5 we end up mounting the default
|
||||||
|
subvolume and if it isn't the top volume one, we can't remove
|
||||||
|
other subvolumes "higher" in the hierarchy.
|
||||||
|
|
||||||
|
This makes the installer crash when reinstalling over a preexisting
|
||||||
|
btrfs installation, for example the default openSUSE installation
|
||||||
|
where the default subvolume is a post installation snapshot.
|
||||||
|
|
||||||
|
Resolves: rhbz#2026205
|
||||||
|
---
|
||||||
|
blivet/devices/btrfs.py | 3 ++-
|
||||||
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/blivet/devices/btrfs.py b/blivet/devices/btrfs.py
|
||||||
|
index 3b9374fc..6629ba95 100644
|
||||||
|
--- a/blivet/devices/btrfs.py
|
||||||
|
+++ b/blivet/devices/btrfs.py
|
||||||
|
@@ -123,7 +123,8 @@ class BTRFSDevice(StorageDevice):
|
||||||
|
else:
|
||||||
|
tmpdir = tempfile.mkdtemp(prefix=self._temp_dir_prefix)
|
||||||
|
try:
|
||||||
|
- util.mount(device=fmt.device, mountpoint=tmpdir, fstype=fmt.type)
|
||||||
|
+ util.mount(device=fmt.device, mountpoint=tmpdir, fstype=fmt.type,
|
||||||
|
+ options=fmt.mountopts)
|
||||||
|
except errors.FSError as e:
|
||||||
|
log.debug("btrfs temp mount failed: %s", e)
|
||||||
|
raise
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
Name: python-blivet
|
Name: python-blivet
|
||||||
Version: 3.4.2
|
Version: 3.4.2
|
||||||
Release: 1
|
Release: 2
|
||||||
Epoch: 1
|
Epoch: 1
|
||||||
Summary: A python module for system storage configuration
|
Summary: A python module for system storage configuration
|
||||||
License: LGPLv2+
|
License: LGPLv2+
|
||||||
@ -20,6 +20,7 @@ BuildRequires: python2-devel python2-setuptools
|
|||||||
Patch0: 0001-force-lvm-plugin.patch
|
Patch0: 0001-force-lvm-plugin.patch
|
||||||
Patch1: fix-the-long-hostname.patch
|
Patch1: fix-the-long-hostname.patch
|
||||||
Patch9000: fix-allocate-partitions-threw-exception-when-raid.patch
|
Patch9000: fix-allocate-partitions-threw-exception-when-raid.patch
|
||||||
|
Patch9001: 0001-Make-sure-we-mount-the-top-level-subvolume-when-moun.patch
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -122,6 +123,9 @@ make PYTHON=%{__python2} DESTDIR=%{buildroot} install
|
|||||||
%doc README.md
|
%doc README.md
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Jul 28 2022 Chenxi Mao <chenxi.mao@suse.com> - 3.4.2-2
|
||||||
|
- Fix remove subvolumes error on brtfs during installation.
|
||||||
|
|
||||||
* Wed Dec 15 2021 yangcheng <yangcheng87@huawei.com> - 3.4.2-1
|
* Wed Dec 15 2021 yangcheng <yangcheng87@huawei.com> - 3.4.2-1
|
||||||
- DESC:Upgrade to 3.4.2
|
- DESC:Upgrade to 3.4.2
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user