]> gitweb.fluxo.info Git - kvm-manager.git/commitdiff
added some arguments gleaned from watching libvirt (still need to switch disk and...
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Wed, 26 Jan 2011 23:47:46 +0000 (18:47 -0500)
committerDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Wed, 26 Jan 2011 23:47:46 +0000 (18:47 -0500)
kvm-manager

index 84795fea927db8af5d56278c283473397c48e22e..2c7eddf3e5d2a04d59024242498500ce5db42d79 100755 (executable)
@@ -41,10 +41,13 @@ up() {
     NETBOOT="$OWNERHOME/vms/$VMNAME/netboot"
     KVMARGS=
     
+    BOOTCHOICE=c
+
     if [ -e "$NETBOOT" ] ; then
-       KVMARGS="-boot n"
+       BOOTCHOICE=n
     elif [ -e "$CDISO" ] && [ -e $(readlink -f "$CDISO") ] ; then
-       KVMARGS="-cdrom $CDISO -boot d"
+       KVMARGS="-cdrom $CDISO"
+        BOOTCHOICE=d
     fi
 
     # set up the disks, if needed:
@@ -62,9 +65,18 @@ up() {
     exec chpst -u "$OWNER:$OWNERGROUP:kvm" \
         /usr/bin/screen -D -m -L -c /etc/screenrc.kvm-manager -S "$VMNAME" -t "$VMNAME" -s /bin/false \
         /usr/bin/kvm $KVMARGS \
+        -M "${MACHINE:-pc}" \
+        -enable-kvm \
+        -nodefaults \
         -nographic \
         -name "$VMNAME" \
         -m "$RAM" \
+        -boot "$BOOTCHOICE" \
+        -chardev "socket,id=monitor,path=$OWNERHOME/vms/$VMNAME/monitor,server,nowait" -mon chardev=monitor,mode=readline \
+        -rtc base=utc \
+        -usb \
+         -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x4 \
+        -chardev stdio,id=serial0 -device isa-serial,chardev=serial0 \
         -smp "${SMP:-1},maxcpus=${MAXCPUS:-8}" \
         -net nic,"macaddr=$MAC" \
         -net "tap,ifname=$TAP,script=no,downscript=no" \