Bug 894956 - floppy can not be recognized by Windows guest (q35)
floppy can not be recognized by Windows guest (q35)
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-kvm-rhev (Show other bugs)
7.0
Unspecified Unspecified
high Severity high
: rc
: ---
Assigned To: Marcel Apfelbaum
Virtualization Bugs
:
: 1044878 (view as bug list)
Depends On:
Blocks: 1227278
  Show dependency treegraph
 
Reported: 2013-01-14 01:19 EST by Suqin Huang
Modified: 2015-12-04 11:13 EST (History)
18 users (show)

See Also:
Fixed In Version: qemu-kvm-rhev-2.3.0-7.el7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-12-04 11:13:03 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
devmgmt shows error (43.37 KB, image/png)
2013-11-20 06:59 EST, Xiaoqing Wei
no flags Details

  None (edit)
Description Suqin Huang 2013-01-14 01:19:54 EST
Description of problem:


Version-Release number of selected component (if applicable):
seabios-1.7.2-0.2.gita810e4e7.el7.x86_64
qemu-kvm-1.3.0-3.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. boot guest with floppy attached
cmd:
/usr/libexec/qemu-kvm -nodefaults \
-device ich9-usb-uhci1,id=usb1,bus=pcie.0,addr=0x4 \
-drive file='/home/autotest-devel/client/tests/kvm/images/win7-64.qcow2',if=none,id=drive-ide0-0-0,media=disk,cache=none,format=qcow2,aio=native \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 -device virtio-net-pci,netdev=idUMvixC,mac=9a:87:88:89:8a:8b,bus=pcie.0,addr=0x3,id='idMztaHV' -netdev tap,id=idUMvixC,vhost=on,script=/home/autotest-devel/client/virt/scripts/qemu-ifup-switch \
-m 2048 -smp 2,cores=1,threads=1,sockets=2 -cpu 'Opteron_G3' \
-device usb-tablet,id=usb-tablet1,bus=usb1.0,port=1 -vnc :0 \
-vga cirrus -rtc base=utc,clock=host,driftfix=slew  \
-boot order=cdn,once=c,menu=off   -no-kvm-pit-reinjection -enable-kvm \
-monitor stdio -acpitable file=/root/seabios-rhel7/out/q35-acpi-dsdt.aml \
-drive file='/home/autotest-devel/client/tests/kvm/images/win7-64/answer.vfd',if=none,id=fdc0-0-0,media=disk,snapshot=off,readonly=off,format=raw -global isa-fdc.driveA=fdc0-0-0 -M q35

2. (qemu) info block
drive-ide0-0-0: removable=0 io-status=ok file=/home/autotest-devel/client/tests/kvm/images/win7-64.qcow2 ro=0 drv=qcow2 encrypted=0 bps=0 bps_rd=0 bps_wr=0 iops=0 iops_rd=0 iops_wr=0
fdc0-0-0: removable=1 locked=0 tray-open=0 file=/home/autotest-devel/client/tests/kvm/images/win7-64/answer.vfd ro=0 drv=raw encrypted=0 bps=0 bps_rd=0 bps_wr=0 iops=0 iops_rd=0 iops_wr=0

3. (qemu) info qtree
dev: ICH9 LPC, id ""
        addr = 1f.0
        romfile = <null>
        rombar = 1
        multifunction = on
        command_serr_enable = on
        class ISA bridge, addr 00:1f.0, pci id 8086:2918 (sub 1af4:1100)
        bus: isa.0
          type ISA
          dev: isa-fdc, id ""
            iobase = 0x3f0
            irq = 6
            dma = 2
            driveA = fdc0-0-0
            driveB = <null>
            bootindexA = -1
            bootindexB = -1
            check_media_rate = on
            isa irq 6

  
Actual results:
no floppy A: in guest

Expected results:


Additional info:
Comment 2 langfang 2013-03-11 22:59:29 EDT
Test  win2012-64 guest hit the same issue.
Comment 3 Sibiao Luo 2013-03-13 01:32:48 EDT
Tit this issue on win8-64bit guest under q35. 

