Bug 27709 - critical nfs update
Summary: critical nfs update
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: kernel
Version: 7.1
Hardware: All
OS: Linux
high
high
Target Milestone: ---
Assignee: Arjan van de Ven
QA Contact: Brock Organ
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2001-02-15 04:54 UTC by Seth Vidal
Modified: 2005-10-31 22:00 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2001-02-15 16:59:15 UTC
Embargoed:


Attachments (Terms of Use)

Description Seth Vidal 2001-02-15 04:54:19 UTC
The update listed here:


> From: Neil Brown 
> Linus,
>  Please consider this for inclusion in 2.4.2
> 
>  The nfsd reply cache is currently not properly distinguishing between
>  different clients.  This is because rqstr->rq_addrlen is not being
>  set by net/sunrpc (atleast, not for udp).
> 
>  A better fix might be to make sure it is set properly, but a lot of
>  the code currently has hardcoded knowledge that AT_INET is the only
>  protocol in use, so hardcoding the address length in the memcmp seem
>  acceptable, for now at least.
> 
>  Without this fix, heavy nfs traffic from a large number of clients
>  can cause file corruption as some write requests get incorrectly
>  served from the cache instead of actually sending data to disk
> 
> NeilBrown
> 
> --- ./fs/nfsd/nfscache.c      2001/02/15 01:15:20     1.1
> +++ ./fs/nfsd/nfscache.c      2001/02/15 01:19:49     1.2
> @@ -192,7 +192,7 @@
>                   xid == rp->c_xid && proc == rp->c_proc &&
>                   proto == rp->c_prot && vers == rp->c_vers &&
>                   time_before(jiffies, rp->c_timestamp + 120*HZ) &&
> -                 memcmp((char*)&rqstp->rq_addr, (char*)&rp->c_addr,
rqstp->rq_addrlen)==0) {
> +                 memcmp((char*)&rqstp->rq_addr, (char*)&rp->c_addr,
sizeof(rp->c_addr))==0) {
>                       nfsdstats.rchits++;
>                       goto found_entry;
>               }
> 


The email say it all.

-sv

Comment 1 Arjan van de Ven 2001-02-15 17:09:34 UTC
Patch will be in the next kernel build.


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