Bug 572825

Summary: qcow2 image corruption when using cache=writeback
Product: Red Hat Enterprise Linux 5 Reporter: lihuang <lihuang>
Component: kvmAssignee: Kevin Wolf <kwolf>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: high    
Version: 5.5CC: chellwig, cpelland, cward, ehabkost, lihuang, llim, michael.hagmann, plyons, qzhang, szhou, tburke, virt-maint, ykaul
Target Milestone: rcKeywords: OtherQA, ZStream
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: kvm-83-188.el5 Doc Type: Bug Fix
Doc Text:
Following writing metadata to a QCOW2 disk image, metadata was not flushed, which could have potentially caused the disk image to become corrupted in the event of system disruption (such as a power outage). With this update, metadata is flushed after being written, thus increasing QCOW2 image integrity, and decreasing the likelihood of image corruption.
Story Points: ---
Clone Of: 537646
: 607200 (view as bug list) Environment:
Last Closed: 2011-01-13 23:34:11 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 537646    
Bug Blocks: 580948, 612507    

Comment 1 Dor Laor 2010-03-14 10:28:14 UTC
Currently we do not support in cache=wb so it's not urgent. We'll keep it open mainly for tracking

Comment 2 chellwig@redhat.com 2010-06-23 08:43:34 UTC
Kevin's patches to introduce bdrv_(p)write_sync should take care of this.

Comment 10 Douglas Silas 2010-07-28 15:42:05 UTC
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:
Following writing metadata to a QCOW2 disk image, metadata was not flushed, which could have potentially caused the disk image to become corrupted in the event of system disruption (such as a power outage). With this update, metadata is flushed after being written, thus increasing QCOW2 image integrity, and decreasing the likelihood of image corruption.

Comment 12 Shirley Zhou 2010-11-02 10:25:21 UTC
verify this bug with kvm-83-207.el5 as https://bugzilla.redhat.com/show_bug.cgi?id=537646#c13, no crash and no error when checking disk image after host power off.

Change status to verified.

Comment 14 errata-xmlrpc 2011-01-13 23:34:11 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2011-0028.html