From b7348cf8ea8eb078f58cc7da2a16633c6873ad08 Mon Sep 17 00:00:00 2001 From: bitcoffee <854182924@qq.com> Date: Wed, 19 May 2021 15:03:53 +0800 Subject: [PATCH] Fix issue when ns_info cannot be retrieved for NVDimm namespace (cherry picked from commit e7cac4650b62d99c907fb404eb6e6d088f298a5d) --- anaconda.spec | 101 +++++++++++++++++- ...s_info-cannot-be-retrieved-for-NVDim.patch | 48 +++++++++ 2 files changed, 147 insertions(+), 2 deletions(-) create mode 100644 bugfix-Fix-issue-when-ns_info-cannot-be-retrieved-for-NVDim.patch diff --git a/anaconda.spec b/anaconda.spec index 6b962d6..cc4aae1 100644 --- a/anaconda.spec +++ b/anaconda.spec @@ -1,7 +1,7 @@ %define _empty_manifest_terminate_build 0 Name: anaconda Version: 33.19 -Release: 13 +Release: 22 Summary: Graphical system installer License: GPLv2+ and MIT URL: http://fedoraproject.org/wiki/Anaconda @@ -43,6 +43,61 @@ Patch6008: fix-remove-unknow-partition-is-sda-failed.patch Patch9024: Change-length-limit-of-hostname-from-255-to-64.patch +Patch6020: bugfix-Schedule-timed-actions-with-the-right-selector-18516.patch +Patch6021: bugfix-Reset-the-state-of-the-custom-partitioning-spoke.patch +Patch6022: bugfix-Fix-regression-reading-kernel-list-when-collecting-c.patch +Patch6023: bugfix-Fix-more-SElinux-contexts.patch +Patch6024: bugfix-Fix-issue-when-NFS-path-is-pointing-directly-to-ISO-.patch +Patch6025: bugfix-Create-the-initial-storage-model-during-the-initiali.patch +Patch6026: bugfix-Always-specify-the-boot-disk.patch +Patch6027: bugfix-Fix-passing-of-arguments-when-creating-dracut-argume.patch +Patch6028: bugfix-Reconfigure-DNF-payload-after-options-are-set.patch +Patch6029: bugfix-Only-pass-one-initrd-image-to-kexec.patch +Patch6030: bugfix-Fix-creating-cached-LVs-on-encrypted-PVs.patch +Patch6031: bugfix-Run-actions-of-the-Resize-dialog-in-the-reversed-ord.patch +Patch6032: bugfix-Reload-treeinfo-repositories-on-every-payload-reset.patch +Patch6033: bugfix-Remove-treeinfo-repositories-instead-of-disabling.patch +Patch6034: bugfix-Fix-crash-on-first-entering-of-source-spoke.patch +Patch6035: bugfix-Keep-treeinfo-repositories-disabled-after-payload-re.patch +Patch6036: bugfix-Fix-issue-that-treeinfo-repositories-were-never-disa.patch +Patch6037: bugfix-Fix-kickstart-file-error-with-user-groups.patch +Patch6038: bugfix-Create-ssh-user-using-only-existing-fields-1860058.patch +Patch6039: bugfix-Automatically-break-lines-in-labels-in-software-sele.patch +Patch6040: bugfix-Reset-the-RAID-level-of-the-device-request-1828092.patch +Patch6041: bugfix-Change-keyboard-ordering-to-US-layout-first-native-s.patch +Patch6042: bugfix-Handle-exceptions-from-threads-without-new-instances.patch +Patch6043: bugfix-network-fix-configuration-of-virtual-devices-by-boot.patch +Patch6044: bugfix-network-do-not-try-to-activate-connection-that-has-n.patch +Patch6045: bugfix-network-add-timeout-for-synchronous-activation-of-a-.patch +Patch6046: bugfix-Fix-traceback-when-removing-additional-repository.patch +Patch6047: bugfix-network-do-not-crash-when-updating-a-connection-with.patch +Patch6048: bugfix-Do-not-mount-as-RW-in-Dracut.patch +Patch6049: bugfix-The-underline-character-should-not-be-displayed.patch +Patch6050: bugfix-Recognize-systemd.unit-anaconda.target-in-anaconda-g.patch +Patch6051: bugfix-Always-clear-treeinfo-metadata-1872056.patch +Patch6052: bugfix-Apply-onboot-policy-even-when-network-was-configured.patch +Patch6053: bugfix-network-fix-parsing-of-hostname-from-ip-if-mac-is-de.patch +Patch6054: bugfix-Don-t-generate-container-data-for-non-container-devi.patch +Patch6055: bugfix-Differentiate-between-RAID-levels-of-a-device-and-it.patch +Patch6056: bugfix-Show-warning-message-when-entered-size-is-not-valid.patch +Patch6057: bugfix-Add-the-DBus-method-IsDeviceShrinkable-1875677.patch +Patch6058: bugfix-Check-if-original-partitions-are-mounted-too.patch +Patch6059: bugfix-network-get-hwadddr-when-binding-to-mac-more-robustl.patch +Patch6060: bugfix-Fix-the-combo-box-for-an-URL-type-of-additional-repo.patch +Patch6061: bugfix-Never-mount-partitions-on-a-disk-with-the-iso9660-fi.patch +Patch6062: bugfix-Add-missing-make-BuildRequires.patch +Patch6063: bugfix-Allow-to-format-selected-DASDs.patch +Patch6064: bugfix-Add-selinux-0-boot-parameter-when-SELinux-is-set-to-.patch +Patch6065: bugfix-Root-password-is-mandatory-if-there-is-not-admin-use.patch +Patch6066: bugfix-Fix-traceback-when-starting-installation-with-inst.c.patch +Patch6067: bugfix-Fix-checking-ssl-certificate-for-metadata-1745064.patch +Patch6068: bugfix-Fix-error-in-initrd-shift-count-out-of-range.patch +Patch6069: bugfix-Fix-the-logic-for-enabling-latest-updates.patch +Patch6070: bugfix-Don-t-enter-spokes-after-we-leave-the-Summary-hub.patch +Patch6071: bugfix-do-not-mount-dbus-source.patch +Patch6072: fix-xorg-timeout-and-throw-exception.patch +Patch6073: bugfix-Fix-issue-when-ns_info-cannot-be-retrieved-for-NVDim.patch + %define dbusver 1.2.3 %define dnfver 3.6.0 %define dracutver 034-7 @@ -255,7 +310,49 @@ update-desktop-database &> /dev/null || : %{_datadir}/gtk-doc %changelog -* Thu Dec 10 2020 zhouyihang - 33.19-13 +* Wed May 19 2021 liuxin - 33.19-22 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:Fix issue when ns_info cannot be retrieved for NVDimm namespace + +* Sat May 8 2021 fengtao - 33.19-21 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:fix xorg timeout and throw exception + +* Thu Apr 29 2021 zhangrui - 33.19-20 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:do not mount dbus sources + +* Mon Mar 29 2021 xuxiaolong - 33.19-19 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:sync 50 bugfix commit from github + +* Sat Mar 27 2021 zhangrui - 33.19-18 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:reset the state of the custom partiting spoke + +* Thu Feb 4 2021 liuxin264 - 33.19-17 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:fix Propagate a lazy proxy of the storage model + +* Thu Jan 14 2021 yuboyun - 33.19-16 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:set up LD_PRELOAD for the Storage and Services module + +* Thu Dec 10 2020 zhouyihang - 33.19-15 - Type:bugfix - ID:NA - SUG:NA diff --git a/bugfix-Fix-issue-when-ns_info-cannot-be-retrieved-for-NVDim.patch b/bugfix-Fix-issue-when-ns_info-cannot-be-retrieved-for-NVDim.patch new file mode 100644 index 0000000..0b22559 --- /dev/null +++ b/bugfix-Fix-issue-when-ns_info-cannot-be-retrieved-for-NVDim.patch @@ -0,0 +1,48 @@ +From 49f6e0e64accb5a1e6590bb08f7986fe7eaec2de Mon Sep 17 00:00:00 2001 +From: Jiri Konecny +Date: Thu, 29 Oct 2020 10:08:09 +0100 +Subject: [PATCH] Fix issue when ns_info cannot be retrieved for NVDimm + namespace + +If we don't skip this part the uncaught exception will raise because we +are +trying to concatenate string and None types. + +This is happening when NVDIMM namespace is set to DEVDAX mode. In this +mode +there is no device to be returned so we will got None from blivet. + +Resolves: rhbz#1891827 +(cherry picked from commit 6afc375b164a802e26802ec4ba54d3446c078091) +--- + pyanaconda/modules/storage/nvdimm/nvdimm.py | 9 +++++++-- + 1 file changed, 7 insertions(+), 2 deletions(-) + +diff --git a/pyanaconda/modules/storage/nvdimm/nvdimm.py b/pyanaconda/modules/storage/nvdimm/nvdimm.py +index 4476dd1..5b9c9dc 100644 +--- a/pyanaconda/modules/storage/nvdimm/nvdimm.py ++++ b/pyanaconda/modules/storage/nvdimm/nvdimm.py +@@ -101,6 +101,12 @@ class NVDIMMModule(KickstartBaseModule): + devices_to_ignore = set() + + for ns_name, ns_info in nvdimm.namespaces.items(): ++ # this is happening when namespace is set to DEVDAX mode - block device is not present ++ if ns_info.blockdev is None: ++ log.debug("%s will be skipped - NVDIMM namespace block device information " ++ "can't be retrieved", ns_name) ++ continue ++ + info = udev.get_device(device_node="/dev/" + ns_info.blockdev) + + if info and udev.device_get_format(info) == "iso9660": +@@ -116,8 +122,7 @@ class NVDIMMModule(KickstartBaseModule): + else: + continue + +- if ns_info.blockdev: +- devices_to_ignore.add(ns_info.blockdev) ++ devices_to_ignore.add(ns_info.blockdev) + + return devices_to_ignore + + -- Gitee