]> xenbits.xensource.com Git - xenrt-citrix/xenrt.git/commitdiff
Changed exception level
authorPeenu Singh <peenu.singh@citrix.com>
Wed, 30 Sep 2015 05:53:22 +0000 (05:53 +0000)
committerPeenu Singh <peenu.singh@citrix.com>
Thu, 8 Oct 2015 06:06:01 +0000 (06:06 +0000)
exec/testcases/xenserver/tc/balloon.py

index dd213b444b35dba81fe2c567f10bd6e957c6c3c7..88b2e4e1438abef1a1d58c6dde48d0432d325b54 100755 (executable)
@@ -425,16 +425,17 @@ class _BalloonSmoketest(_BalloonPerfBase):
             #(ranging from too busy, crashed guest, malicious guest, buggy balloon driver)
             #then the product marks the guest as uncooperative
             #Check for uncooperative tag, if found shut down the VM, print the details and proceed with the test
-            res = self.host.execdom0("xenstore-ls -pf | grep memory | grep -E 'uncoop'")
-            if res and "uncooperative" in res:
-                log("Caught failure: %s" % str(e))
-                log("Guest marked uncooperative")
-                log("Shut down the guest")
-                try:
-                    self.guest.shutdown(force=True)
-                except:
-                    pass
-            raise
+            elif "Memory target not met" in str(e):
+                res = self.host.execdom0("xenstore-ls -pf | grep memory | grep -E 'uncoop'", level=xenrt.RC_OK)
+                if res and "uncooperative" in res:
+                    log("Caught failure: %s" % str(e))
+                    log("Guest marked uncooperative")
+                    log("Shut down the guest")
+                    try:
+                        self.guest.shutdown(force=True)
+                    except:
+                        pass
+                raise
 
     def testMaxRange(self, minMem, maxMem):
         step("Set dynamic-min=dynamic-max=min, static-max=max")