From: Vasily Averin <vvs@virtuozzo.com>
To: "linux-nfs@vger.kernel.org" <linux-nfs@vger.kernel.org>,
"J. Bruce Fields" <bfields@fieldses.org>,
Chuck Lever <chuck.lever@oracle.com>,
Trond Myklebust <trond.myklebust@hammerspace.com>,
Anna Schumaker <anna.schumaker@netapp.com>
Subject: Re: unsafe req->rq_xprt using inside bc_svc_process() ?
Date: Thu, 5 Dec 2019 11:40:04 +0300 [thread overview]
Message-ID: <3b4bd000-13f6-bd4e-a0ea-3e4da3882135@virtuozzo.com> (raw)
In-Reply-To: <79494560-1876-494a-0838-cc646eabf68c@virtuozzo.com>
I've found that Trond fixed it recently in commit 875f0706acc
"SUNRPC: The TCP back channel mustn't disappear while requests are outstanding"
On 11/29/19 5:10 PM, Vasily Averin wrote:
> OpenVz team got complain on crash in bc_svc_process().
> Crashed node had 15 running containers with active nfsv4.1 mounts,
> single nfsv4.1-svc thread was processed its back-channel requests.
> In our case nfs41_callback_svc() took rpc_rqst *req from serv->sv_cb_list
> started its processing but found that req->rq_xprt points to already freed
> struct rpc_xprt aka part of struct sock_xprt transport.
>
> Back-channel request was submitted via xprt_complete_bc_request(),
> its processing uses req->rq_xprt reference in many times,
> however I did not found who keeps this reference.
> It seems sock_xprt or even whole its net namespace can be freed before bc_svc_process() will start processing of submitted back-channel request, and req->rq_xprt using is unsafe in bc_svc_process()
>
> Am I missed something probably?
next prev parent reply other threads:[~2019-12-05 8:40 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-29 14:10 unsafe req->rq_xprt using inside bc_svc_process() ? Vasily Averin
2019-12-05 8:40 ` Vasily Averin [this message]
2019-12-06 21:20 ` J. Bruce Fields
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3b4bd000-13f6-bd4e-a0ea-3e4da3882135@virtuozzo.com \
--to=vvs@virtuozzo.com \
--cc=anna.schumaker@netapp.com \
--cc=bfields@fieldses.org \
--cc=chuck.lever@oracle.com \
--cc=linux-nfs@vger.kernel.org \
--cc=trond.myklebust@hammerspace.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).