From e417d02462380b8ea28215780193fedcd6b2fb71 Mon Sep 17 00:00:00 2001 From: thierry Date: Wed, 10 Feb 2010 16:05:25 +0000 Subject: [PATCH] check for kqemu --- scripts/manage-infrastructure.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/scripts/manage-infrastructure.py b/scripts/manage-infrastructure.py index d859270..2138cae 100755 --- a/scripts/manage-infrastructure.py +++ b/scripts/manage-infrastructure.py @@ -170,6 +170,13 @@ class BuildBoxes: if not self.options.probe: self.reboot(box) else: + command=['ssh',self.root(box),'lsmod'] + modules=self.backquote(command).split('\n') + kqemu_msg='*NO kqemu MODULE LOADED*' + for module in modules: + if module.find('kqemu')==0: + kqemu_msg='kqemu OK' + command=['ssh',self.root(box),'pgrep','qemu'] if self.options.dry_run: self.run(command,None) @@ -178,7 +185,7 @@ class BuildBoxes: if not pids: self.header ('No qemu process on %s'%box) else: - self.header ("Active qemu processes on %s"%box) + self.header ("Active qemu processes on %s (%s)"%(box,kqemu_msg)) command=['ssh',self.root(box),'ps','-o','pid,command'] + [ pid for pid in pids.split("\n") if pid] ps_lines = self.backquote (command).split("\n") for ps_line in ps_lines: -- 2.45.2