System services on guest and host take uncertain resource, it effects
the perf results. We can use the below two scripts to disable some
services of host and guest.

rh_stop_serivices.sh is used to stop the running serivices.
rh_off_service.sh is used to off services when host starts up.

We can use them to prepare environment for performance testcases.
Using scripts can split the environment preparation with real testing,
it's easy to maintain.

Those two scripts are prepared for RHEL/Fedora system, it's just an
example. Users can reference those to create their own scripts.

Signed-off-by: Amos Kong <[email protected]>
---
 client/virt/scripts/rh_off_services.sh  |   30 ++++++++++++++++++++++++++++++
 client/virt/scripts/rh_stop_services.sh |   30 ++++++++++++++++++++++++++++++
 2 files changed, 60 insertions(+), 0 deletions(-)
 create mode 100755 client/virt/scripts/rh_off_services.sh
 create mode 100755 client/virt/scripts/rh_stop_services.sh

diff --git a/client/virt/scripts/rh_off_services.sh 
b/client/virt/scripts/rh_off_services.sh
new file mode 100755
index 0000000..b095aa4
--- /dev/null
+++ b/client/virt/scripts/rh_off_services.sh
@@ -0,0 +1,30 @@
+#!/bin/bash
+# @author Amos Kong <[email protected]>
+# @copyright: 2012 Red Hat, Inc.
+
+chkconfig  auditd off
+chkconfig  autofs off
+chkconfig  avahi-daemon off
+chkconfig  crond off
+chkconfig  cups off
+chkconfig  ip6tables off
+chkconfig  sendmail off
+chkconfig  smartd off
+chkconfig  xfs off
+chkconfig  acpid off
+chkconfig  atd off
+chkconfig  haldaemon off
+chkconfig  mdmonitor off
+chkconfig  netfs off
+chkconfig  rhnsd off
+chkconfig  rpcgssd off
+chkconfig  rpcidmapd off
+chkconfig  abrtd off
+chkconfig  kdump off
+chkconfig  koan off
+chkconfig  libvirt-guests off
+chkconfig  ntpdate off
+chkconfig  portreserve off
+chkconfig  postfix off
+chkconfig  rhsmcertd off
+chkconfig  tuned off
diff --git a/client/virt/scripts/rh_stop_services.sh 
b/client/virt/scripts/rh_stop_services.sh
new file mode 100755
index 0000000..78df551
--- /dev/null
+++ b/client/virt/scripts/rh_stop_services.sh
@@ -0,0 +1,30 @@
+#!/bin/bash
+# @author Amos Kong <[email protected]>
+# @copyright: 2012 Red Hat, Inc.
+
+service auditd stop
+service avahi-daemon stop
+service anacron stop
+service qpidd stop
+service smartd stop
+service crond stop
+service haldaemon stop
+service opensmd stop
+service openibd stop
+service yum-updatesd stop
+service collectd stop
+service bluetooth stop
+service cups stop
+service cpuspeed stop
+service hidd stop
+service isdn stop
+service kudzu stop
+service lvm2-monitor stop
+service mcstrans stop
+service mdmonitor stop
+service messagebus stop
+service restorecond stop
+service rhnsd stop
+service rpcgssd stop
+service setroubleshoot stop
+service smartd stop

_______________________________________________
Autotest mailing list
[email protected]
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest

Reply via email to