Skip to contentSkip to conversation

pvmove on the same PV

linux-lvm Aran Cox 3 participants 3 messages Dec 7, 2004

lore
Share & tools
lore

Aran Cox

author
#0 lore raw

Is it possible to move an extent from one position to another on the same PV? It used to be possible under LVM1.

The reason I ask is that a long time ago I wrote a sort of LVM defrag/repacker program. Basically it was a higher level interface to the pvmove program. I wrote it because when I would shrink a LV and enlarge another on a mostly utilized VG the logical extents would end up highly non-contiguous, especially after a few such re-organizations.

In any case, I was updating it for LVM2 today and it seems that pvmove refuses to move an extent from one position on a PV to another position on the same PV. I guess I can work around this but it means lots of wasted moves. Also, I'd be happy to share this tool if anyone's remotely interested, once I've updated it for LVM2.

Thanks,

Signature · 1 line
Aran Cox <[email protected]>
#1 lore raw
Quoted 5 lines · Aran Cox

In any case, I was updating it for LVM2 today and it seems that pvmove refuses to move an extent from one position on a PV to another position on the same PV. I guess I can work around this but it means lots of wasted moves. Also, I'd be happy to share this tool if anyone's remotely interested, once I've updated it for LVM2.

I've been thinking of writing something similar for awhile. It would be a nice thing to have.

Signature · 3 lines
The best we can hope for concerning the people at large is that they
be properly armed.  -- Alexander Hamilton
-- Eric Hopper ([email protected]  http://www.omnifarious.org/~hopper) --
#2 lore raw
In reply to Aran Cox
Quoted 2 lines · Aran Cox

Is it possible to move an extent from one position to another on the same PV? It used to be possible under LVM1.

pvmove --alloc anywhere

tells overrides normal common-sense restrictions.

Alasdair

Signature · 1 line
[email protected]