Discussion:
[linux-lvm] device failure during pvmove
Bryan Larsen
2016-01-15 01:38:34 UTC
Permalink
I was in the process of doing a pvmove from /dev/md3 to a new, blank
/dev/md1 when /dev/md1 failed due to operator stupidity.

I tried doing a pvmove abort, but it complains about a missing device. It
suggests doing a vgreduce --removemissing but that refuses to proceed
without a --force because pvmove has placed data onto the broken and
missing /dev/md1.

So theoretically all my data should still be available on /dev/md3. Any
hints on how to proceed?

Sorry for the inexact messages, the failed machine no longer has a root
partition so is only accessible from the console.

thanks,
Bryan
Bryan Larsen
2016-01-15 02:29:59 UTC
Permalink
Post by Bryan Larsen
I was in the process of doing a pvmove from /dev/md3 to a new, blank
/dev/md1 when /dev/md1 failed due to operator stupidity.
I tried doing a pvmove abort, but it complains about a missing device.
It suggests doing a vgreduce --removemissing but that refuses to proceed
without a --force because pvmove has placed data onto the broken and
missing /dev/md1.
So theoretically all my data should still be available on /dev/md3. Any
hints on how to proceed?
I solved the problem. I did a vgcfgdump, carefully edited the resulting
file, and used vgcfgrestore to bring things back to life.

cheers,
Bryan
Zdenek Kabelac
2016-01-15 11:53:32 UTC
Permalink
Post by Bryan Larsen
I was in the process of doing a pvmove from /dev/md3 to a new, blank
/dev/md1 when /dev/md1 failed due to operator stupidity.
I tried doing a pvmove abort, but it complains about a missing device.
It suggests doing a vgreduce --removemissing but that refuses to proceed
without a --force because pvmove has placed data onto the broken and
missing /dev/md1.
So theoretically all my data should still be available on /dev/md3. Any
hints on how to proceed?
I solved the problem. I did a vgcfgdump, carefully edited the resulting
file, and used vgcfgrestore to bring things back to life.
If you have enabled archiving - you could use archived metadata before
you started pvmove.


Also if you have 'recent enough' version of lvm2 - check '--atomic' option
for pvmove.

Regards

Zdenek

Loading...