Snapshot resizing pe_allocated correction
Another slight fix. When a snapshot is resized, the volume groups' pe_allocated field is not updated. The following patch should fix this problem:
drivers/md/lvm.c renamed from drivers/md/lvm.c.orig +0 -0
@@ -2280,6 +2280,9 @@
return -ENOMEM; }
+ vg_ptr->pe_allocated -= old_lv->lv_allocated_snapshot_le;
+ vg_ptr->pe_allocated += new_lv->lv_allocated_le;
+
return 0; }
Accepted.
Please send patches relative to the head of CVS.
Thanks,
Heinz -- The LVM Guy --
Quoted 20 lines · Dale J. Stephenson
Another slight fix. When a snapshot is resized, the volume groups'
pe_allocatedfield is not updated. The following patch should fix this problem:drivers/md/lvm.c renamed from drivers/md/lvm.c.orig +3
-0@@ -2280,6 +2280,9 @@return -ENOMEM ; } + vg_ptr->pe_allocated -= old_lv->lv_allocated_snapshot_le; + vg_ptr->pe_allocated += new_lv->lv_allocated_le; +return 0 ; }
Quoted 5 lines
_______________________________________________
linux-lvm mailing list
[email protected]
http://lists.sistina.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/
*** Software bugs are stupid.
Nevertheless it needs not so stupid people to solve them ***
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Heinz Mauelshagen Sistina Software Inc.
Senior Consultant/Developer Am Sonnenhang 11
56242 Marienrachdorf Germany
[email protected] +49 2626 141200
FAX 924446
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-