Change in vdsm[master]: sp: refresh metadata on hsm when listing domains
by Federico Simoncelli
Federico Simoncelli has uploaded a new change for review.
Change subject: sp: refresh metadata on hsm when listing domains
......................................................................
sp: refresh metadata on hsm when listing domains
In this patch:
- validatePoolSD and validateAttachedDomain are relevant only for SPM
operations (remove @unsecured)
Change-Id: I095cd0760076fb4be97a776498af78a40ff84112
Signed-off-by: Federico Simoncelli <fsimonce(a)redhat.com>
---
M vdsm/storage/sp.py
1 file changed, 2 insertions(+), 6 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/86/21786/1
diff --git a/vdsm/storage/sp.py b/vdsm/storage/sp.py
index 8ae733b..37dcec8 100644
--- a/vdsm/storage/sp.py
+++ b/vdsm/storage/sp.py
@@ -506,15 +506,11 @@
return self.getMetaParam(PMDK_MASTER_VER)
# TODO: Remove or rename this function.
- @unsecured
def validatePoolSD(self, sdUUID):
if sdUUID not in self.getDomains():
- self._metadata.invalidate()
- if sdUUID not in self.getDomains():
- raise se.StorageDomainNotMemberOfPool(self.spUUID, sdUUID)
+ raise se.StorageDomainNotMemberOfPool(self.spUUID, sdUUID)
return True
- @unsecured
def validateAttachedDomain(self, dom):
"""
Avoid handling domains if not owned by pool.
@@ -1542,7 +1538,6 @@
def updateMonitoringThreads(self):
# domain list it's list of sdUUID:status
# sdUUID1:status1,sdUUID2:status2,...
- self.invalidateMetadata()
activeDomains = self.getDomains(activeOnly=True)
monitoredDomains = self.domainMonitor.poolMonitoredDomains
@@ -1569,6 +1564,7 @@
@unsecured
def getDomains(self, activeOnly=False):
+ self.invalidateMetadata()
return dict(
(sdUUID, status) for sdUUID, status in
self.getMetaParam(PMDK_DOMAINS).iteritems()
--
To view, visit http://gerrit.ovirt.org/21786
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I095cd0760076fb4be97a776498af78a40ff84112
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Federico Simoncelli <fsimonce(a)redhat.com>
10 years, 4 months
Change in vdsm[master]: Fix regression introduced in #22837
by amuller@redhat.com
Assaf Muller has uploaded a new change for review.
Change subject: Fix regression introduced in #22837
......................................................................
Fix regression introduced in #22837
Gluster API verbs will now be callable again.
wrapApiMethod was using the function's class 'updateTimestamp',
but updateTimestamp is defined in BindingXMLRPC and doesn't exist
in the GlusterAPI class. This patch moves 'updateTimestamp' to be
a static method.
Change-Id: Ibab01ef654e7ac469ea0a2594c4744918ae24819
Signed-off-by: Assaf Muller <amuller(a)redhat.com>
---
M vdsm/BindingXMLRPC.py
1 file changed, 4 insertions(+), 3 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/44/23044/1
diff --git a/vdsm/BindingXMLRPC.py b/vdsm/BindingXMLRPC.py
index 2364684..56eefa6 100644
--- a/vdsm/BindingXMLRPC.py
+++ b/vdsm/BindingXMLRPC.py
@@ -80,7 +80,8 @@
self._thread.join()
return {'status': doneCode}
- def updateTimestamp(self):
+ @staticmethod
+ def updateTimestamp():
# FIXME: The setup+editNetwork API uses this log file to
# determine if this host is still accessible. We use a
# file (rather than an event) because setup+editNetwork is
@@ -141,7 +142,7 @@
def _registerFunctions(self):
def wrapIrsMethod(f):
def wrapper(*args, **kwargs):
- self.updateTimestamp()
+ BindingXMLRPC.updateTimestamp()
fmt = ""
logargs = []
@@ -938,7 +939,7 @@
def wrapApiMethod(f):
def wrapper(*args, **kwargs):
try:
- f.im_self.updateTimestamp()
+ BindingXMLRPC.updateTimestamp()
logLevel = logging.DEBUG
if f.__name__ in ('getVMList', 'getAllVmStats', 'getStats',
'fenceNode'):
--
To view, visit http://gerrit.ovirt.org/23044
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ibab01ef654e7ac469ea0a2594c4744918ae24819
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Assaf Muller <amuller(a)redhat.com>
10 years, 4 months
Change in vdsm[master]: [wip] jsonrpc: Vdsm changes
by ybronhei@redhat.com
Yaniv Bronhaim has posted comments on this change.
Change subject: [wip] jsonrpc: Vdsm changes
......................................................................
Patch Set 13: Code-Review-1
(10 comments)
....................................................
Commit Message
Line 3: AuthorDate: 2013-11-29 12:33:29 +0100
Line 4: Commit: pkliczewski <piotr.kliczewski(a)gmail.com>
Line 5: CommitDate: 2014-01-02 16:43:20 +0100
Line 6:
Line 7: [wip] jsonrpc: Vdsm changes
when will you plan to remove the wip?
Line 8:
Line 9: Here are engine changes: http://gerrit.ovirt.org/#/c/20926/
Line 10:
Line 11: Changes are done on top of Saggi's reimplementation of async tcp server
Line 8:
Line 9: Here are engine changes: http://gerrit.ovirt.org/#/c/20926/
Line 10:
Line 11: Changes are done on top of Saggi's reimplementation of async tcp server
Line 12: using json. The changes include:
on top of? is it part of that patch or you depend on something ? or there is a link for those changes?
Line 13: - Fixing ssl
Line 14: - Gluster api support
Line 15: - Fixing number of issues around Bridge.py and json binding
Line 16: - Update vdsm schema and code to be consistent
Line 9: Here are engine changes: http://gerrit.ovirt.org/#/c/20926/
Line 10:
Line 11: Changes are done on top of Saggi's reimplementation of async tcp server
Line 12: using json. The changes include:
Line 13: - Fixing ssl
what was wrong in ssl?
Line 14: - Gluster api support
Line 15: - Fixing number of issues around Bridge.py and json binding
Line 16: - Update vdsm schema and code to be consistent
Line 17: - getAllVmStats was only available for xml so it was moved to API
Line 11: Changes are done on top of Saggi's reimplementation of async tcp server
Line 12: using json. The changes include:
Line 13: - Fixing ssl
Line 14: - Gluster api support
Line 15: - Fixing number of issues around Bridge.py and json binding
elaborate
Line 16: - Update vdsm schema and code to be consistent
Line 17: - getAllVmStats was only available for xml so it was moved to API
Line 18: - vm snapshot method had not optional argument
Line 19: - added implementation for full vm list
Line 12: using json. The changes include:
Line 13: - Fixing ssl
Line 14: - Gluster api support
Line 15: - Fixing number of issues around Bridge.py and json binding
Line 16: - Update vdsm schema and code to be consistent
I prefer the update of the schema in separate patch ? is it possible?
Line 17: - getAllVmStats was only available for xml so it was moved to API
Line 18: - vm snapshot method had not optional argument
Line 19: - added implementation for full vm list
Line 20: - added gerHardwareInfo method
Line 13: - Fixing ssl
Line 14: - Gluster api support
Line 15: - Fixing number of issues around Bridge.py and json binding
Line 16: - Update vdsm schema and code to be consistent
Line 17: - getAllVmStats was only available for xml so it was moved to API
remove tabs
Line 18: - vm snapshot method had not optional argument
Line 19: - added implementation for full vm list
Line 20: - added gerHardwareInfo method
Line 21:
....................................................
File lib/yajsonrpc/__init__.py
Line 98: method = obj.get("method")
Line 99: if method is None:
Line 100: raise JsonRpcInvalidRequestError()
Line 101:
Line 102: reqId = obj.get("id")
id is not int anymore ? why do you remove the check ?
Line 103:
Line 104: params = obj.get('params', [])
Line 105: if not isinstance(params, (list, dict)):
Line 106: raise JsonRpcInvalidRequestError()
....................................................
File tests/jsonRpcTests.py
Line 198: {'text': data},
Line 199: 10, CALL_TIMEOUT),
Line 200: data)
Line 201:
Line 202: @brokentest('fail with "error: [Errno 9] Bad file descriptor"')
what about the rest that defined as broken ?
Line 203: @permutations(CONNECTION_PERMUTATIONS)
Line 204: def testMethodMissingMethod(self, rt, ssl):
Line 205: bridge = _DummyBridge()
Line 206: with constructServer(rt, bridge, ssl) as (server, clientFactory):
....................................................
File vdsm/API.py
Line 651: ip = '0'
Line 652: self.log.info('network %s: using %s', network, ip)
Line 653: return ip
Line 654:
Line 655: def snapshot(self, snapDrives, snapMemVolHandle=None):
do it separately in external patch. it fixes a bug
Line 656: v = self._cif.vmContainer.get(self._UUID)
Line 657: if not v:
Line 658: return errCode['noVM']
Line 659: memoryParams = {}
....................................................
File vdsm/gluster/vdsmapi-gluster-schema.json
Line 1: #
think all those scheme changes can be separately , and not related to jsonrpc
Line 2: # Copyright 2013 Red Hat, Inc.
Line 3: #
Line 4: # This program is free software; you can redistribute it and/or modify
Line 5: # it under the terms of the GNU General Public License as published by
--
To view, visit http://gerrit.ovirt.org/19497
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: If828355b7efe28fe6a2e784069425fefd2f3f25c
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Saggi Mizrahi <smizrahi(a)redhat.com>
Gerrit-Reviewer: Adam Litke <alitke(a)redhat.com>
Gerrit-Reviewer: Barak Azulay <bazulay(a)redhat.com>
Gerrit-Reviewer: Eduardo <ewarszaw(a)redhat.com>
Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczewski(a)gmail.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi(a)redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei(a)redhat.com>
Gerrit-Reviewer: mooli tayer <mtayer(a)redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
10 years, 5 months
Change in vdsm[master]: vdsm: Reduce the migration progress timeout
by Vinzenz Feenstra
Vinzenz Feenstra has uploaded a new change for review.
Change subject: vdsm: Reduce the migration progress timeout
......................................................................
vdsm: Reduce the migration progress timeout
The progress of the migration should indicate a stuck migration
way before the currently configured migration_timeout, which has
by default 300 seconds.
Half of the time should be more than enough for now.
This commit introduces the migration_progress_timeout configuration
value to be able adjusting this value.
Change-Id: I8f314d70b8f32cfff58f9776bcc2182a748a9b67
Signed-off-by: Vinzenz Feenstra <vfeenstr(a)redhat.com>
---
M lib/vdsm/config.py.in
M vdsm/vm.py
2 files changed, 7 insertions(+), 2 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/02/16602/1
diff --git a/lib/vdsm/config.py.in b/lib/vdsm/config.py.in
index 2a5618a..d95c78d 100644
--- a/lib/vdsm/config.py.in
+++ b/lib/vdsm/config.py.in
@@ -52,6 +52,11 @@
'Please note, that this is not overall migration timeout. '
'Source waits twice as long (to avoid races).'),
+ ('migration_progress_timeout', '150',
+ 'Maximum time the source host waits during a migration in case '
+ 'that there is no progress. If the time has passed, the migration '
+ 'will be aborted.'),
+
('migration_listener_timeout', '30',
'Time to wait (in seconds) for migration destination to start '
'listening before migration begins.'),
diff --git a/vdsm/vm.py b/vdsm/vm.py
index 281c584..309a1bd 100644
--- a/vdsm/vm.py
+++ b/vdsm/vm.py
@@ -746,6 +746,7 @@
lastProgressTime = time.time()
smallest_dataRemaining = None
+ progress_timeout = config.getint('vars', 'migration_progress_timeout')
while not self._stop.isSet():
self._stop.wait(self._MIGRATION_MONITOR_INTERVAL)
@@ -758,8 +759,7 @@
smallest_dataRemaining > dataRemaining):
smallest_dataRemaining = dataRemaining
lastProgressTime = time.time()
- elif (time.time() - lastProgressTime >
- config.getint('vars', 'migration_timeout')):
+ elif (time.time() - lastProgressTime) > progress_timeout:
# Migration is stuck, abort
self._vm.log.warn(
'Migration is stuck: Hasn\'t progressed in %s seconds. '
--
To view, visit http://gerrit.ovirt.org/16602
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I8f314d70b8f32cfff58f9776bcc2182a748a9b67
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Vinzenz Feenstra <vfeenstr(a)redhat.com>
10 years, 5 months
Change in vdsm[master]: Setting force to true overwrites the configuration in libvir...
by ybronhei@redhat.com
Yaniv Bronhaim has uploaded a new change for review.
Change subject: Setting force to true overwrites the configuration in libvirt configurer
......................................................................
Setting force to true overwrites the configuration in libvirt configurer
This patch adds force flag to isconfigured verb to allow different return
value of isconfigured force is required. In libvirt configure with force we
will overwrite the configuration to keep the old semantic, although in
sanlock configurer rerun of configure is not required also if force is
set.
This sanlock reconfigure caused a failure during host deploy while trying to
stop sanlock service that was already configured.
Change-Id: I2d3984e3cd6b866dcee6e6dc493ba78a34ff56d6
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1035847
Signed-off-by: Yaniv Bronhaim <ybronhei(a)redhat.com>
---
M lib/vdsm/tool/configurator.py
1 file changed, 11 insertions(+), 4 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/92/22492/1
diff --git a/lib/vdsm/tool/configurator.py b/lib/vdsm/tool/configurator.py
index 869d774..4419536 100644
--- a/lib/vdsm/tool/configurator.py
+++ b/lib/vdsm/tool/configurator.py
@@ -44,7 +44,7 @@
def configure(self):
pass
- def isconfigured(self):
+ def isconfigured(self, force):
return True
@@ -93,11 +93,16 @@
except RuntimeError:
return False
- def isconfigured(self):
+ def isconfigured(self, force):
"""
Check if libvirt is already configured for vdsm
+
+ if force set configure needs to run libvirt configure also if
+ already configured. The result of isconfigured will be False
"""
try:
+ if force:
+ return False
self._exec_libvirt_configure("check_if_configured")
return True
except RuntimeError:
@@ -136,10 +141,12 @@
if rc != 0:
raise RuntimeError("Failed to perform sanlock config.")
- def isconfigured(self, *args):
+ def isconfigured(self, force):
"""
True if sanlock service is configured, False if sanlock service
requires a restart to reload the relevant supplementary groups.
+
+ force value currently doesn't change the result
"""
ret = False
try:
@@ -191,7 +198,7 @@
raise RuntimeError(
"Configuration of %s is invalid" % c.getName()
)
- if args.force or not c.isconfigured():
+ if not c.isconfigured(args.force):
configurer_to_trigger.append(c)
services = []
--
To view, visit http://gerrit.ovirt.org/22492
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I2d3984e3cd6b866dcee6e6dc493ba78a34ff56d6
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Yaniv Bronhaim <ybronhei(a)redhat.com>
10 years, 5 months
Change in vdsm[ovirt-3.3]: BindingXMLRPC bugfix: Return lastClientIface for current con...
by amuller@redhat.com
Hello Dan Kenigsberg,
I'd like you to do a code review. Please visit
http://gerrit.ovirt.org/22967
to review the following change.
Change subject: BindingXMLRPC bugfix: Return lastClientIface for current connection
......................................................................
BindingXMLRPC bugfix: Return lastClientIface for current connection
The patch does two things:
1) Fixes a bug where lastClientIface was for the previous
connection, and not the current one. The method to retrieve
the last client was through a log_request LoggingMixIn
which is invoked at the end of a response, not at the beginning.
The patch removes the usage of that MixIn, and instead uses
values that are updated at the beginning of the connection
2) Simplifies the 'LoggingMixin' out of the picture as its no
longer needed
Change-Id: I36e48cc07a27f44a2b413f0e9159110404f1b0ca
Signed-off-by: Assaf Muller <amuller(a)redhat.com>
Reviewed-on: http://gerrit.ovirt.org/22837
Reviewed-by: Dan Kenigsberg <danken(a)redhat.com>
---
M vdsm/BindingXMLRPC.py
1 file changed, 16 insertions(+), 17 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/67/22967/1
diff --git a/vdsm/BindingXMLRPC.py b/vdsm/BindingXMLRPC.py
index 5ee7126..666cc95 100644
--- a/vdsm/BindingXMLRPC.py
+++ b/vdsm/BindingXMLRPC.py
@@ -80,6 +80,15 @@
self._thread.join()
return {'status': doneCode}
+ def updateTimestamp(self):
+ # FIXME: The setup+editNetwork API uses this log file to
+ # determine if this host is still accessible. We use a
+ # file (rather than an event) because setup+editNetwork is
+ # performed by a separate, root process. To clean this
+ # up we need to move this to an API wrapper that is only
+ # run for real clients (not vdsm internal API calls).
+ file(constants.P_VDSM_CLIENT_LOG, 'w')
+
def _getKeyCertFilenames(self):
"""
Get the locations of key and certificate files.
@@ -97,29 +106,16 @@
threadLocal = self.cif.threadLocal
- class LoggingMixIn:
-
- def log_request(self, code='-', size='-'):
- """Track from where client connections are coming."""
- self.server.lastClient = self.client_address[0]
- self.server.lastServerIP = self.request.getsockname()[0]
- # FIXME: The editNetwork API uses this log file to
- # determine if this host is still accessible. We use a
- # file (rather than an event) because editNetwork is
- # performed by a separate, root process. To clean this
- # up we need to move this to an API wrapper that is only
- # run for real clients (not vdsm internal API calls).
- file(constants.P_VDSM_CLIENT_LOG, 'w')
-
server_address = (self.serverIP, int(self.serverPort))
if self.enableSSL:
basehandler = SecureXMLRPCServer.SecureXMLRPCRequestHandler
else:
basehandler = SimpleXMLRPCServer.SimpleXMLRPCRequestHandler
- class LoggingHandler(LoggingMixIn, basehandler):
+ class LoggingHandler(basehandler):
def setup(self):
threadLocal.client = self.client_address[0]
+ threadLocal.server = self.request.getsockname()[0]
return basehandler.setup(self)
def parse_request(self):
@@ -149,6 +145,7 @@
def _registerFunctions(self):
def wrapIrsMethod(f):
def wrapper(*args, **kwargs):
+ self.updateTimestamp()
fmt = ""
logargs = []
@@ -301,8 +298,9 @@
api = API.Global()
ret = api.getCapabilities()
ret['info']['management_ip'] = self.serverIP
- ret['info']['lastClient'] = self.server.lastClient
- ret['info']['lastClientIface'] = getIfaceByIP(self.server.lastServerIP)
+ ret['info']['lastClient'] = self.cif.threadLocal.client
+ ret['info']['lastClientIface'] = getIfaceByIP(
+ self.cif.threadLocal.server)
return ret
def getHardwareInfo(self):
@@ -940,6 +938,7 @@
def wrapApiMethod(f):
def wrapper(*args, **kwargs):
try:
+ f.im_self.updateTimestamp()
logLevel = logging.DEBUG
if f.__name__ in ('getVMList', 'getAllVmStats', 'getStats',
'fenceNode'):
--
To view, visit http://gerrit.ovirt.org/22967
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I36e48cc07a27f44a2b413f0e9159110404f1b0ca
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.3
Gerrit-Owner: Assaf Muller <amuller(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
10 years, 5 months
Change in vdsm[ovirt-3.3]: vm: Bring back missing before_device_migrate_source hook call
by Vinzenz Feenstra
Hello Dan Kenigsberg,
I'd like you to do a code review. Please visit
http://gerrit.ovirt.org/23012
to review the following change.
Change subject: vm: Bring back missing before_device_migrate_source hook call
......................................................................
vm: Bring back missing before_device_migrate_source hook call
During the merge of libvirtvm.py and vm.py this section of the code
somehow got removed, this patch brings it back.
Change-Id: I317ae6b0ed5a7a6fa0f959169b27339c4451b35a
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1048763
Signed-off-by: Vinzenz Feenstra <vfeenstr(a)redhat.com>
Reviewed-on: http://gerrit.ovirt.org/23006
Reviewed-by: Dan Kenigsberg <danken(a)redhat.com>
---
M vdsm/vm.py
1 file changed, 3 insertions(+), 0 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/12/23012/1
diff --git a/vdsm/vm.py b/vdsm/vm.py
index 6b2de55..f9b241e 100644
--- a/vdsm/vm.py
+++ b/vdsm/vm.py
@@ -350,6 +350,9 @@
self._vm._vmStats.cont()
raise
else:
+ for dev in self._vm._customDevices():
+ hooks.before_device_migrate_source(
+ dev._deviceXML, self._vm.conf, dev.custom)
hooks.before_vm_migrate_source(self._vm._dom.XMLDesc(0),
self._vm.conf)
response = self.destServer.migrationCreate(self._machineParams)
--
To view, visit http://gerrit.ovirt.org/23012
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I317ae6b0ed5a7a6fa0f959169b27339c4451b35a
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.3
Gerrit-Owner: Vinzenz Feenstra <vfeenstr(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
10 years, 5 months
Change in vdsm[master]: Get rid of legacy status 'Running'
by Vinzenz Feenstra
Vinzenz Feenstra has uploaded a new change for review.
Change subject: Get rid of legacy status 'Running'
......................................................................
Get rid of legacy status 'Running'
The status 'Running' means 'Up' for any case, now we get rid of it
completely as this is not helpful having two states for Up.
Change-Id: Ie3c6e66365fe02158e5a7bb8db56c724b612b366
Signed-off-by: Vinzenz Feenstra <vfeenstr(a)redhat.com>
---
M tests/functional/momTests.py
M tests/functional/storageTests.py
M tests/functional/virtTests.py
M vdsm/guestIF.py
4 files changed, 5 insertions(+), 5 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/66/21766/1
diff --git a/tests/functional/momTests.py b/tests/functional/momTests.py
index b5be83e..7ae0c2b 100644
--- a/tests/functional/momTests.py
+++ b/tests/functional/momTests.py
@@ -80,7 +80,7 @@
def _statsOK(self, stats):
try:
- return stats['status'] == 'Running' and stats['balloonInfo'] \
+ return stats['status'] == 'Up' and stats['balloonInfo'] \
and stats['memoryStats']
except KeyError:
return False
diff --git a/tests/functional/storageTests.py b/tests/functional/storageTests.py
index e9b2c4f..df3a043 100644
--- a/tests/functional/storageTests.py
+++ b/tests/functional/storageTests.py
@@ -62,7 +62,7 @@
@expandPermutations
class StorageTest(TestCaseBase):
- UPSTATES = frozenset(('Up', 'Powering up', 'Running'))
+ UPSTATES = frozenset(('Up', 'Powering up'))
def runTest(self):
pass
diff --git a/tests/functional/virtTests.py b/tests/functional/virtTests.py
index cdb695a..d49c439 100644
--- a/tests/functional/virtTests.py
+++ b/tests/functional/virtTests.py
@@ -135,7 +135,7 @@
@expandPermutations
class VirtTest(TestCaseBase):
- UPSTATES = frozenset(('Up', 'Powering up', 'Running'))
+ UPSTATES = frozenset(('Up', 'Powering up'))
def setUp(self):
self.vdsm = VdsProxy()
diff --git a/vdsm/guestIF.py b/vdsm/guestIF.py
index 6f09ef1..06ca71b 100644
--- a/vdsm/guestIF.py
+++ b/vdsm/guestIF.py
@@ -169,9 +169,9 @@
def _handleMessage(self, message, args):
self.log.log(logging.TRACE, "Guest's message %s: %s", message, args)
if self.guestStatus is None:
- self.guestStatus = 'Running'
+ self.guestStatus = 'Up'
if message == 'heartbeat':
- self.guestStatus = 'Running'
+ self.guestStatus = 'Up'
self.guestInfo['memUsage'] = int(args['free-ram'])
# ovirt-guest-agent reports the following fields in 'memory-stat':
# 'mem_total', 'mem_free', 'mem_unused', 'swap_in', 'swap_out',
--
To view, visit http://gerrit.ovirt.org/21766
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie3c6e66365fe02158e5a7bb8db56c724b612b366
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Vinzenz Feenstra <vfeenstr(a)redhat.com>
10 years, 5 months
Change in vdsm[master]: build: add gluster dependency conditionally
by barumuga@redhat.com
Hello Timothy Asir, Saggi Mizrahi, Aravinda VK, Dan Kenigsberg, Darshan N,
I'd like you to do a code review. Please visit
http://gerrit.ovirt.org/21705
to review the following change.
Change subject: build: add gluster dependency conditionally
......................................................................
build: add gluster dependency conditionally
This patch adds glusterfs dependency conditionally for rhel and
others.
Change-Id: Ib61b9acb8aa4e842dfc133c48811a6a6b43e025e
Signed-off-by: Bala.FA <barumuga(a)redhat.com>
---
M vdsm.spec.in
1 file changed, 4 insertions(+), 0 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/05/21705/1
diff --git a/vdsm.spec.in b/vdsm.spec.in
index 43e47ea..0207c9f 100644
--- a/vdsm.spec.in
+++ b/vdsm.spec.in
@@ -217,8 +217,12 @@
# GlusterFS client-side RPMs needed for Gluster SD
%if 0%{?with_gluster}
+%if 0%{?rhel}
+Requires: glusterfs >= 3.4.0
+%else
Requires: glusterfs >= 3.4.1
Requires: glusterfs-cli
+%endif
Requires: glusterfs-api
Requires: glusterfs-fuse
Requires: glusterfs-rdma
--
To view, visit http://gerrit.ovirt.org/21705
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib61b9acb8aa4e842dfc133c48811a6a6b43e025e
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Bala.FA <barumuga(a)redhat.com>
Gerrit-Reviewer: Aravinda VK <avishwan(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Darshan N <dnarayan(a)redhat.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi(a)redhat.com>
Gerrit-Reviewer: Timothy Asir <tjeyasin(a)redhat.com>
10 years, 5 months
Change in vdsm[master]: tests: skip mkimageTests when mkisofs and mkfs.msdos don't e...
by Jarod.w
Jarod.w has uploaded a new change for review.
Change subject: tests: skip mkimageTests when mkisofs and mkfs.msdos don't exist
......................................................................
tests: skip mkimageTests when mkisofs and mkfs.msdos don't exist
Change-Id: I192707f466203786cd0864c8ca7c9e5070867523
Signed-off-by: jarod.w <work.iec23801(a)gmail.com>
---
M tests/mkimageTests.py
1 file changed, 23 insertions(+), 0 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/84/18984/1
diff --git a/tests/mkimageTests.py b/tests/mkimageTests.py
index 28b35bb..38d23d1 100644
--- a/tests/mkimageTests.py
+++ b/tests/mkimageTests.py
@@ -34,11 +34,21 @@
from nose.plugins.skip import SkipTest
from testrunner import VdsmTestCase, permutations, expandPermutations
from testValidation import checkSudo, ValidateRunningAsRoot
+from vdsm.utils import CommandPath
import storage
import mkimage
+
+_mkfsmsdos = CommandPath("mkfs.msdos",
+ "/usr/sbin/mkfs.msdos", # Fedora
+ "/sbin/mkfs.msdos", # RHEL6
+ )
+
+_mkisofs = CommandPath("mkisofs",
+ "/usr/bin/mkisofs", # Fedora, RHEL6
+ )
@expandPermutations
class MkimageTestCase(VdsmTestCase):
"""
@@ -122,6 +132,16 @@
self.assertEqual(len(partitions), 3)
self.assertEqual(partitions[2].strip(), '"' + label + '"')
+ def _check_path(self, cmdpath):
+ """
+ Check whether execute file exists
+ """
+ try:
+ if cmdpath.cmd == None:
+ raise SkipTest("cannot execute %s" % cmdpath.name)
+ except:
+ raise SkipTest("cannot execute %s" % cmdpath.name)
+
def test__decodeFilesIntoDir(self):
"""
Tests mkimage._decodeFilesIntoDir
@@ -137,6 +157,7 @@
Tests mkimage.mkFloppyFs creating an image and checking its content.
Requires root permissions for writing into the floppy image.
"""
+ self._check_path(_mkfsmsdos)
floppy = mkimage.mkFloppyFs("vmId_floppy", self.files, label)
self.assertTrue(os.path.exists(floppy))
m = storage.mount.Mount(floppy, self.workdir)
@@ -153,6 +174,7 @@
"""
Tests mkimage.mkIsoFs creating an image and checking its content
"""
+ self._check_path(_mkisofs)
checkSudo(["mount", "-o", "loop", "somefile", "target"])
checkSudo(["umount", "target"])
iso_img = mkimage.mkIsoFs("vmId_iso", self.files, label)
@@ -172,6 +194,7 @@
Check also that removeFs doesn't remove anything
outside mkimage._P_PAYLOAD_IMAGES
"""
+ self._check_path(_mkisofs)
checkSudo(["mount", "-o", "loop", "somefile", "target"])
checkSudo(["umount", "target"])
iso_img = mkimage.mkIsoFs("vmId_iso", self.files)
--
To view, visit http://gerrit.ovirt.org/18984
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I192707f466203786cd0864c8ca7c9e5070867523
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Jarod.w <work.iec23801(a)gmail.com>
10 years, 5 months