On 07/30/2012 06:34 AM, Yu Mingfei wrote:
This patch adds paused state in vm's preprocess.
Signed-off-by: Yu Mingfei <[email protected]>
---
client/virt/base.cfg.sample | 1 +
client/virt/virt_env_process.py | 3 +++
2 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/client/virt/base.cfg.sample b/client/virt/base.cfg.sample
index 80cab6e..192ec39 100644
--- a/client/virt/base.cfg.sample
+++ b/client/virt/base.cfg.sample
@@ -244,6 +244,7 @@ restore_image_on_check_error = no
# Some preprocessor/postprocessor params
start_vm = yes
+paused_after_start_vm = no
kill_vm = no
kill_vm_gracefully = yes
kill_unresponsive_vms = yes
diff --git a/client/virt/virt_env_process.py
b/client/virt/virt_env_process.py
index 306be76..153f1a3 100644
--- a/client/virt/virt_env_process.py
+++ b/client/virt/virt_env_process.py
@@ -104,6 +104,9 @@ def preprocess_vm(test, params, env, name):
vm.create(name, params, test.bindir,
migration_mode=params.get("migration_mode"),
migration_fd=params.get("migration_fd"))
+ if params.get("paused_after_start_vm") == "yes":
+ if vm.state() != "paused":
+ vm.pause()
else:
# Don't start the VM, just update its params
vm.params = params
--
1.7.1
--
Best Regards
Yu Mingfei
Well, I was going to do a quick test then commit this to next branch.
But my RHEL 5.8 box is giving me fits - Anaconda can't talk to the
built-in http server for kickstart file. Anyway, after fighting with it
I'll just commit this and we'll see if the integration tests are still
working tomorrow ;)
--
Chris Evich, RHCA, RHCE, RHCDS, RHCSS
Quality Assurance Engineer
e-mail: cevich + `@' + redhat.com o: 1-888-RED-HAT1 x44214
_______________________________________________
Autotest-kernel mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/autotest-kernel