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 738182 - uninstall didn't wipe the boot disk
Summary: uninstall didn't wipe the boot disk
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: ovirt-node
Version: 6.2
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: rc
: ---
Assignee: Mike Burns
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-09-14 09:42 UTC by Mohua Li
Modified: 2011-12-06 19:27 UTC (History)
7 users (show)

Fixed In Version: ovirt-node-2.0.2-0.12.gitc05f24f.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-12-06 19:27:50 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Patch (1.69 KB, patch)
2011-09-15 19:14 UTC, Mike Burns
apevec: review+
Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:1783 0 normal SHIPPED_LIVE rhev-hypervisor6 bug fix and enhancement update 2011-12-06 15:10:54 UTC

Description Mohua Li 2011-09-14 09:42:58 UTC
Description of problem:

see Bug 736971  comment 10, although dracut could wipe the lvs, but won't wipe the root/rootbackup boot disk, which make it still bootable, but no any lvs, so can't login, 


Version-Release number of selected component (if applicable):
6.2-0.16.2,

How reproducible:
always

Steps to Reproduce:
1.install rhev-hypervisor first
2.try to uninstall it specify "uninstall " in kernel cmd line
3.
  
Actual results:
wiped the all lv, but didn't remove rootbackup/root

Expected results:


Additional info:

Comment 1 Mike Burns 2011-09-15 13:13:04 UTC
This is actually not an easy fix, though it might be doable.  The problem lies with the fact that we don't know what device to clean up with just "uninstall" in the kernel commandline.  We do most of the cleanup in dracut with detecting where HostVG, but the cleaning of the mbr is done in ovirt-early.  

There are a couple of approaches that we could take, though both are speculative until I try to implement them

1.  cleanup mbr in dracut as well -- not easy.  I think we would need to include sfdisk in dracut to determine the right places on the disk to cleanup

2.  We *could* leave the HostVG volume group after we're done with dracut and cleaning up all the LV's.  Then we can wipe HostVG, PVs and mbr from disks in ovirt-early.  Note:  this is a radical change since we don't individually clean up LVs now.  

3.  pass information to the running system from dracut -- I don't even know if this is technically possible, but it would solve the problem if we could.

There may be others, but none that I can think of at the moment.

Alan, any thoughts on the above?

Comment 2 Mike Burns 2011-09-15 19:14:50 UTC
Created attachment 523431 [details]
Patch

After discussion with Alan, we decided that we can detect the disk that contains Root and RootBackup partitions and wipe that.

Comment 5 Ying Cui 2011-10-13 07:18:03 UTC
Check this issue with RHEV-H 6.2-20111010.2 build. It is not fixed, After uninstall in kernel cmd, it didn't remove Rootbackup/Root. and it still can be bootable.

#pvs
#lvs
No volume groups found
#vgs
No volume groups found
#findfs LABEL=Root
/dev/sda2
#findfs LABEL=RootBackup
/dev/sda1

Assigned it.

Comment 6 Mike Burns 2011-10-13 14:10:01 UTC
Called the wrong function, so it wasn't wiping any disks.

diff --git a/scripts/ovirt-early b/scripts/ovirt-early
index 28ebd05..6c22054 100755
--- a/scripts/ovirt-early
+++ b/scripts/ovirt-early
@@ -679,7 +679,7 @@ start_ovirt_early () {
         oldIFS=$IFS
         log "Found uninstall arg, wiping mbr from init disks"
         IFS=$SEP
-        for init_disk in $init $init_app $(get_boot_disk); do
+        for init_disk in $init $init_app $(get_boot_device); do
             echo "Wiping $init_disk"
             wipe_mbr "$init_disk"
         done

Comment 9 errata-xmlrpc 2011-12-06 19:27:50 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2011-1783.html


Note You need to log in before you can comment on or make changes to this bug.