From: Jason Wang <jasowang@redhat.com>
To: autotest@test.kernel.org
Cc: lmr@redhat.com, kvm@vger.kernel.org
Subject: [PATCH] KVM test: Minor enhancement for kdump
Date: Wed, 17 Nov 2010 18:45:02 +0800 [thread overview]
Message-ID: <20101117104502.18974.93653.stgit@dhcp-91-158.nay.redhat.com> (raw)
Make the crash kerenl prob command could be configurated.
Use carshkernel=128M instead of crashkerenl=128M@64M.
Signed-off-by: Jason Wang <jasowang@redhat.com>
---
client/tests/kvm/tests/kdump.py | 10 ++++++----
client/tests/kvm/tests_base.cfg.sample | 4 +++-
2 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/client/tests/kvm/tests/kdump.py b/client/tests/kvm/tests/kdump.py
index a5843c7..90c8cd2 100644
--- a/client/tests/kvm/tests/kdump.py
+++ b/client/tests/kvm/tests/kdump.py
@@ -18,11 +18,14 @@ def run_kdump(test, params, env):
timeout = float(params.get("login_timeout", 240))
crash_timeout = float(params.get("crash_timeout", 360))
session = kvm_test_utils.wait_for_login(vm, 0, timeout, 0, 2)
- def_kernel_param_cmd = ("grubby --update-kernel=`grubby --default-kernel`"
- " --args=crashkernel=128M@64M")
+ def_kernel_param_cmd = "grubby --update-kernel=`grubby --default-kernel`" \
+ " --args=crashkernel=128M"
kernel_param_cmd = params.get("kernel_param_cmd", def_kernel_param_cmd)
def_kdump_enable_cmd = "chkconfig kdump on && service kdump start"
kdump_enable_cmd = params.get("kdump_enable_cmd", def_kdump_enable_cmd)
+ def_crash_kernel_prob_cmd = "grep -q 1 /sys/kernel/kexec_crash_loaded"
+ crash_kernel_prob_cmd = params.get("crash_kernel_prob_cmd",
+ def_crash_kernel_prob_cmd)
def crash_test(vcpu):
"""
@@ -55,8 +58,7 @@ def run_kdump(test, params, env):
try:
logging.info("Checking the existence of crash kernel...")
- prob_cmd = "grep -q 1 /sys/kernel/kexec_crash_loaded"
- s = session.get_command_status(prob_cmd)
+ s = session.get_command_status(crash_kernel_prob_cmd)
if s != 0:
logging.info("Crash kernel is not loaded. Trying to load it")
# We need to setup the kernel params
diff --git a/client/tests/kvm/tests_base.cfg.sample b/client/tests/kvm/tests_base.cfg.sample
index 2ae7f78..3c248e2 100644
--- a/client/tests/kvm/tests_base.cfg.sample
+++ b/client/tests/kvm/tests_base.cfg.sample
@@ -667,7 +667,7 @@ variants:
- clock_getres: install setup unattended_install.cdrom
type = clock_getres
- - kdump:
+ - kdump: unattended_install.cdrom
type = kdump
# time waited for the completion of crash dump
# crash_timeout = 360
@@ -675,6 +675,8 @@ variants:
# kernel_param_cmd = "grubby --update-kernel=`grubby --default-kernel` --args=crashkernel=128M@64M"
# command to enable kdump service
# kdump_enable_cmd = chkconfig kdump on && service kdump start
+ # command to probe the crash kernel
+ # crash_kernel_prob_cmd = "grep -q 1 /sys/kernel/kexec_crash_loaded"
# system_powerdown, system_reset and shutdown *must* be the last ones
# defined (in this order), since the effect of such tests can leave
reply other threads:[~2010-11-17 10:38 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20101117104502.18974.93653.stgit@dhcp-91-158.nay.redhat.com \
--to=jasowang@redhat.com \
--cc=autotest@test.kernel.org \
--cc=kvm@vger.kernel.org \
--cc=lmr@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.