Page 1 of 1

Bad Sector tools?

Posted: Wed Oct 11, 2006 11:52 am
by Judah
Is there a tool/program/command that can scan your hard drive
and block out bad sectors for linux? I think my hard-drive has
a few. The only way I would have guessed this is I have one of
those Hard-Drive "in-use" lights and when my system locks-up,
the hard-drive light is on and stays on ...

Any Suggestions?

Posted: Wed Oct 11, 2006 12:08 pm
by Tsuroerusu
I personally use Steve Gibson's SpinRite, I know this is a shameless plug, but this thing actually does work quite well.

Posted: Wed Oct 11, 2006 12:10 pm
by Wally Balljacker
Tsuroerusu wrote:I personally use Steve Gibson's SpinRite, I know this is a shameless plug, but this thing actually does work quite well.
Just out of curiosity, does SpinRite require Windows at all?

Posted: Wed Oct 11, 2006 12:12 pm
by Tsuroerusu
Wally Balljacker wrote:
Tsuroerusu wrote:I personally use Steve Gibson's SpinRite, I know this is a shameless plug, but this thing actually does work quite well.
Just out of curiousity, does SpinRite require Windows at all?
No it does not, you make a bootable CD, floppy or even USB thumbdrive with it and it boots up FreeDOS and runs SpinRite.

The boot-media-maker is a Windows program, but it runs perfect under Wine.

SpinRite is not free-of-charge, it costs 89 bucks, but there are ways around that ...
Especially since it only takes up like 197kbs (All written in Assembly) :P

Re: Bad Sector tools?

Posted: Thu Oct 12, 2006 8:07 am
by Gomer_X
Judah wrote:Is there a tool/program/command that can scan your hard drive
and block out bad sectors for linux? I think my hard-drive has
a few. The only way I would have guessed this is I have one of
those Hard-Drive "in-use" lights and when my system locks-up,
the hard-drive light is on and stays on ...

Any Suggestions?
IDE disk drives have spare sectors on each track (this includes SATA). They will mark bad sectors and move the data to a spare sector on the fly. This happens in the controller (on the dirve), and you won't see it happening.

If you see bad sectors, that means the drive has used up all it's spares and doesn't know what to do. This is a sign that you should get a backup and swap out the drive if you have anything important there.

I believe mkfs (and mke2fs and friends) will do a complete scan looking for bad sectors, but I don't know if it can do it without destroying data. I don't have a Linux system at hand, and can't check the man page.

Posted: Sat Oct 14, 2006 1:39 pm
by Judah
Maybe my extra sectors are filled up. This is a pretty old system.
This is a dual-boot system and when it actually started locking up on
the linux side, I knew it was probably a hardware issue.

Hmm, now I really wanna do a scan of some sort, just to see if I do get
bad sectors. I didn't know that was how IDE drives dealt with bad
sectors by shifting them over to a spare sector automatically..

Thanks for the info Gomer.. :wink: