Bug 510257 - allow more flexibility for read_ahead_kb store
allow more flexibility for read_ahead_kb store
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: kernel (Show other bugs)
All Linux
medium Severity medium
: rc
: ---
Assigned To: Danny Feng
Red Hat Kernel QE team
Depends On:
Blocks: 533192 526775
  Show dependency treegraph
Reported: 2009-07-08 10:03 EDT by Bryn M. Reeves
Modified: 2010-10-23 06:37 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2010-03-30 03:30:35 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Commit from comment #0 rediffed for RHEL5 (487 bytes, patch)
2009-07-08 10:07 EDT, Bryn M. Reeves
no flags Details | Diff

  None (edit)
Description Bryn M. Reeves 2009-07-08 10:03:19 EDT
Description of problem:
RHEL5 inherited a bug from upstream that applies more restrictive checks to the setting of a device's read_ahead_kb parameter when setting the parameter via sysfs instead of via the BLKRASET ioctl:

commit da20a20f3b5c175648fa797c899dd577e4dacb51
Author: Jens Axboe <axboe@suse.de>
Date:   Fri Jul 21 20:30:28 2006 +0200

    [PATCH] ll_rw_blk: allow more flexibility for read_ahead_kb store
    It can make sense to set read-ahead larger than a single request.
    We should not be enforcing such policy on the user. Additionally,
    using the BLKRASET ioctl doesn't impose such a restriction. So
    additionally we now expose identical behaviour through the two.
    Issue also reported by Anton <cbou@mail.ru>
    Signed-off-by: Jens Axboe <axboe@suse.de>

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. echo 2048 > /sys/block/<dev>/queue/read_ahead_kb
2. cat /sys/block/<dev>/queue/read_ahead_kb
3. blockdev --setra 4096 /dev/<dev>
4. cat /sys/block/<dev>/queue/read_ahead_kb
Actual results:
# echo 2048 > /sys/block/sda/queue/read_ahead_kb 
# cat /sys/block/sda/queue/read_ahead_kb
#  blockdev --setra 4096 /dev/sda
# cat /sys/block/sda/queue/read_ahead_kb

Expected results:
# echo 2048 > /sys/block/sda/queue/read_ahead_kb 
# cat /sys/block/sda/queue/read_ahead_kb
#  blockdev --setra 4096 /dev/sda
# cat /sys/block/sda/queue/read_ahead_kb

Additional info:
Comment 1 Bryn M. Reeves 2009-07-08 10:07:05 EDT
Created attachment 350941 [details]
Commit from comment #0 rediffed for RHEL5
Comment 3 RHEL Product and Program Management 2009-09-25 13:39:27 EDT
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
Comment 4 Don Zickus 2009-10-06 15:38:21 EDT
in kernel-2.6.18-168.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 6 Chris Ward 2010-02-11 05:12:36 EST
~~ Attention Customers and Partners - RHEL 5.5 Beta is now available on RHN ~~

RHEL 5.5 Beta has been released! There should be a fix present in this 
release that addresses your request. Please test and report back results 
here, by March 3rd 2010 (2010-03-03) or sooner.

Upon successful verification of this request, post your results and update 
the Verified field in Bugzilla with the appropriate value.

If you encounter any issues while testing, please describe them and set 
this bug into NEED_INFO. If you encounter new defects or have additional 
patch(es) to request for inclusion, please clone this bug per each request
and escalate through your support representative.
Comment 7 Bryn M. Reeves 2010-02-11 07:57:52 EST
Verified in 2.6.18-182.el5:

[root@pe1950-5 ~]# uname -r
[root@pe1950-5 ~]# echo 2048 > /sys/block/sda/queue/read_ahead_kb
[root@pe1950-5 ~]# cat /sys/block/sda/queue/read_ahead_kb
[root@pe1950-5 ~]# blockdev --setra 4096 /dev/sda 
[root@pe1950-5 ~]# cat /sys/block/sda/queue/read_ahead_kb
Comment 9 errata-xmlrpc 2010-03-30 03:30:35 EDT
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.


Note You need to log in before you can comment on or make changes to this bug.