But met anther bug 920924 about '-drive...-global...' method fail to detect them correctly when add two floppies, that's the global problem, so i will open a new bug to tracking it.

Best Regards.
Comment 4 huiqingding 2013-08-29 02:10:44 EDT
RHEL7 guest also has this problem.

Attach a floopy "-drive file=floppy-1440K.vfd,if=none,id=drive-fdc0-0-0,format=raw,cache=none -global isa-fdc.driveA=drive-fdc0-0-0". In guest, there is no the device file /dev/fd0.

The cmdline is as following:
/usr/libexec/qemu-kvm -M q35 -cpu SandyBridge -enable-kvm -m 2048 -smp 4,sockets=2,cores=2,threads=1 -name rhel7 -uuid 6afa5f93-2d4f-420f-81c6-e5fdddbd1c83 -drive if=none,id=drive-disk,cache=none,file=rhel7.raw,format=raw,aio=native -device virtio-blk-pci,ioeventfd=on,drive=drive-disk,id=disk,scsi=off,config-wce=off,x-data-plane=on -netdev tap,id=hostnet0,vhost=on,queues=8 -device virtio-net-pci,netdev=hostnet0,id=net0,mac=00:1a:4a:42:0a:00,vectors=17,mq=on -monitor stdio -spice port=5900,disable-ticketing -vga std  -drive file=floppy-1440K.vfd,if=none,id=drive-fdc0-0-0,format=raw,cache=none -global isa-fdc.driveA=drive-fdc0-0-0  -qmp tcp:0:12345,server,nowait

The kernel of host and guest is kernel-3.10.0-11.el7.x86_64.
qemu-kvm is qemu-kvm-1.5.2-4.el7.x86_64.
Comment 5 Xiaoqing Wei 2013-08-29 22:54:05 EDT
As most unattended Windows guest installation people would use floppy to store the answer file, this blocks it, raise to urgent/urgent and add testblocker

Regards,
Xiaoqing
Comment 7 Xiaoqing Wei 2013-09-23 09:07:09 EDT
Per mail discussed,
Q35 is a Tech Preview for RHEL7.0, removing the 'TestBlocker' keyword.

Regards,
Xiaoqing.
Comment 8 Jun Li 2013-10-22 22:36:02 EDT
RHEL7 guest should manually modprobe floppy. Then could recognize floppy inside guest correctly. So I think RHEL7.0 guest doesn't have this issue.
Comment 9 Ronen Hod 2013-11-11 03:03:06 EST
Removed the Blocker+ since Q35 is a tech-preview.
Comment 11 Xiaoqing Wei 2013-11-20 06:59:03 EST
Created attachment 826586 [details]
devmgmt shows error
Comment 12 Karen Noel 2013-12-13 14:54:00 EST
Which versions of windows require floppy?

Can the unattended install use CDROM instead?
Comment 13 Cleber Rosa 2013-12-13 15:28:15 EST
According to:

http://technet.microsoft.com/en-us/library/dd349348(v=ws.10).aspx

"Windows 7 Setup (Setup.exe) will begin automatically. By default, Windows Setup will search the root directory of all removable media for an answer file called Autounattend.xml."

