From patchwork Sat May 8 17:01:09 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?THVrw6HFoSBEb2t0b3I=?= X-Patchwork-Id: 97929 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o48H1N74017214 for ; Sat, 8 May 2010 17:01:23 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754161Ab0EHRBV (ORCPT ); Sat, 8 May 2010 13:01:21 -0400 Received: from mx1.redhat.com ([209.132.183.28]:19471 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753882Ab0EHRBU (ORCPT ); Sat, 8 May 2010 13:01:20 -0400 Received: from int-mx04.intmail.prod.int.phx2.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.17]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o48H1JXb025658 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sat, 8 May 2010 13:01:19 -0400 Received: from localhost.localdomain (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx04.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o48H1BYW006901; Sat, 8 May 2010 13:01:16 -0400 From: Lukas Doktor To: ldoktor@redhat.com Cc: jzupka@redhat.com, kvm@vger.kernel.org, autotest@test.kernel.org, jasowang@redhat.com, lmr@redhat.com Subject: [PATCH 2/4] Add VMs alive check while spliting the guest's pages Date: Sat, 8 May 2010 18:01:09 +0100 Message-Id: <1273338071-8595-3-git-send-email-ldoktor@redhat.com> In-Reply-To: <[KVM_AUTOTEST][PATCH] KSM_overcommit: dynamic reserve calculation (2)> References: <[KVM_AUTOTEST][PATCH] KSM_overcommit: dynamic reserve calculation (2)> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.17 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Sat, 08 May 2010 17:01:23 +0000 (UTC) diff --git a/client/tests/kvm/tests/ksm_overcommit.py b/client/tests/kvm/tests/ksm_overcommit.py index 4aa6deb..b3d6880 100644 --- a/client/tests/kvm/tests/ksm_overcommit.py +++ b/client/tests/kvm/tests/ksm_overcommit.py @@ -142,6 +142,12 @@ def run_ksm_overcommit(test, params, env): session = None vm = None for i in range(1, vmsc): + # Check VMs + for j in range(0, vmsc): + if not lvms[j].is_alive: + e_msg = "VM %d died while executing static_random_fill in"\ + " VM %d on allocator loop" % (j, i) + raise error.TestFail(e_msg) vm = lvms[i] session = lsessions[i] a_cmd = "mem.static_random_fill()" @@ -154,6 +160,10 @@ def run_ksm_overcommit(test, params, env): logging.debug("Watching host memory while filling vm %s memory", vm.name) while not out.startswith("PASS") and not out.startswith("FAIL"): + if not vm.is_alive(): + e_msg = "VM %d died while executing static_random_fill"\ + " on allocator loop" % i + raise error.TestFail(e_msg) free_mem = int(utils.read_from_meminfo("MemFree")) if (ksm_swap): free_mem = (free_mem +