Detect secure a clean hard disk.

2012-02-05 Thread Andreas Schockenhoff
Hi, i am searching for a small shell script that detects, if the hard disk is clean. I will use it for virtual machines. There I create always new clean virtuell hard disks. I will stop the installation if the hard disk is not clean. I will use it for easy automatic fai-cd testing. To be sure t

Re: Detect secure a clean hard disk.

2012-02-05 Thread Michał Dwużnik
Hi, keep in mind that members of software RAID, lvm physical volumes and so on may house the data despite zeroed out first sector: #dd if=/dev/md0 of=file count=1 1+0 records in 1+0 records out 512 bytes (512 B) copied, 0.00886503 s, 57.8 kB/s #dd if=/dev/zero of=zero count=1 1+0 records in 1

Re: Detect secure a clean hard disk.

2012-02-06 Thread Andreas Schockenhoff
Hi, Am Sonntag, den 05.02.2012, 14:44 +0100 schrieb Michał Dwużnik: > keep in mind that members of software RAID, lvm physical volumes and > so on may house the data despite zeroed out first sector: > > #dd if=/dev/md0 of=file count=1 > 1+0 records in > 1+0 records out > 512 bytes (512 B) copi