[email protected] writes: > Ho trasformato un'immagine .vdi (VirtualBox) in un'immagine raw .img e > in una compressa .qcow2. > Sto provando a lanciarla con Qemu ma appena inizia il boot di Windows XP > qualcosa va storto e mi compare una schermata nera in cui mi dà la > possibilità di lanciare la modalità provvisoria (ma se ci provo anche > quella non va). > > Idee?
Temo che l'immagine di XP non stia tanto bene. Se arrivi alla schermata in cui ti offre di avviare XP in modalità provvisoria allora vuol dire che qemu/kvm sono partiti correttamente e stanno avviando il sistema ospite. Che però ha problemi di suo. Magari trasformala in formato NON compresso... > Conoscete qualche guida/tutorial ben fatto su Qemu? Per un uso molto > elementare... Come guida non si qualificano molto bene. Hanno qualche anno di onorato servizio però. Nota: uno dei rarissimi casi in cui uso sudo, così la password la do una volta sola e non devo mettere setuid lo script. --------------8<-------------[qemustart]-------------------- #! /bin/bash # (C) 2007, 2008 Chiara Paci, (C) 2011 Gian Uberto Lauri e Chiara Paci # # Distribuito sotto GNU GPL v3 o successive # # http://www.gnu.org/licenses/gpl-3.0-standalone.html function help { echo "$0 -h | [ -N -i <if0> -i <if1> ... ] [ -M <memoria_in_mega> ] [ -U -v <vendor> -p <productid> ] [ -F ] [ -X ] [ -B <boot> ] [ -c <cd> ] [ -f <floppy> ] [-M ] [ -s ] [ -D image ] <hd_image> " echo "B: tipo di boot (stessi di qemu):" echo " c: hd (default)" echo " a: floppy" echo " d: cdrom" echo "F: fullscreen" echo "N: rete" echo "X: 64bit" echo "S: <dev> Device scsi" echo "s: attiva Samba" echo "D: second disk image" echo echo "<ifx>: interfacename or interfacename@MAC address" } function ifacename() { echo $1 | awk -F@ '{print $1}' } function ifacemac() { echo $1 | awk -F@ -v data=`date +20:02:$2:%T` '{print ($2=="")?data:$2}' } isocd="" floppy="" boottype="c" args="-usb " rete="" interfacce='' x64="" memoria="256" scsidev="" usbvendor="" usbproductid="" usb="" usa_samba="" second_image="" while getopts "M:c:f:hB:FNi:XUv:p:S:sD:" opzione do case $opzione in h) help;exit;; c) isocd="$OPTARG";; f) floppy="$OPTARG";; B) boottype="$OPTARG";; F) args="$args -full-screen";; N) rete=yes;; X) x64=yes;; M) memoria="$OPTARG";; i) interfacce="$interfacce $OPTARG";; S) scsidev="yes";; U) usb="yes";; v) vendor="$OPTARG";; p) productid="$OPTARG";; s) usa_samba="SI";; D) second_image="$OPTARG";; esac done hdimage="${!OPTIND}" if [ ! "$hdimage" ] then help exit fi echo -e "\nPrima immagine "$hdimage"\nSeconda immagine "$second_image"\n"; modprobe kvm modprobe kvm-intel export DISPLAY=:0 args="$args -m $memoria" args="$args -boot $boottype" #args="$args -vga std -soundhw all " #args="$args -nographic -serial vc" #args="$args -vnc 192.168.22.250:0 -usbdevice tablet -k it" if [ "$isocd" ] then args="$args -cdrom $isocd" fi if [ "$floppy" ] then args="$args -fda $floppy" fi if [ "$scsidev" ] then args="$args -usbdevice file=/dev/sdb1" fi script_ifup=/usr/local/bin/qemu-ifup if [ "$rete" ] then n=0 for intf in $interfacce do nameifc=`ifacename $intf` macifc=`ifacemac $intf $n` echo "MAC: "$macifc args="$args -net nic,vlan=$n,macaddr=$macifc " args="$args -net tap,vlan=$n,ifname=$nameifc,script=${script_ifup}" echo $args let n=$n+1 done fi if [ "$usb" ] then args="$args -usbdevice host:$vendor:$productid" fi if [ "$usa_samba" ] && ps -fu root | grep -q smbd then echo "Samba richiesto ma non attivo, lo attiviamo ora" sudo /etc/init.d/samba start fi if [ "$second_image" ] then args="$args -hdb $second_image " fi if [ ! "$x64" ] then if id | grep -q 'uid=0(root) gid=0(root) groups=0(root)' then qemu $args -hda $hdimage else echo "Lancio di QEMU a 32 bit" sudo qemu $args -hda $hdimage fi else if id | grep -q 'uid=0(root) gid=0(root) groups=0(root)' then # qemu-system-x86_64 $args -hda $hdimage kvm $args -hda $hdimage else echo "Lancio di QEMU a 64 bit" sudo kvm $args -hda $hdimage fi fi ---------------------------8<-[qemu.ifup]------------------- #!/bin/sh # (C) 2007, 2008 Chiara Paci # # Distribuito sotto GNU GPL v3 o successive echo "Executing /etc/qemu-ifup" if ! ifconfig | grep br0:0 then echo "Bringing ub br0:0" /sbin/ifup br0:0 /usr/local/bin/siirouter fi echo "Bringing up $1 for bridged mode..." /sbin/ifconfig $1 0.0.0.0 promisc up echo "Adding $1 to br0:0..." /sbin/brctl addif br0:0 $1 sleep 2 -------------------------8<--------------------------------- -- /\ ___ Ubuntu: ancient /___/\_|_|\_|__|___Gian Uberto Lauri_____ African word //--\| | \| | Integralista GNUslamico meaning "I can \/ coltivatore diretto di software not install già sistemista a tempo (altrui) perso... Debian" Warning: gnome-config-daemon considered more dangerous than GOTO -- Per REVOCARE l'iscrizione alla lista, inviare un email a [email protected] con oggetto "unsubscribe". Per problemi inviare un email in INGLESE a [email protected] To UNSUBSCRIBE, email to [email protected] with a subject of "unsubscribe". Trouble? Contact [email protected] Archive: https://lists.debian.org/[email protected]

