Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
Found this bug when test this bug:Bug 1150820 - fail to specify wwn for virtual IDE CD-ROM, so the new bug to track this issue.
Version-Release number of selected component (if applicable):
Host:
# uname -r
3.10.0-210.el7.x86_64
# rpm -q qemu-kvm-rhev
qemu-kvm-rhev-2.1.2-13.el7.x86_64
Guest:
3.10.0-210.el7.x86_64
How reproducible:
100%
Steps to Reproduce:
1.Boot guest with ide disk/ide-cdrom/scsi-cdrom ,all with wmn parameter
-drive file=/root/RHEL-Server-7.0-64-copy.qcow2,if=none,id=drive-virtio-disk,format=qcow2,cache=none,aio=native,werror=stop,rerror=stop -device ide-drive,bus=ide.0,unit=0,wwn=0x5000c50015ea71bb,drive=drive-virtio-disk,id=virtio-disk,bootindex=1...-drive file=/root/en_windows_xp_professional_x64.iso,if=none,id=cd,format=raw,media=cdrom,readonly=on,cache=none,werror=stop,rerror=stop -device ide-drive,bus=ide.0,unit=1,wwn=0x5000c50015ea71ad,drive=cd,id=cdrom...-drive file=/root/en_windows_xp_professional_x64.iso,if=none,media=cdrom,id=drive-cdrom-disk,format=raw,cache=none,aio=native,werror=stop,rerror=stop -device virtio-scsi-pci,bus=pci.0,addr=0x5,id=scsi1 -device scsi-cd,wwn=0x5000c50015ea78aa,drive=drive-cdrom-disk,id=cdrom-disk,bus=scsi1.0
2.In guest
[root@localhost ~]# ll /dev/disk/by-id/wwn-*
lrwxrwxrwx. 1 root root 9 Nov 27 2014 /dev/disk/by-id/wwn-0x5000c50015ea71ad -> ../../sr1--->ide-cdrom
lrwxrwxrwx. 1 root root 9 Nov 27 2014 /dev/disk/by-id/wwn-0x5000c50015ea71bb -> ../../sda
lrwxrwxrwx. 1 root root 10 Nov 27 2014 /dev/disk/by-id/wwn-0x5000c50015ea71bb-part1 -> ../../sda1
lrwxrwxrwx. 1 root root 10 Nov 27 2014 /dev/disk/by-id/wwn-0x5000c50015ea71bb-part2 -> ../../sda2
lrwxrwxrwx. 1 root root 9 Nov 27 2014 /dev/disk/by-id/wwn-0x5000c50015ea78aa -> ../../sr0-->scsi-cdrom
# sg_inq -p 0x83 /dev/sr1--->seem can't get the detail info for id-cdrom
VPD INQUIRY: Device Identification page
invalid VPD response; probably a STANDARD INQUIRY response
# sg_inq -p 0x83 /dev/sr0--->scsi-cdrom
VPD INQUIRY: Device Identification page
Designation descriptor number 1, descriptor length: 20
designator_type: vendor specific [0x0], code_set: ASCII
associated with the addressed logical unit
vendor specific: drive-cdrom-disk
Designation descriptor number 2, descriptor length: 12
designator_type: NAA, code_set: Binary
associated with the addressed logical unit
NAA 5, IEEE Company_id: 0xc50
Vendor Specific Identifier: 0x15ea78aa
[0x5000c50015ea78aa]
# sg_inq -p 0x83 /dev/sda--->ide disk
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: QM00001
Designation descriptor number 2, descriptor length: 72
designator_type: T10 vendor identification, code_set: ASCII
associated with the addressed logical unit
vendor id: ATA
vendor specific: QEMU HARDDISK QM00001
Designation descriptor number 3, descriptor length: 12
designator_type: NAA, code_set: Binary
associated with the addressed logical unit
NAA 5, IEEE Company_id: 0xc50
Vendor Specific Identifier: 0x15ea71bb
[0x5000c50015ea71bb]
Actual results:
Can't get the detail info for id-cdrom
Expected results:
Additional info:
sisi_cdrom and ide disk not hit such issue.
Add the comments from John( from Bug 1150820 - fail to specify wwn for virtual IDE CD-ROM comment6 and commnet7)
John Snow 2014-12-01 10:57:54 EST
I'll have to look at why sg_inq is failing; the bugs that this BZ was cloned from were fixed with a simple patch and I assumed the same patch would alleviate the problems here, but there might be something else causing that command to fail.
It seems that this patch did fix `ll /dev/disk/by-id/wwn-*` where it did not work previously. sg_inq *might* be a separate issue.
I'll research.
John Snow 2014-12-01 18:06:08 EST
It looks as if Linux expects to find the wwn via the ATAPI IDENTIFY and/or ATA IDENTIFY commands, but the sg_inq tool expects to find it via the scsi/atapi inquiry command, in which we do not support for ATAPI entirely correctly.
It might be best to treat this as a separate bug ("IDE ATAPI devices do not respond to VPD inquiries") and fix this there.
Closing this as NOTABUG: After discussions with the author of sg3_utils, it has come to light that most ATAPI devices generally do not claim compliance with this specification and it is not expected that these devices will adhere to the current version of the specification.
As such, do not use sg3_utils with the --id flag or --page=0x83 to try to get the WWN of an ATAPI device. Use --ata instead.