Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-5007

Windows guest does not present fault (slow response) disk

    • Major
    • sst_virtualization_windows
    • ssg_virtualization
    • False
    • Hide

      None

      Show
      None
    • If docs needed, set a value

      Description of problem:

      Emulate one fault disk, it will delay IO about 5 minutes.

      Pass-through the disk to vm and boot it. The vm boot slowly.

      The disk can be found in disk management after boot.

      Version-Release number of selected component (if applicable):

      Red Hat Enterprise Linux release 9.0 Beta (Plow)
      5.14.0-1.7.1.el9.x86_64
      qemu-kvm-6.1.0-8.el9.x86_64
      seabios-bin-1.14.0-6.el9.noarch
      edk2-ovmf-20210527gite1999b264f1f-6.el9.noarch
      virtio-win-prewhql-0.1-214.iso

      (qemu-kvm-6.0.0-13.el9_b.5.x86_64 same result)

      How reproducible:
      100%

      Steps to Reproduce:
      1. emulate fault disk

      1.1 create scsi_debug disk ==>/dev/sdb
      modprobe scsi_debug dev_size_mb=128

      1.2 create dm disk with fault sector ==> /dev/mapper/baddisk

      dmsetup create baddisk << EOF
      0 160000 linear /dev/sdd 0
      160000 5 delay /dev/sdd 160000 0 /dev/sdd 160000 300000
      160005 80000 linear /dev/sdd 160005
      EOF

      1.3 export the dm disk
      (workspace) root@dell-per440-07 /home/vbugs $ targetcli ls
      o- / ..................................................................... [...]
      o- backstores .......................................................... [...]

      o- block .............................................. [Storage Objects: 1]
        o- device.baddisk .. [/dev/mapper/baddisk (117.2MiB) write-thru activated]
        o- alua ............................................... [ALUA Groups: 1]
        o- default_tg_pt_gp ................... [ALUA state: Active/optimized]
      o- fileio ............................................. [Storage Objects: 0]
      o- pscsi .............................................. [Storage Objects: 0]
      o- ramdisk ............................................ [Storage Objects: 0]
      o- iscsi ........................................................ [Targets: 1]
      o- iqn.2019-12.com.redhat:kvm-qe ................................. [TPGs: 1]
      o- tpg1 .............................................. [gen-acls, no-auth]
      o- acls ...................................................... [ACLs: 0]
      o- luns ...................................................... [LUNs: 1]
        o- lun0 [block/device.baddisk (/dev/mapper/baddisk) (default_tg_pt_gp)]
      o- portals ................................................ [Portals: 1]
      o- 0.0.0.0:3260 ................................................. [OK]
      o- loopback ..................................................... [Targets: 0]

      1.4 attach the iscsi disk ==> sde

      lsblk:
      sdd 8:48 0 128M 0 disk
      --baddisk 253:3 0 117.2M 0 dm
      sde 8:64 0 117.2M 0 disk

      2.pass-through the disk and boot it
      /usr/libexec/qemu-kvm \
      -name 'avocado-vt-vm1' \
      -sandbox on \
      -machine pc,memory-backend=mem-machine_mem \
      -nodefaults \
      -device VGA,bus=pci.0,addr=0x2 \
      -m 30720 \
      -object memory-backend-ram,size=30720M,id=mem-machine_mem \
      -smp 10,maxcpus=10,cores=5,threads=1,dies=1,sockets=2 \
      -cpu 'Cascadelake-Server-noTSX',hv_stimer,hv_synic,hv_vpindex,hv_relaxed,hv_spinlocks=0x1fff,hv_vapic,hv_time,hv_frequencies,hv_runtime,hv_tlbflush,hv_reenlightenment,hv_stimer_direct,hv_ipi,+kvm_pv_unhalt \
      \
      -device ich9-usb-ehci1,id=usb1,addr=0x1d.0x7,multifunction=on,bus=pci.0 \
      -device ich9-usb-uhci1,id=usb1.0,multifunction=on,masterbus=usb1.0,addr=0x1d.0x0,firstport=0,bus=pci.0 \
      -device ich9-usb-uhci2,id=usb1.1,multifunction=on,masterbus=usb1.0,addr=0x1d.0x2,firstport=2,bus=pci.0 \
      -device ich9-usb-uhci3,id=usb1.2,multifunction=on,masterbus=usb1.0,addr=0x1d.0x4,firstport=4,bus=pci.0 \
      -device usb-tablet,id=usb-tablet1,bus=usb1.0,port=1 \
      -device virtio-scsi-pci,id=virtio_scsi_pci0,bus=pci.0,addr=0x3 \
      -blockdev node-name=file_image1,driver=file,auto-read-only=on,discard=unmap,aio=threads,filename=/home/kvm_autotest_root/images/win2019-64-virtio-scsi.qcow2,cache.direct=on,cache.no-flush=off \
      -blockdev node-name=drive_image1,driver=qcow2,read-only=off,cache.direct=on,cache.no-flush=off,file=file_image1 \
      -device scsi-hd,id=image1,drive=drive_image1,write-cache=on \
      -blockdev node-name=host_device_stg0,driver=host_device,auto-read-only=on,discard=unmap,aio=threads,filename=/dev/sde,cache.direct=on,cache.no-flush=off \
      -blockdev node-name=drive_stg0,driver=raw,read-only=off,cache.direct=on,cache.no-flush=off,file=host_device_stg0 \
      -device scsi-block,id=stg0,drive=drive_stg0 \
      -device virtio-net-pci,mac=9a:a7:e2:63:66:14,id=idRtFaeP,netdev=idABy47V,bus=pci.0,addr=0x4 \
      -netdev tap,id=idABy47V,vhost=on \
      -blockdev node-name=file_cd1,driver=file,auto-read-only=on,discard=unmap,aio=threads,filename=/home/kvm_autotest_root/iso/windows/winutils.iso,cache.direct=on,cache.no-flush=off \
      -blockdev node-name=drive_cd1,driver=raw,read-only=on,cache.direct=on,cache.no-flush=off,file=file_cd1 \
      -device scsi-cd,id=cd1,drive=drive_cd1 \
      -rtc base=localtime,clock=host,driftfix=slew \
      -boot menu=off,order=cdn,once=c,strict=off \
      -vnc :5 \
      -rtc base=localtime,clock=host,driftfix=slew \
      -boot menu=off,order=cdn,once=c,strict=off \
      -enable-kvm \
      -monitor stdio \
      -qmp tcp:0:5955,server=on,wait=off \

      3.wait for the guest boot,the check the disk
      wmic diskdrive get index
      or disk managerment.

      Actual results:
      Not found the disk

      Expected results:
      The disk should exist and usable.

      Additional info:

      No issue on
      Red Hat Enterprise Linux release 8.4 (Ootpa)
      4.18.0-305.el8.x86_64
      qemu-kvm-5.2.0-16.module+el8.4.0+13043+9eb47245.11.x86_64
      seabios-bin-1.13.0-2.module+el8.3.0+7353+9de0a3cc.noarch
      edk2-ovmf-20200602gitca407c7246bf-4.el8.noarch
      virtio-win-prewhql-0.1-214.iso

      and

      Red Hat Enterprise Linux release 8.2 (Ootpa)
      4.18.0-305.el8.x86_64
      qemu-kvm-4.2.0-18.module+el8.2.0+6278+dfae3426.x86_64
      seabios-bin-1.13.0-1.module+el8.2.0+5520+4e5817f3.noarch
      seabios-1.13.0-1.module+el8.2.0+5520+4e5817f3.x86_64
      edk2-ovmf-20190829git37eef91017ad-9.el8.noarch
      virtio-win-prewhql-0.1-214.iso

      There is no issue on RHEL guest.
      And RHEL guest boot fast.The fault disk looks like does not affect the boot.

            rhn-support-vrozenfe Vadim Rozenfeld
            qingwangrh qing wang
            Vadim Rozenfeld Vadim Rozenfeld
            qing wang qing wang
            Votes:
            0 Vote for this issue
            Watchers:
            13 Start watching this issue

              Created:
              Updated: