[Bug 1209923] New: YaST Partitioner produces invalid GPT (on USB drive) after removing two partitions
http://bugzilla.opensuse.org/show_bug.cgi?id=1209923 Bug ID: 1209923 Summary: YaST Partitioner produces invalid GPT (on USB drive) after removing two partitions Classification: openSUSE Product: openSUSE Tumbleweed Version: Current Hardware: x86-64 OS: openSUSE Tumbleweed Status: NEW Severity: Major Priority: P5 - None Component: YaST2 Assignee: yast2-maintainers@suse.de Reporter: opensuse.k1akb@slmail.me QA Contact: jsrain@suse.com Found By: --- Blocker: --- I started up YaST2 Partitioner. I insert a USB drive (that contained the OpenSUSE Tumbleweed installation image, but probably irrelevant) and use the partitioner to remove the 2 existing partitions. I let the partitioner apply the modifications and close it. What happens: - in KDE, the storage/removable device mount notifications show the medium is refreshed/reloaded and shows as if the partitions still exist. (Reports on OpenSUSE Tumbleweed partition) - `sudo gdisk -l /dev/sda` reports a corrupt GPT partition. What I expected: - KDE to detect a drive without partitions, therefore nothing to mount. - YaST2 Partitioner to make the modifications such that there are no corruptions, i.e. `gdisk` reports no errors and changes are applied without surprises :-) NOTE: (obviously) I lost no valuable data (except for the OpenSUSE Tumbleweed image, of course), but I would think twice to trust YaST2 for making changes to drivers purposed for backup/long-term storage. ``` user@host ~> sudo gdisk -l /dev/sda [sudo] password for user: GPT fdisk (gdisk) version 1.0.9.1 Caution: invalid main GPT header, but valid backup; regenerating main header from backup! Warning: Invalid CRC on main header data; loaded backup partition table. Warning! Main and backup partition tables differ! Use the 'c' and 'e' options on the recovery & transformation menu to examine the two tables. Warning! Main partition table CRC mismatch! Loaded backup partition table instead of main partition table! Warning! One or more CRCs don't match. You should repair the disk! Main header: ERROR Backup header: OK Main partition table: ERROR Backup partition table: OK Partition table scan: MBR: MBR only BSD: not present APM: not present GPT: damaged Found valid MBR and corrupt GPT. Which do you want to use? (Using the GPT MAY permit recovery of GPT data.) 1 - MBR 2 - GPT 3 - Create blank GPT Your answer: ^C��� user@host ~ [SIGINT]> ``` Not sure which packages belong to YaST2 Partitioner: rpm -qa | grep yast2 ``` yast2-bootloader-4.6.0-1.1.x86_64 yast2-metapackage-handler-4.6.0-1.1.noarch yast2-online-update-frontend-4.6.1-1.1.noarch yast2-packager-4.6.0-1.1.x86_64 patterns-yast-yast2_basis-20220411-1.4.x86_64 yast2-journal-4.6.0-1.1.noarch yast2-python3-bindings-4.6.0-1.2.x86_64 yast2-sysconfig-4.6.0-1.1.noarch yast2-alternatives-4.6.0-1.1.x86_64 patterns-yast-yast2_desktop-20220411-1.4.x86_64 yast2-country-data-4.6.0-1.1.x86_64 yast2-security-4.6.0-1.1.noarch yast2-xml-4.6.0-1.2.x86_64 yast2-core-4.6.0-1.2.x86_64 yast2-printer-4.6.0-1.1.x86_64 yast2-perl-bindings-4.6.0-1.2.x86_64 yast2-users-4.6.0-1.2.x86_64 yast2-network-4.6.0-1.1.noarch yast2-update-4.6.0-1.1.x86_64 yast2-qt-branding-openSUSE-84.87.20230227-1.1.noarch yast2-apparmor-4.6.0-1.1.noarch patterns-yast-x11_yast-20220411-1.4.x86_64 yast2-ruby-bindings-4.6.1-1.2.x86_64 yast2-pkg-bindings-4.6.0-1.2.x86_64 yast2-x11-4.6.0-1.1.x86_64 yast2-theme-4.6.0-1.1.noarch yast2-control-center-qt-4.6.0-1.2.x86_64 yast2-storage-ng-4.6.2-1.1.x86_64 patterns-kde-kde_yast-20221001-2.1.noarch yast2-ycp-ui-bindings-4.6.0-1.2.x86_64 yast2-online-update-4.6.1-1.1.noarch yast2-ntp-client-4.6.0-1.1.noarch yast2-theme-breeze-4.6.0-1.1.noarch yast2-logs-4.6.1-1.1.x86_64 yast2-pam-4.6.0-1.1.noarch yast2-services-manager-4.6.0-1.1.noarch yast2-proxy-4.6.0-1.1.noarch yast2-country-4.6.0-1.1.x86_64 yast2-firewall-4.6.0-1.1.noarch yast2-trans-stats-2.19.0-17.26.noarch yast2-hardware-detection-4.6.0-1.2.x86_64 yast2-control-center-4.6.0-1.2.x86_64 yast2-vm-4.6.0-1.1.x86_64 yast2-installation-4.6.1-1.1.noarch yast2-ldap-4.6.0-1.2.x86_64 yast2-4.6.1-1.1.x86_64 yast2-snapper-4.6.0-1.1.x86_64 yast2-transfer-4.6.0-1.2.x86_64 ``` rpm -qa | grep openSUSE-release ``` openSUSE-release-appliance-custom-20230326-2183.1.x86_64 openSUSE-release-20230326-2183.1.x86_64 ``` -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1209923 http://bugzilla.opensuse.org/show_bug.cgi?id=1209923#c1 --- Comment #1 from OpenSUSE Account <opensuse.k1akb@slmail.me> --- Please note that I use the same USB drive often for installation images. If the information does not match up perfectly with how the OpenSUSE Tumbleweed image is composed, this may be a contributing factor. Regardless, of how the situation came to be, it may be good to consider that we went from a valid to a corrupted state with the operating system reporting on incorrect or obsolete partition information. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1209923 http://bugzilla.opensuse.org/show_bug.cgi?id=1209923#c5 --- Comment #5 from OpenSUSE Account <opensuse.k1akb@slmail.me> --- Thanks for clarifying. To add a detail: it is an 8 GB USB stick, so definitely somewhat larger than the images it typically holds. I had the same scenario in mind. I understand that there might be remnants already before YaST Partitioner was run. However, I am left with the following concerns: 1. Before running YaST, I had an operational OpenSUSE Tumbleweed USB drive (i.e. image correct, recently used.) Afterwards, I had a USB drive of which KDE *thinks* there is an installation image, but the partitions are actually removed.[1] Or said otherwise, YaST thinks the partitions are gone, while KDE thinks they exist and are available. 2. Even in less-than-ideal circumstances, I would think that the partitioner at least recognizes that there are inconsistencies: either to fix to perform the job as expected, or to warn about to let the user know, or as a reason to refuse operation because it might lead to unexpected results. Please note that I wanted to clarify my reason for informing you. I realize if this is an edge case outside of immediate concern. I'll leave it at this, unless there are follow-up questions. [1] Note that I understand that the actual bytes of data still exist and merely the definition of the partitions (sizes, boundaries, parameters) have been deleted. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1209923 http://bugzilla.opensuse.org/show_bug.cgi?id=1209923#c8 --- Comment #8 from OpenSUSE Account <opensuse.k1akb@slmail.me> --- @stefan: I am guessing you do not want to make this a long discussion. So I will say that equating "warning of an issue" with "restriction actions" is not correct. Furthermore, a properly constructed image is complete and consistent, and I assume you do not claim that the openSUSE Tumbleweed installation images are broken. Regardless, I intended to make you aware of a possible situation you might want inspect, and now you are aware of this situation. -- You are receiving this mail because: You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@suse.com