From patchwork Fri Jul 24 11:28:37 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: sudhir kumar X-Patchwork-Id: 37123 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n6OBShwH002658 for ; Fri, 24 Jul 2009 11:28:44 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751000AbZGXL2l (ORCPT ); Fri, 24 Jul 2009 07:28:41 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751052AbZGXL2l (ORCPT ); Fri, 24 Jul 2009 07:28:41 -0400 Received: from mail-pz0-f196.google.com ([209.85.222.196]:48142 "EHLO mail-pz0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750849AbZGXL2k (ORCPT ); Fri, 24 Jul 2009 07:28:40 -0400 Received: by pzk34 with SMTP id 34so1076233pzk.4 for ; Fri, 24 Jul 2009 04:28:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=JzVyl9zx+iCAlip+7CAWG9AFBRPuSPa4LzqJ0fyJtlQ=; b=vN0BQMT02UXfP6diFZtU6/VUrFRyWeLQm4qhrH4QT8E9lPBT9O2D6qchH/vBK88A/D SpCPFMqd6xaygK5fo3e+w2bkG2ABbi/2rSUFlehd4gSAL7Gd/gb02sD0rZ7+2FQBfcBL GXcOHxFjEWSeK4H8qylYEWiDXtZnSIy3UbGmc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=Y/ET3vj9KMQINiogP/7BPX2wkP9ot2vobbOhR/ihUPQbMTstVraDkvfQIA3UWiSsU2 atUSUd6KA5T1t+Zfpz9QcD+1AMycH5rJNvmX3HEG5IqrhHA13UBxN2zmdSI6Zof90yGv BmI0/5lyPseqJ5W6iD8yHsQD+ioymyDcy4NKM= MIME-Version: 1.0 Received: by 10.143.1.12 with SMTP id d12mr594176wfi.55.1248434917149; Fri, 24 Jul 2009 04:28:37 -0700 (PDT) Date: Fri, 24 Jul 2009 16:58:37 +0530 Message-ID: Subject: [AUTOTEST] print login command and change some timeout values From: sudhir kumar To: Autotest mailing list Cc: kvm-devel , Lucas Meneghel Rodrigues , Michael Goldish , smalikphy@gmail.com Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org This patch does two small things. 1. Prints the guest login command to debug messages. 2. Changes the guest login timeout to 240 seconds. I see the timeout for *.wait_for() functions in boot test is 240 seconds, while in reboot is 120 seconds which causes the test to fail. We might have missed it by mistake. 240 seconds is a reasonable timeout duration. This patch fixes that. Signed-off-by: Sudhir Kumar Index: autotest/client/tests/kvm/kvm_utils.py =================================================================== --- autotest.orig/client/tests/kvm/kvm_utils.py +++ autotest/client/tests/kvm/kvm_utils.py @@ -637,6 +637,7 @@ def remote_login(command, password, prom password_prompt_count = 0 logging.debug("Trying to login...") + logging.debug("Guest login Command: %s" % command) while True: (match, text) = sub.read_until_last_line_matches( Index: autotest/client/tests/kvm/kvm_tests.py =================================================================== --- autotest.orig/client/tests/kvm/kvm_tests.py +++ autotest/client/tests/kvm/kvm_tests.py @@ -48,7 +48,7 @@ def run_boot(test, params, env): logging.info("Guest is down; waiting for it to go up again...") - session = kvm_utils.wait_for(vm.ssh_login, 120, 0, 2) + session = kvm_utils.wait_for(vm.ssh_login, 240, 0, 2) if not session: raise error.TestFail("Could not log into guest after reboot") @@ -88,7 +88,7 @@ def run_shutdown(test, params, env): logging.info("Shutdown command sent; waiting for guest to go down...") - if not kvm_utils.wait_for(vm.is_dead, 120, 0, 1): + if not kvm_utils.wait_for(vm.is_dead, 240, 0, 1): raise error.TestFail("Guest refuses to go down") logging.info("Guest is down") @@ -445,7 +445,7 @@ def run_yum_update(test, params, env): logging.info("Logging into guest...") - session = kvm_utils.wait_for(vm.ssh_login, 120, 0, 2) + session = kvm_utils.wait_for(vm.ssh_login, 240, 0, 2) if not session: message = "Could not log into guest" logging.error(message)