Bug 894211
Summary: | fail to works with the serial property for virtio scsi devices(scsi-hd,scsi-disk) | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Sibiao Luo <sluo> |
Component: | qemu-kvm | Assignee: | Virtualization Maintenance <virt-maint> |
Status: | CLOSED NOTABUG | QA Contact: | Virtualization Bugs <virt-bugs> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 7.0 | CC: | acathrow, bsarathy, chayang, dyasny, juzhang, mazhang, michen, mkenneth, pbonzini, qzhang, sluo, stefanha, virt-maint |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | 894210 | Environment: | |
Last Closed: | 2013-01-11 13:48:29 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Comment 1
Sibiao Luo
2013-01-11 03:04:40 UTC
(In reply to comment #2) > > SCSI disks do not have /sys/class/block/<dev>/serial attributes. I believe > this is standard Linux behavior - at least I can't find the serial attribute > code in drivers/scsi/. > > Please check: > $ ls /dev/disk/by-id > > You will see the disk serial is listed. > > Alternatively, you can use: > > $ scsi_id --whitelist /dev/<dev> > 0QEMU QEMU HARDDISK <serial> ok, thanks for your reminds. i mistake between /sys/class/block/<dev>/serial and /dev/disk/by-id. the scsi-block has no such serial property, so i think the qemu-kvm should also disable the serial property for the virtio scsi devices(scsi-hd,scsi-disk), otherwise it will confuse users. > should disable the serial property for the virtio scsi devices(scsi-hd,scsi-
> disk), otherwise it will confuse users.
It works with upstream:
$ x86-64-softmmu/qemu-system-x86_64 --enable-kvm \
-drive file=$HOME/test.img,id=hd,if=none -device virtio-scsi-pci \
-device scsi-disk,serial=foo,drive=hd -m 256
...
# scsi_id --whitelisted /dev/sda
0QEMU QEMU HARDDISK foo
$ x86-64-softmmu/qemu-system-x86_64 --enable-kvm \
-drive file=$HOME/test.img,id=hd,if=none,serial=foo -device virtio-scsi-pci \
-device scsi-disk,drive=hd -m 256
...
# scsi_id --whitelisted /dev/sda
0QEMU QEMU HARDDISK foo
Same with scsi-hd.
scsi-block has no serial property because it uses the physical drive's serial number.
|