Change in vdsm[master]: doc: doc generation fix, another attempt.
by Dan Kenigsberg
Dan Kenigsberg has posted comments on this change.
Change subject: doc: doc generation fix, another attempt.
......................................................................
Patch Set 1: I would prefer that you didn't submit this
(1 inline comment)
please squash this commit into the former one, and use its Chnage-Id I836210fa5bbd844c20b3b5444be24cd9fa4023e2
That's how you fix a commit in gerrit - we would not want to change a line in one commit only to revert the same line in the following commit.
....................................................
File doc/create_sl.sh
Line 1: #!/bin/bash
Line 2:
Line 3: # Adds a symoblic link for vdscli in vdsm if not present.
Line 4: VDSCLI=$(readlink -f "../vdsm/vdscli.py")
Line 5: if [ ! -e $VDSCLI ] ; then
using unquoted variables in bash is usually a bug.
Line 6: ln -s ../vdsm_cli/vdscli.py $VDSCLI
--
To view, visit http://gerrit.ovirt.org/11661
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I76065019f94f332033cb79412e1c1564b5a095fd
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Giuseppe Vallarelli <giuseppevallarelli(a)gmail.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
11 years, 3 months
Change in vdsm[master]: doc: Solved sphinx-build import errors.
by Dan Kenigsberg
Dan Kenigsberg has posted comments on this change.
Change subject: doc: Solved sphinx-build import errors.
......................................................................
Patch Set 1: I would prefer that you didn't submit this
(2 inline comments)
....................................................
Commit Message
Line 8:
Line 9: Added _static folder to remove a sphinx-build warning,
Line 10: updated incorrect reference in SPM.rst, modified
Line 11: import statement in vm.py module. Generating docs
Line 12: requires updating PYTHONPATH by making it pointing to both
Could you have these PYTHONPATH changes within the "make htmlsctrict" target?
Line 13: vdsm python package and vdsm_cli folder.
Line 14:
Line 15: Change-Id: I836210fa5bbd844c20b3b5444be24cd9fa4023e2
Line 16: Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=491467
....................................................
File vdsm/vm.py
Line 32: from vdsm.config import config
Line 33: import kaxmlrpclib
Line 34: from logUtils import SimpleLogAdapter
Line 35: import libvirt
Line 36: import vdscli
I am afraid that this is not an acceptable fix - we need the "from vdsm" during runtime.
Line 37:
Line 38: DEFAULT_BRIDGE = config.get("vars", "default_bridge")
Line 39:
Line 40: DISK_DEVICES = 'disk'
--
To view, visit http://gerrit.ovirt.org/11652
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I836210fa5bbd844c20b3b5444be24cd9fa4023e2
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Giuseppe Vallarelli <giuseppevallarelli(a)gmail.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
11 years, 3 months
Change in vdsm[master]: Do not fail when getVSize is called on an inctive LV.
by ewarszaw@redhat.com
Eduardo has uploaded a new change for review.
Change subject: Do not fail when getVSize is called on an inctive LV.
......................................................................
Do not fail when getVSize is called on an inctive LV.
Change-Id: I0a8b6da4d57cdf810769586c1959989d7a545d0c
Bug-uri: https://bugzilla.redhat.com/show_bug.cgi?id=878955
Signed-off-by: Eduardo <ewarszaw(a)redhat.com>
---
M vdsm/storage/blockVolume.py
1 file changed, 11 insertions(+), 9 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/39/9739/1
diff --git a/vdsm/storage/blockVolume.py b/vdsm/storage/blockVolume.py
index 98c471b..bf71fb2 100644
--- a/vdsm/storage/blockVolume.py
+++ b/vdsm/storage/blockVolume.py
@@ -61,7 +61,7 @@
rmanager = rm.ResourceManager.getInstance()
-def _getDeviceSize(devPath):
+def _tellEnd(devPath):
with open(devPath, "rb") as f:
f.seek(0, 2)
return f.tell()
@@ -91,15 +91,17 @@
@classmethod
def getVSize(cls, sdobj, imgUUID, volUUID, bs=512):
try:
- return _getDeviceSize(lvm.lvPath(sdobj.sdUUID, volUUID)) / bs
- except Exception, e:
- # The volume might not be active, skip logging.
- if not (isinstance(e, IOError) and e.errno == os.errno.ENOENT):
- cls.log.warn("Could not get size for vol %s/%s using "
- "optimized methods", sdobj.sdUUID, volUUID, exc_info=True)
+ size = _tellEnd(lvm.lvPath(sdobj.sdUUID, volUUID)) / bs
+ except IOError as e:
+ if e.errno == os.errno.ENOENT:
+ # Inactive volume has no /dev entry. Fallback to lvm way.
+ size = int(int(lvm.getLV(sdobj.sdUUID, volUUID).size) / bs)
+ else:
+ cls.log.warn("Could not get size for vol %s/%s",
+ sdobj.sdUUID, volUUID, exc_info=True)
+ raise
- # Fallback to the traditional way.
- return int(int(lvm.getLV(sdobj.sdUUID, volUUID).size) / bs)
+ return size
getVTrueSize = getVSize
--
To view, visit http://gerrit.ovirt.org/9739
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I0a8b6da4d57cdf810769586c1959989d7a545d0c
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Eduardo <ewarszaw(a)redhat.com>
11 years, 3 months