代码拉取完成,页面将自动刷新
同步操作将从 src-openEuler/anaconda 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
From ad48d3ab850c9dd40908a51eae3580fcc148e171 Mon Sep 17 00:00:00 2001
From: xqrustc2020 <69908158+xqrustc2020@users.noreply.github.com>
Date: Tue, 29 Sep 2020 13:16:43 +0800
Subject: [PATCH] fix remove unkown partition in sda failed
fix: cannot create partition when sda exists a ext4 filesystem.
When you clicked the "-" button, only the format on sda should be
destroyed without removing sda from the device tree, but sda
was also destroyed. As a result, sda cannot be found during disk
initialization and an error was reported.
Resolves: rhbz#1878661
---
.../modules/storage/partitioning/interactive/utils.py | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/pyanaconda/modules/storage/partitioning/interactive/utils.py b/pyanaconda/modules/storage/partitioning/interactive/utils.py
index b52876a..fe7bd59 100644
--- a/pyanaconda/modules/storage/partitioning/interactive/utils.py
+++ b/pyanaconda/modules/storage/partitioning/interactive/utils.py
@@ -1046,8 +1046,10 @@ def _destroy_device(storage, device):
:param device: an instance of a device
"""
# Remove the device.
- if device.is_disk and device.partitioned and not device.format.supported:
- storage.recursive_remove(device)
+ if device.is_disk:
+ if device.partitioned and not device.format.supported:
+ storage.recursive_remove(device)
+ storage.initialize_disk(device)
elif device.direct and not device.isleaf:
# We shouldn't call this method for with non-leaf devices
# except for those which are also directly accessible like
@@ -1057,10 +1059,6 @@ def _destroy_device(storage, device):
else:
storage.destroy_device(device)
- # Initialize the disk.
- if device.is_disk:
- storage.initialize_disk(device)
-
# Remove empty extended partitions.
if getattr(device, "is_logical", False):
storage.remove_empty_extended_partitions()
--
2.23.0
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。