Since this is related to the new XML based answer file which is available starting with Windows 2008, I assume this is truth for every Windows version since then.
Comment 14 juzhang 2013-12-22 22:32:25 EST
*** Bug 1044878 has been marked as a duplicate of this bug. ***
Comment 15 Xiaoqing Wei 2013-12-23 03:15:49 EST
(In reply to Cleber Rodrigues from comment #13)
> According to:
> 
> http://technet.microsoft.com/en-us/library/dd349348(v=ws.10).aspx
> 
> "Windows 7 Setup (Setup.exe) will begin automatically. By default, Windows
> Setup will search the root directory of all removable media for an answer
> file called Autounattend.xml."
> 
> Since this is related to the new XML based answer file which is available
> starting with Windows 2008, I assume this is truth for every Windows version
> since then.

Hi Cleber,

How about when using virtio-scsi-pci based devices ?
a scsi-cd/scsi-hd itself needs vioscsi.* to drive,

or use full virtualized cd-rom devices instead(ide/ahci) ?
Comment 16 Cleber Rosa 2013-12-23 15:39:30 EST
Yes, using a fully virtualized CDROM is exactly what I'd do.

Here you can find a quick hack to virt-test to use a CDROM instead of a floppy. Tested with Windows 7 SP1 x86_64:

https://github.com/clebergnu/virt-test/commit/f83e0b8f4e078cb1f053a5e3342e68a3517e2a9c

This is the resulting qemu command line with this patch:

MALLOC_PERTURB_=1  /bin/qemu-kvm \
    -S  \
    -name 'virt-tests-vm1'  \
    -sandbox on  \
    -M pc  \
    -nodefaults  \
    -vga std  \
    -chardev socket,id=hmp_id_hmp1,path=/tmp/monitor-hmp1-20131223-172531-zvFe3LkL,server,nowait \
    -mon chardev=hmp_id_hmp1,mode=readline  \
    -chardev socket,id=serial_id_serial0,path=/tmp/serial-serial0-20131223-172531-zvFe3LkL,server,nowait \
    -device isa-serial,chardev=serial_id_serial0  \
    -chardev socket,id=seabioslog_id_20131223-172531-zvFe3LkL,path=/tmp/seabios-20131223-172531-zvFe3LkL,server,nowait \
    -device isa-debugcon,chardev=seabioslog_id_20131223-172531-zvFe3LkL,iobase=0x402 \
    -device ich9-usb-uhci1,id=usb1,bus=pci.0,addr=03 \
    -drive id=drive_image1,if=none,aio=native,file=/home/cleber/src/virt-test/shared/data/images/win7-64-sp1.qcow2 \
    -device ide-hd,id=image1,drive=drive_image1,bus=ide.0,unit=0 \
    -device virtio-net-pci,mac=9a:7c:7d:7e:7f:80,id=idPj0RFe,netdev=idkfW7Ls,bus=pci.0,addr=04  \
    -netdev user,id=idkfW7Ls,hostfwd=tcp::5000-:10022,hostfwd=tcp::5001-:12323,hostfwd=tcp::5002-:10023  \
    -m 1024  \
    -smp 2,cores=1,threads=1,sockets=2  \
    -cpu 'SandyBridge' \
    -drive aio=native,media=cdrom,file=/home/cleber/src/virt-test/shared/data/isos/windows/en_windows_7_ultimate_with_sp1_x64_dvd_u_677332.iso,bus=0,unit=1 \
    -drive aio=native,media=cdrom,file=/home/cleber/src/virt-test/shared/data/images/win7-64-sp1/answer.iso,bus=1,unit=0 \
    -drive aio=native,media=cdrom,file=/home/cleber/src/virt-test/shared/data/isos/windows/winutils.iso,bus=1,unit=1 \
    -device usb-tablet,id=usb-tablet1,bus=usb1.0,port=1  \
    -vnc :0  \
    -rtc base=localtime,clock=host,driftfix=none  \
    -boot order=cdn,once=d,menu=off \
    -enable-kvm
Comment 24 Marcel Apfelbaum 2015-06-25 06:42:52 EDT
Merged upstream commit:
commit 557772f26b361ade84acecb366fe6fdd2d55a6d9
    hw/q35: fix floppy controller definition in ich9
Comment 26 Miroslav Rezanina 2015-07-02 15:32:34 EDT
Fix included in qemu-kvm-rhev-2.3.0-7.el7
Comment 33 juzhang 2015-07-29 02:31:16 EDT
According to comment32, set this issue as verified.
Comment 35 errata-xmlrpc 2015-12-04 11:13:03 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-2546.html

Note You need to log in before you can comment on or make changes to this bug.