Hide Forgot
Description of problem: use local image as guest disk,attached twice on different virtio-scsi-pci.In guest we get different wwid,so can't configure multipath. Version-Release number of selected component (if applicable): # uname -r;rpm -q qemu-kvm 2.6.32-246.el6.x86_64 qemu-kvm-0.12.1.2-2.236.el6.x86_64 How reproducible: 100% Steps to Reproduce: 1.boot a guest with one local raw image attached twice,like /usr/libexec/qemu-kvm -M rhel6.2.0 -cpu cpu64-rhel6 -enable-kvm -m 2G -smp 2,sockets=1,cores=2,threads=1 -name win2003sp2 -uuid 125b7bc8-1b37-49e9-9a33-7e8917c34b88 -rtc base=localtime,driftfix=slew -device virtio-serial-pci,id=virtio-serial0,max_ports=16,bus=pci.0,addr=0x4 -drive file=/home/RHEL6.3_20120304.n.0_x86_64_0308.qcow2,if=none,id=scsi0,format=qcow2,cache=none,werror=stop,rerror=stop,aio=native -device virtio-scsi-pci,id=sysscsi0,bus=pci.0,addr=0x5 -device scsi-hd,drive=scsi0 -netdev tap,id=hostnet0,vhost=on,script=/etc/qemu-ifup-switch -device virtio-net-pci,netdev=hostnet0,id=net0,mac=00:1a:4a:42:1a:52,bus=pci.0,addr=0x3 -chardev socket,id=charchannel0,path=/tmp/wdai-test,server,nowait -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.rhevm.vdsm -spice port=9000,disable-ticketing -vga qxl -global qxl-vga.vram_size=33554432 -usb -device usb-tablet,id=input0 -device virtio-balloon-pci,id=balloon0,addr=0x7 -boot c -monitor stdio -drive file=/home/datadisk.raw,if=none,format=raw,id=datadisk1 -device virtio-scsi-pci,id=scsipci1 -device scsi-hd,drive=datadisk1,serial=test -drive file=/home/datadisk.raw,if=none,format=raw,id=datadisk2 -device virtio-scsi-pci,id=scsipci2 -device scsi-hd,drive=datadisk2,serial=test 2.in guest check wwid # scsi_id --whitelisted --replace-whitespace --device=/dev/sdb # scsi_id --whitelisted --replace-whitespace --device=/dev/sdc 3. Actual results: after get different wwids 0QEMU_QEMU_HARDDISK_datadisk1 0QEMU_QEMU_HARDDISK_datadisk2 So,can't configure multipath. Expected results: should get the same wwids. Additional info: If there are other ways to configure multi-path, please correct me. Thanks
On real hardware: $ sudo sg_inq -p 0x80 /dev/sda VPD INQUIRY: Unit serial number page Unit serial number: 5TG11QWL $ sudo sg_inq -p 0x83 /dev/sda VPD INQUIRY: Device Identification page Designation descriptor number 1, descriptor length: 24 designator_type: vendor specific [0x0], code_set: ASCII associated with the addressed logical unit vendor specific: 5TG11QWL So if a serial is provided we must use it in page 0x83. Better do it before 6.3 so that we don't change guest-visible properties later.
Reproduced and verified this issue with the same steps as weidai. Reproduced this issue with the environment and test results as following: host info: # uname -r && rpm -q qemu-kvm 2.6.32-251.el6.x86_64 qemu-kvm-0.12.1.2-2.241.el6.x86_64 Actual results: # scsi_id --whitelisted --replace-whitespace --device=/dev/sdb 0QEMU_QEMU_HARDDISK_datadisk1 # scsi_id --whitelisted --replace-whitespace --device=/dev/sdc 0QEMU_QEMU_HARDDISK_datadisk2 Verified this issue with the environment and test results as following: host info: # uname -r && rpm -q qemu-kvm 2.6.32-251.el6.x86_64 qemu-kvm-0.12.1.2-2.267.el6.x86_64 Actual results: # scsi_id --whitelisted --replace-whitespace --device=/dev/sdb 0QEMU_QEMU_HARDDISK_test # scsi_id --whitelisted --replace-whitespace --device=/dev/sdc 0QEMU_QEMU_HARDDISK_test Above all, this issue has been fixed.
Technical note added. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. New Contents: No documentation needed
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. http://rhn.redhat.com/errata/RHBA-2012-0746.html