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.

Bug 915162

Summary: AHCI disk drive (not CD-ROM) doesn't support the readonly=on
Product: Red Hat Enterprise Linux 7 Reporter: Sibiao Luo <sluo>
Component: qemu-kvmAssignee: Virtualization Maintenance <virt-maint>
Status: CLOSED NOTABUG QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.0CC: acathrow, chayang, flang, juzhang, kwolf, michen, pbonzini, qzhang, sluo, 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: Environment:
Last Closed: 2013-02-25 08:10:22 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:

Description Sibiao Luo 2013-02-25 06:03:44 UTC
Description of problem:
boot a guest with a AHCI disk drive (not CD-ROM) adding readonly=on, but the qemu will fail to boot up. while the AHCI(SATA) CD-ROM can support the readonly=on.

Version-Release number of selected component (if applicable):
host info:
kernel-3.7.0-0.34.el7.x86_64
qemu-kvm-1.3.0-5.el7.x86_6
guest info:
kernel-3.7.0-0.34.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1.boot a guest with a AHCI disk drive (not CD-ROM) adding readonly=on.
e.g:...-device ahci,id=ahci1,bus=pci.0,multifunction=on,addr=0x8 -drive file=/home/my-data-disk.raw,if=none,media=disk,format=raw,id=drive-sata-disk,readonly=on -device ide-hd/ide-drive,drive=drive-sata-disk,id=sata-disk,bus=ahci1.0,unit=0
2.
3.
  
Actual results:
after the step 1,
guest fail to boot up with qemu prompt like: 
qemu-kvm: -device ide-hd,drive=drive-sata-disk,id=sata-disk,bus=ahci1.0,unit=0: Can't use a read-only drive
qemu-kvm: -device ide-hd,drive=drive-sata-disk,id=sata-disk,bus=ahci1.0,unit=0: Device 'ide-hd' could not be initialized

Expected results:

Additional info:

Comment 1 Paolo Bonzini 2013-02-25 08:10:22 UTC
The ATA standard does not support read-only hard disks.