Change in vdsm[master]: vm: Fix extend size calculation
nsoffer at redhat.com
nsoffer at redhat.com
Sun Feb 22 20:18:01 UTC 2015
Nir Soffer has posted comments on this change.
Change subject: vm: Fix extend size calculation
......................................................................
Patch Set 2:
(5 comments)
http://gerrit.ovirt.org/#/c/37274/2/vdsm/virt/vm.py
File vdsm/virt/vm.py:
Line 1418: try:
Line 1419: capacity, alloc, physical = self._getExtendInfo(drive)
Line 1420: except (libvirt.libvirtError, VolumeInfoError) as e:
Line 1421: self.log.error("Error getting extend info for %s: %s",
Line 1422: drive.path, e)
> Should be in separate patch
Fixed in http://gerrit.ovirt.org/38045
Line 1423: continue
Line 1424:
Line 1425: ret.append((drive, drive.volumeID, capacity, alloc, physical))
Line 1426:
Line 1432: mergeCandidate['capacity'], mergeCandidate['alloc'],
Line 1433: mergeCandidate['physical']))
Line 1434: return ret
Line 1435:
Line 1436: def _getExtendInfo(self, drive):
> _getDriveVolumeWatermarks?
Merge into the patch adding support for mixed domain types.
Line 1437: capacity, alloc, physical = self._dom.blockInfo(drive.path, 0)
Line 1438:
Line 1439: # When replicating file-based disk to block domain, physical is
Line 1440: # identical to alloc, breaking extend logic. We can get the real
Line 1448: replica["volumeID"])
Line 1449: if res['status']['code'] != 0:
Line 1450: raise VolumeInfoError("Error getting volume info %s" %
Line 1451: replica["volumeID"])
Line 1452: physical = int(res['apparentsize'])
Should be truesize if merged after http://gerrit.ovirt.org/37834
Line 1453:
Line 1454: return capacity, alloc, physical
Line 1455:
Line 1456: def _shouldExtendVolume(self, drive, volumeID, capacity, alloc, physical):
http://gerrit.ovirt.org/#/c/37274/2/vdsm/virt/vmdevices/storage.py
File vdsm/virt/vmdevices/storage.py:
Line 153
Line 154
Line 155
Line 156
Line 157
Fixed in http://gerrit.ovirt.org/37726
Line 355: # Extending block-based disks
Line 356:
Line 357: def getNextVolumeSize(cursize, capacity, chunk):
Line 358: """
Line 359: Returns the next volume size in megabytes. This value is the size that
> This api does not make sense and will lead to fatal errors. This should get
Fixed in http://gerrit.ovirt.org/37727
Line 360: should be requested for the next LV extension.
Line 361:
Line 362: Arguments:
Line 363: cursize Current volume size in bytes. For leaf block-based leaf
--
To view, visit http://gerrit.ovirt.org/37274
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I7afe3a7f6cfbb47eb76249d3851b7adaf4dbba6f
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Adam Litke <alitke at redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini at redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
More information about the vdsm-patches
mailing list