[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ale] Bad Disk Blocks
- Subject: [ale] Bad Disk Blocks
- From: transam at cavu.com (Bob's ALE Mail)
- Date: Fri, 13 Dec 1996 18:12:23 -0500
How about:
dd if=/dev/hda1 of=/dev/null bs=1024k
Replace hda1 with whatever your disk devices are ("df" will list hose
mounted.)
If there are any bad blocks then you should see error messages.
Writing to a marginally bad block should clear it.
One possibility if you feel lucky is:
dd if=/dev/hda1 of=/dev/hda1 conv=sync,noerror bs=512
(ONLY do this if you fully understand it and have backups
in case something goes wrong such as a power failure.)
This simply reads each block and then writes it. If it hits a bad
(unreadable) block then it will write NULs to it, which probably will
clear any CRC errors. Repeating
dd if=/dev/hda1 of=/dev/null bs=1024k
will test for this. The first "dd" listed is always safe (unless
you mistype it) and I do it weekly on about 300GB of disk at the office.
Bob Toxen
bob at cavu.com
transam at cavu.com [ALE]
http://www.mindspring.com/~cavu
Fly-By-Day Consulting, Inc.
"Venimus, Vidimus, Dolavimus" (We came, we saw, we hacked)