diff options
Diffstat (limited to 'src/os-plugins/plugins/qemukvm/files')
-rw-r--r-- | src/os-plugins/plugins/qemukvm/files/run-virt.include | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/src/os-plugins/plugins/qemukvm/files/run-virt.include b/src/os-plugins/plugins/qemukvm/files/run-virt.include index 64f2b3e1..80b9290d 100644 --- a/src/os-plugins/plugins/qemukvm/files/run-virt.include +++ b/src/os-plugins/plugins/qemukvm/files/run-virt.include @@ -1,7 +1,7 @@ # run-virt.include # ----------------------------------------------------------------------------- # Copyright (c) 2009..2010 - RZ Uni Freiburg -# Copyright (c) 2009..2010 - OpenSLX GmbH +# Copyright (c) 2009..2012 - OpenSLX GmbH # # This program/file is free software distributed under the GPL version 2. # See http://openslx.org/COPYING @@ -220,15 +220,15 @@ cdrom1=${cdtest:-"FALSE"} ide="TRUE" hddrv="ide" -# TODO: nur bei vmchooser -#VIRTCMDOPTS="${VIRTCMDOPTS} -fda /dev/fd0" +# special feature for real and virtual floppy disks +[ ${floppy0} == TRUE ] && VIRTCMDOPTS="${VIRTCMDOPTS} -fda /dev/fd0" #VIRTCMDOPTS="${VIRTCMDOPTS} -fdb ${floppy1name}" # audio VIRTCMDOPTS="${VIRTCMDOPTS} -soundhw all" # serial -#VIRTCMDOPTS="${VIRTCMDOPTS} -serial /dev/ttyS0" +[ ${serial} == ttyS0 ] && VIRTCMDOPTS="${VIRTCMDOPTS} -serial /dev/ttyS0" writelog "Virtual Hardware:" writelog "\tGuest RAM:\t\t${mem} MB" @@ -247,7 +247,14 @@ writelog "\tNetwork kind:\t\t${network_kind}" ### finally set env for run-virt.sh ################################################################################ -# TODO: besser drive statt hda? +# configure and start samba service to provide user's home directory +if [ -f /usr/sbin/smbd ] ; then + sudo /opt/openslx/rootfs/bin/sed -i /etc/qemu/smb.conf -e "s,$USER,USER," + sudo /usr/sbin/nmbd -c /etc/qemu/smb.conf + sudo /usr/sbin/smbd -c /etc/qemu/smb.conf +fi + + #-drive [file=file][,if=type][,bus=n][,unit=m][,media=d][,index=i] # [,cyls=c,heads=h,secs=s[,trans=t]][,snapshot=on|off] # [,cache=writethrough|writeback|none][,format=f][,serial=s] @@ -301,7 +308,7 @@ if [ -c /dev/kvm -a "x${emu}" != "xqemu" ]; then [ -n "$VIRTCMD" ] && break done else - VIRTCMD=$(which qemu 2>/dev/null) + VIRTCMD=$(which qemu-system-i386 2>/dev/null) writelog "KVM available but /dev/kvm not found!" writelog "Trying fallback to QEMU emulation." fi @@ -310,7 +317,7 @@ if [ -z "${VIRTCMD}" ]; then writelog "No QEMU/KVM found, exiting!" rm -rf ${RMDIRS} exit 1 -elif [ "${VIRTCMD##*/}" = "qemu" ]; then +elif [ "${VIRTCMD##*/}" = "qemu-system-i386" ]; then writelog "User space emulation:\t\t${VIRTCMD}" else writelog "User space virtualization:\t${VIRTCMD}" |