Change in vdsm[master]: Shrink the new volume When merging block cow volumes
ykaplan at redhat.com
ykaplan at redhat.com
Sun Dec 16 10:55:35 UTC 2012
Yeela Kaplan has posted comments on this change.
Change subject: Shrink the new volume When merging block cow volumes
......................................................................
Patch Set 2: (4 inline comments)
....................................................
Commit Message
Line 3: AuthorDate: 2012-11-13 17:47:46 +0200
Line 4: Commit: Yeela Kaplan <ykaplan at redhat.com>
Line 5: CommitDate: 2012-12-12 11:28:34 +0200
Line 6:
Line 7: Shrink the new volume When merging block cow volumes
Done
Line 8:
Line 9: On merge, size of the new volume is currently the sum of virtual
Line 10: sizes of the original volumes that were merged. With qcow
Line 11: volumes on block devices we don't use the whole size of the new volume,
....................................................
File vdsm/qemuImg.py
Line 103: offset = int(__iregexSearch("offset", out[1]))
Line 104: except:
Line 105: raise QImgError(rc, out, err, "unable to parse qemu-img check output")
Line 106:
Line 107: return offset
Done
....................................................
File vdsm/storage/blockVolume.py
Line 291: """
Line 292: self.log.info("Request to reduce LV %s of image %s in VG %s with "
Line 293: "size = %s", self.volUUID, self.imgUUID, self.sdUUID,
Line 294: newSize)
Line 295: sizemb = (newSize + 2047) / 2048
I agree that we should have a utils function to do the aligning.
I'll add it in a consecutive patch, so I won't add any explicit info here.
Line 296: lvm.reduceLV(self.sdUUID, self.volUUID, sizemb)
Line 297:
Line 298: def shrinkToOptimalSize(self):
Line 299: """
....................................................
File vdsm/storage/lvm.py
Line 1057: _lvminfo._invalidatelvs(vgName, lvNames)
Line 1058: raise se.CannotRemoveLogicalVolume(vgName, str(lvNames))
Line 1059:
Line 1060:
Line 1061: def resizeLV(op, vgName, lvName, size):
Done
Line 1062: """
Line 1063: Size units: MB (1024 ** 2 = 2 ** 20)B.
Line 1064: """
Line 1065: # WARNING! From man vgs:
--
To view, visit http://gerrit.ovirt.org/9725
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I8ace4c48d278cb84ce871bc402643131265c3198
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yeela Kaplan <ykaplan at redhat.com>
Gerrit-Reviewer: Ayal Baron <abaron at redhat.com>
Gerrit-Reviewer: Eduardo <ewarszaw at redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Shu Ming <shuming at linux.vnet.ibm.com>
Gerrit-Reviewer: Yeela Kaplan <ykaplan at redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
More information about the vdsm-patches
mailing list