Re: disk bad block checking post-install / ext2
From: prg (rdgentry1_at_cablelynx.com)
Date: 11 Jan 2005 08:06:13 -0800
> does a utility exist to check a (SCSI) disk for bad blocks after
> It seems that badblocks is designed to run at filesystem creation
> only (and really designed to be called by the relevant mkfs utility).
> One of the 18GB SCSI drives in my home fileserver (ext2 filesystem)
> starting to throw up the occasional disk error on the OS drive, and
> although I have a spare I can use I'd rather check other options
> a) does anything exist to run a disk check whilst maintaining
As others noted, $ man badblocks -- _very_ carefully.
Also, check if you have smartmontools on your distro. $ man smartd
Check if you can get a disk diagnostic/repair utility from the maker:
> b) am I sort-of worrying about nothing because the SCSI firmware in
> drive itself is remapping bad blocks as soon as they're detected
As noted, you only have so much spare disk space for remapping. And
the re-mapping is only available on first write -- it the hd can't
_read_ the block with data it will _not_ re-map.
> Of course seeing any disk errors seems cause for concern so I should
> probably replace the drive soon - just a question of whether to do it
> or when I actually have a free moment!
> (Yes I do have regular backups before anyone asks ;)
(Keep them very handy!)
Badblocks is best run at fs creation time, but is handy afterwards
also. But to use it you must _know_ what you're doing _and_ generate a
table that the fs can read/use to avoid badblock marked blocks.
The hd badblock re-mapping _should_ be transparent, but if the hd can't
_read_ a block, it won't re-map it unless you force it (and likely lose
For smartmontools visit:
The more you use the flakey disks, the more likely you will lose data.
email above disabled