From: Stanislav Kinsbursky <skinsbursky@parallels.com>
To: "bfields@fieldses.org" <bfields@fieldses.org>
Cc: "Trond.Myklebust@netapp.com" <Trond.Myklebust@netapp.com>,
"linux-nfs@vger.kernel.org" <linux-nfs@vger.kernel.org>
Subject: Re: [RFC] RPCBIND: add anonymous listening socket in addition to named one
Date: Thu, 29 Dec 2011 15:48:46 +0400 [thread overview]
Message-ID: <4EFC539E.4050008@parallels.com> (raw)
In-Reply-To: <20111228182213.GA10220@fieldses.org>
28.12.2011 22:22, bfields@fieldses.org пишет:
> On Wed, Dec 28, 2011 at 07:17:30PM +0400, Stanislav Kinsbursky wrote:
>> I've experienced a problem with registering Lockd service with
>> rpcbind in container. My container operates in it's own network
>> namespace context and has it's own root. But on service register,
>> kernel tries to connect to named unix socket by using
>> rpciod_workqueue. Thus any connect is done with the same fs->root,
>
> There's no way to pass the correct context down to the rpc task and from
> there to the registration code?
>
This context is current->fs->root. It's used to lookup unix socket inode by name
on connect.
Obviously, current is always "rpciod_workqueue" kernel thread. And thus has the
same root.
The only solution how to pass and use the context, which I can see, is to expand
sock_xprt with a pointer to corrent root and then set this root before
kernel_connect() and set the old one after.
But this looks ugly and too complicated for the issue, from my pow.
Or maybe you have some more elegant solution to this problem?
--
Best regards,
Stanislav Kinsbursky
prev parent reply other threads:[~2011-12-29 11:49 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-28 15:17 [RFC] RPCBIND: add anonymous listening socket in addition to named one Stanislav Kinsbursky
2011-12-28 17:03 ` Chuck Lever
2011-12-28 17:30 ` Stanislav Kinsbursky
2011-12-28 17:59 ` Chuck Lever
2011-12-29 11:48 ` Stanislav Kinsbursky
2011-12-29 16:03 ` Chuck Lever
2011-12-29 16:12 ` Stanislav Kinsbursky
2011-12-29 16:23 ` Chuck Lever
2011-12-29 17:04 ` Stanislav Kinsbursky
2011-12-29 17:42 ` Stanislav Kinsbursky
2012-01-25 11:12 ` Stanislav Kinsbursky
2012-01-25 14:41 ` bfields
2012-01-25 16:02 ` Stanislav Kinsbursky
2011-12-28 18:22 ` bfields
2011-12-29 11:48 ` Stanislav Kinsbursky [this message]
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=4EFC539E.4050008@parallels.com \
--to=skinsbursky@parallels.com \
--cc=Trond.Myklebust@netapp.com \
--cc=bfields@fieldses.org \
--cc=linux-nfs@vger.kernel.org \
/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