Bug 146054 - clearpart should delete ext3 (and other) meta data from existing partitions
clearpart should delete ext3 (and other) meta data from existing partitions
Product: Fedora
Classification: Fedora
Component: anaconda (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Chris Lumens
Mike McLean
Depends On:
Blocks: FC6Blocker
  Show dependency treegraph
Reported: 2005-01-24 18:10 EST by Dax Kelson
Modified: 2007-11-30 17:10 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2006-09-21 23:21:34 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Dax Kelson 2005-01-24 18:10:12 EST
Description of problem:

In a classroom or lab environment when multiple installs are being
performed on a machine, anaconda and clearpart don't clear enough.

In a FC3 test lab, we are seeing freshly kickstarted machines having
ext3 labels such as "/boot1", "/var/1", and "/usr1".

The kickstart lines we are using are as follows:

clearpart --all --initlabel
part /boot --fstype ext3 --ondisk=hda --size 100
part /     --fstype ext3 --ondisk=hda --size 2060
part swap --ondisk=hda --size 512
part /usr --fstype ext3 --ondisk=hda --size 7925
part /tmp --fstype ext3 --ondisk=hda --size 300
part /var --fstype ext3 --ondisk=hda --size 500

In a related issue, when we create software RAID or LVM using the
exact same commands on the fresh install as were used during the
previous install we get a bunch of complaints from the raidtools/mdadm
and lvm tools about "existing" volumes, etc.

This is very common in a classroom environment.


Either by default, or with an additional switch to clearpart have it
zero out (dd if=/dev/zero ...) the first one megabyte of each
pre-existing partition before it blows away the table and creates a
new table.

Thanks for your consideration.
Comment 1 Jeremy Katz 2005-02-01 22:33:45 EST
Maybe we should try to use parted's clobber stuff...
Comment 2 Dax Kelson 2005-02-02 11:27:07 EST
I don't have any insight on the way it should be implemented properly.

Here is our current workaround:

for i in `(fdisk -l /dev/hda ; fdisk -l /dev/sda) | grep -v Ext | egrep
'^/dev/.da[0-9]*' | sed 's/ .*//' | sort -r`; do dd if=/dev/zero of=$i count=1
bs=1M; done
Comment 3 Sitsofe Wheeler 2005-02-05 19:08:21 EST
This sounds similar to bug #145732 ...
Comment 4 Chris Lumens 2005-06-24 15:25:03 EDT
clobber doesn't look all that helpful.  I'll look into implementing our own
stuff in anaconda for wiping out labels and other identifying filesystem
Comment 5 Jeremy Katz 2006-09-21 23:21:34 EDT
We have clobbering now

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