From c79bc15426f3edd32a97869fb25e2003123f8e10 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Tue, 2 Jul 2024 10:06:20 -0300 Subject: Fix: QEMU parameter updates --- ChangeLog.md | 9 +++++++++ IDEAS.md | 11 ----------- kvmx | 60 ++++++++++++++++++++++++++++++------------------------------ 3 files changed, 39 insertions(+), 41 deletions(-) diff --git a/ChangeLog.md b/ChangeLog.md index d2062bd..4e6c394 100644 --- a/ChangeLog.md +++ b/ChangeLog.md @@ -2,6 +2,15 @@ ## 0.1.1 - unreleased +* QEMU parameter updates: + * Update `nowait` to `wait=off`. + + * Update `server` to `server=on`. + + * Update `unix` to `unix=on`. + + * Update `disable-ticketing` to `disable-ticketing=on`. + * Provide default parameters by loading the sample config. This allows a `kvmxfile` to be small and have only the overrides. diff --git a/IDEAS.md b/IDEAS.md index fee448f..fb8d375 100644 --- a/IDEAS.md +++ b/IDEAS.md @@ -1,16 +1,5 @@ # Ideas -## Options - -* Short-form deprectations that may need to be upgraded soon: - * Update `nowait` to `wait=off`. - - * Update `server` to `server=on`. - - * Update `unix` to `unix=on`. - - * Update `disable-ticketing` to `disable-ticketing=on`. - ## Usability * Docs (tutorial and manpage). diff --git a/kvmx b/kvmx index 8071edb..2756896 100755 --- a/kvmx +++ b/kvmx @@ -547,7 +547,7 @@ function kvmx_up { # Otherwise any guest could open a spice connection to another guest using the host local IP (10.0.2.2) and the other guest spice port if [ -z "$spice" ] || [ "$spice" == "1" ]; then #spice_opts="-spice port=$PORT,addr=127.0.0.1,disable-ticketing,streaming-video=off,jpeg-wan-compression=never,playback-compression=off,zlib-glz-wan-compression=never,image-compression=off" - spice_opts="-spice unix,addr=$SPICESOCKET,disable-ticketing,streaming-video=off,jpeg-wan-compression=never,playback-compression=off,zlib-glz-wan-compression=never,image-compression=off" + spice_opts="-spice unix=on,addr=$SPICESOCKET,disable-ticketing=on,streaming-video=off,jpeg-wan-compression=never,playback-compression=off,zlib-glz-wan-compression=never,image-compression=off" spice_opts="$spice_opts -device virtio-serial-pci" spice_opts="$spice_opts -device virtserialport,chardev=spicechannel0,name=com.redhat.spice.0" spice_opts="$spice_opts -chardev spicevmc,id=spicechannel0,name=vdagent" @@ -593,39 +593,39 @@ function kvmx_up { # Run virtual machine, nohup approach # See https://en.wikipedia.org/wiki/Nohup#Overcoming_hanging - #nohup setsid kvm -m $memory -name $VM \ - # -chardev "socket,id=monitor,path=$MONITORFILE,server,nowait" -mon chardev=monitor,mode=readline \ - # -chardev "socket,id=serial0,path=$CONSOLEFILE,server,nowait" -device isa-serial,chardev=serial0 \ - # -smp $smp -cpu host \ - # $balloon \ - # $graphics $shared \ - # $image_opts \ - # $spice_opts \ - # $sound_opts \ - # $cdrom_opts \ - # $boot_opts \ - # $net_opts \ - # $rng_opts \ + #nohup setsid kvm -m $memory -name $VM \ + # -chardev "socket,id=monitor,path=$MONITORFILE,server=on,wait=off" -mon chardev=monitor,mode=readline \ + # -chardev "socket,id=serial0,path=$CONSOLEFILE,server=on,wait=off" -device isa-serial,chardev=serial0 \ + # -smp $smp -cpu host \ + # $balloon \ + # $graphics $shared \ + # $image_opts \ + # $spice_opts \ + # $sound_opts \ + # $cdrom_opts \ + # $boot_opts \ + # $net_opts \ + # $rng_opts \ # $qemu_opts &> $LOGFILE < /dev/null & # Run virtual machine, screen approach # This is more immune to hangups - screen $screen_log $LOGFILE -S kvmx-qemu-$VM -d -m kvm -m $memory -name $VM \ - -chardev "socket,id=monitor,path=$MONITORFILE,server,nowait" -mon chardev=monitor,mode=readline \ - -chardev "socket,id=serial0,path=$CONSOLEFILE,server,nowait" -device isa-serial,chardev=serial0 \ - -smp $smp -cpu host \ - $balloon \ - $graphics $shared \ - $image_opts \ - $spice_opts \ - $sound_opts \ - $cdrom_opts \ - $boot_opts \ - $net_opts \ - $rng_opts \ - $usb_opts \ - -pidfile $PIDFILE \ - -D $LOGFILE \ + screen $screen_log $LOGFILE -S kvmx-qemu-$VM -d -m kvm -m $memory -name $VM \ + -chardev "socket,id=monitor,path=$MONITORFILE,server=on,wait=off" -mon chardev=monitor,mode=readline \ + -chardev "socket,id=serial0,path=$CONSOLEFILE,server=on,wait=off" -device isa-serial,chardev=serial0 \ + -smp $smp -cpu host \ + $balloon \ + $graphics $shared \ + $image_opts \ + $spice_opts \ + $sound_opts \ + $cdrom_opts \ + $boot_opts \ + $net_opts \ + $rng_opts \ + $usb_opts \ + -pidfile $PIDFILE \ + -D $LOGFILE \ $qemu_opts # Only if nohup approach is being used -- cgit v1.2.3