From: Thierry Parmentelat Date: Fri, 23 Jan 2009 13:18:38 +0000 (+0000) Subject: run qemu in smp mode X-Git-Tag: tests-4.3-0~33 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=d42a371173899c719103e7354697c551c4ddbad1;p=tests.git run qemu in smp mode --- diff --git a/system/template-qemu/qemu-start-node b/system/template-qemu/qemu-start-node index 6d5817e..7d327b1 100755 --- a/system/template-qemu/qemu-start-node +++ b/system/template-qemu/qemu-start-node @@ -66,12 +66,17 @@ ls -l /dev/kqemu echo 'Cleaning up pid file' rm -f qemu.pid + + # qemu options # basics ARGS="$ARGS -m ${RAM}" ARGS="$ARGS -hda ${DISK_IMAGE}" ARGS="$ARGS -nographic" ARGS="$ARGS -pidfile qemu.pid" +# how many pysical procs have we got, run in smp mode if possible +procs=$(grep -i mhz /proc/cpuinfo | wc -l ) +if (( $procs >= 2 )) ; then ARGS="$ARGS -smp 2" ; fi # boot from CD ARGS="$ARGS -boot d" ARGS="$ARGS -cdrom ${NODE_ISO}"