Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a MD drive set in RAID6 configuration with LVM2 on top. One of my drives was faulted last night due to bad blocks. Now apart from the fact that I am aware I should physically replace the drive, I am wondering:

Can I feed MD a list of badblocks (such as I can with mke2fs -l [badblockslist]) in such a way that the these blocks are no longer used and effectively extend the life of the disk?

share|improve this question
up vote 3 down vote accepted

No, you can't. You should also check the drive's SMART status either with the gnome disk utility or with smartctl from the smartmontools package. If it is only a few bad sectors, md should have tried to rewrite them, which should have triggered the drive to automatically remap them to the spare pool. If you have enough bad sectors that the spare pool has run out, then you need to replace the drive immediately.

share|improve this answer
Actually, Linux 3.1 added bad block management in mdadm. So you can now. But I'm upvoting anyway, for the good advice on checking the disk status and getting them remapped. – derobert Jan 8 '13 at 19:10

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.