shutting down logical volumes once an underlying device fails?
A coworker has been testing failure scenarious using lvm, and noticed that when a PV fail a filesystem on a logical volume that spans multiple PVs only fails once it accesses the actually failed physical device.
At least for system using higher level error detection and replication behaviour that fails a LV as soon as one of the underlying devices fails would be much more helpful. Is the current LVM behaviour intention and should we work around this using userspace monitoring, or would be patches to introduce a shutdown state similar to what we have in XFS for example be welcome?
Quoted 10 lines · Christoph Hellwig
A coworker has been testing failure scenarious using lvm, and noticed that when a PV fail a filesystem on a logical volume that spans multiple PVs only fails once it accesses the actually failed physical device.
At least for system using higher level error detection and replication behaviour that fails a LV as soon as one of the underlying devices fails would be much more helpful. Is the current LVM behaviour intention and should we work around this using userspace monitoring, or would be patches to introduce a shutdown state similar to what we have in XFS for example be welcome?
Don't think any shutdown should be initiated by the kernel.
But events that userspace could respond to by deactivating (an arbitrarily complex) lvm device would be the way forward IMHO.
Could this tie back to needing better UA handling/notification between kernel<->userspace?
Quoted 5 lines · Mike Snitzer
Don't think any shutdown should be initiated by the kernel.
But events that userspace could respond to by deactivating (an arbitrarily complex) lvm device would be the way forward IMHO.
Deactivating is maybe a bit of a too strong word. But I'd expect we'll get EIO from al sectors not just those on the failed device.
Quoted 2 lines
Could this tie back to needing better UA handling/notification between kernel<->userspace?
That current proposed solution we have internally is to simply poll the status output for the PVs and handle it all in userspace. To me this seems a bit clumsy, but at least it's easily doable in short time.