Bug 495866

Summary: show_partition() oops when race with rescan_partitions()
Product: Red Hat Enterprise Linux 5 Reporter: Wengang Wang <wen.gang.wang>
Component: kernelAssignee: Jeff Moyer <jmoyer>
Status: CLOSED ERRATA QA Contact: Red Hat Kernel QE team <kernel-qe>
Severity: medium Docs Contact:
Priority: low    
Version: 5.3CC: dzickus, greg.marsden, lmcilroy, mgahagan
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-09-02 08:58:57 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:
Attachments:
Description Flags
show_partition() oops fix patch.
none
Protect the per-gendisk partition array with rcu none

Description Wengang Wang 2009-04-15 09:09:04 UTC
problem is same as bug https://bugzilla.redhat.com/show_bug.cgi?id=495858, but this is for EL5.

Comment 1 Wengang Wang 2009-04-15 09:11:11 UTC
Created attachment 339654 [details]
show_partition() oops fix patch.

the patch fixes the oops.
it's based on kernel 2.6.18-128
please have it included in next release.

Comment 2 Lachlan McIlroy 2009-06-24 05:45:29 UTC
*** Bug 507758 has been marked as a duplicate of this bug. ***

Comment 3 Jeff Moyer 2009-07-10 14:42:10 UTC
Created attachment 351271 [details]
Protect the per-gendisk partition array with rcu

This is basically the same patch, but protecting /proc/diskstats accesses with rcu as well.

Comment 4 Jeff Moyer 2009-07-10 14:44:28 UTC
I ran the above patch through the following test for 16 hours or so without failure:

# while true; do cat /proc/diskstats > /dev/null; done &
# while true; do cat /proc/partitions > /dev/null; done &
# while true; do hdparm -z /dev/sdd; done

Prior to the patch, I could get a failure within seconds.

Comment 5 RHEL Program Management 2009-07-10 15:03:34 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 7 Don Zickus 2009-07-14 20:57:01 UTC
in kernel-2.6.18-158.el5
You can download this test kernel from http://people.redhat.com/dzickus/el5

Please do NOT transition this bugzilla state to VERIFIED until our QE team
has sent specific instructions indicating when to do so.  However feel free
to provide a comment indicating that this fix has been verified.

Comment 10 errata-xmlrpc 2009-09-02 08:58:57 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-2009-1243.html