Bad disk removal
Hey all,
So after lots of scans and log review, turns out 1 of the 8 IDE disks in my LVM is bad. (I know, IDE, yeahyeah...)
I currently have the affected volume group online, and it's mounted in XFS readonly,norecovery mode. XFS can't attempt repair because one of the bad sectors is the superblock so xfs_repair bombs.
Unfortunately I don't have 1.2TB of free space available to try and pull all the data off the VG before rebuilding it and replacing the failed drive. If I get a replacement for the bad drive and extend the VG, my question would be:
How fault tolerant is pvmove if it encounters unreadable/bad sectors on a disk? Will I hose the entire VG if pvmove bombs? Will pvmove skip the bad sectors after a few attempts and move on? Will pvmove refuse to even try?
I'm sure someone's had experience with this before. :) (Obviously I don't have RAID underneath the LVM, otherwise I'm sure this would be moot... lesson learned.)
Thanks all,
-Barnaby
Quoted 4 lines · Barnaby Claydon
Hey all,
So after lots of scans and log review, turns out 1 of the 8 IDE disks in my LVM is bad. (I know, IDE, yeahyeah...)
When this happened to me, I got a replacement drive as large as that drive, and used dd to copy the PV data bit-by-bit to the new disk, and then zeroed the sectors corresponding to the old bad sectors. It worked fairly well, but the bad sectors were probably only file data blocks for me.
As far as I managed to find out, pvmove will not handle bad sectors at all, and abort when it finds any. It would be great if anyone could correct me on that, though...
Fredrik Tolf
Quoted 12 lines · Fredrik Tolf
Quoted 4 lines · Barnaby Claydon
Hey all,
So after lots of scans and log review, turns out 1 of the 8 IDE disks in my LVM is bad. (I know, IDE, yeahyeah...)
When this happened to me, I got a replacement drive as large as that drive, and used dd to copy the PV data bit-by-bit to the new disk, and then zeroed the sectors corresponding to the old bad sectors. It worked fairly well, but the bad sectors were probably only file data blocks for me.
Quoted 4 lines
As far as I managed to find out, pvmove will not handle bad sectors at all, and abort when it finds any. It would be great if anyone could correct me on that, though...
pvmove will ignore errors and copy as much as it can. It will not retry failed sectors though. pvmove basically mirrors the drives, so you can use the volume while the device is being copied. When the copy is complete, pvmove breaks the mirror and leaves you with the LV remapped to the new device.
brassow
Quoted 5 lines · Jonathan E Brassow
pvmove will ignore errors and copy as much as it can. It will not retry failed sectors though. pvmove basically mirrors the drives, so you can use the volume while the device is being copied. When the copy is complete, pvmove breaks the mirror and leaves you with the LV remapped to the new device.
Really? I was sure the manpage said otherwise, but now that I look again, it doesn't seem to be saying anything at all about it. Should it not be amended to explain this?
By the way, what happens to the sectors on the new disk that corresponds to the bad ones on the old disk, and would that affect only that sector on the new disk, or the entire containing PE?
Fredrik Tolf