Subj : Re: bad sectors To : comp.os.linux From : David Kinsell Date : Mon Oct 18 2004 02:21 pm "Roland" wrote in message news:4173a867$0$15610$ba620e4c@news.skynet.be... > > "Sybren Stuvel" wrote in message > news:slrncn6smb.9ib.sybrenUSE@sybren.thirdtower.com... > > Roland enlightened us with: > > > If I have some bad sectors on a hard disk, is there any way to tell > > > linux (or the filesystem) not to use them? > > > > badblocks > > > > All right. But the man page says that badblocks can provide a list of bad > blocks to mke2fs, that is, _before_ the filesystem is created. > I have a partition on which bad blocks appeared long after I created the > filesystem, do I have to recreate the filesystem or can I add the list of > (new) bad blocks somewhere to the existing list. And what if this is a > reiserfs? > > (Sure the best option when new bad sectors appear on a disk is to buy a new > disk, but the problem seems to be stable so I want to continue with this > drive.) > If it's a SCSI disk, it almost certainly has the capability to hide bad sectors by mapping in spares. Easiest way is to do a low-level format and let the controller handle the issue, but individual blocks can also be spared if you can get the proper command to the disk. Not generally used, because most bad blocks that appear in the field are the warning signs of impending catastrophic failure. Make sure you do lots of backups, even if you do think the situation is stable. -Dave .