[svlug] Detecting 'virgin' disks ?

Joe Buck Joe.Buck at synopsys.COM
Tue Jul 26 13:43:46 PDT 2005


On Tue, Jul 26, 2005 at 07:39:41AM -0700, Steve wrote:
> > Anyone know a 'safe' method for detecting 'virgin' disks (disks that 
> > have never been formatted...)
> > I'm doing an installer, which will have to run MBR on these disks in 
> > addition to partitioning them.

On Tue, Jul 26, 2005 at 01:29:52PM -0700, Ian Kluft wrote:
> Before drawing conclusions, you'll probably need to check what people find
> on their new drives from various manufacturers.  I would expect that the
> results will vary with each manufacturer, maybe even among divisions of
> a manufacturer.

It seems that you want to avoid wiping out valid data, but there's no
end to the variety of invalid data you might encounter.  As Ian says, it
might be a test pattern, and every manufacturer might have a different
one.  A USB disk I recently bought came with an empty VFAT filesystem
filling the disk, and this seems common for removable media.

I'd suggest seeing if it has a valid partition table and valid
filesystems (of any of the common types).  You might decide to treat
completely empty filesystems differently (since overwriting them doesn't
cause data loss).




More information about the svlug mailing list