All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] nfs4: v4 mounts should not need rpcbind running
@ 2011-06-03 14:11 Steve Dickson
  2011-06-03 14:41 ` Chuck Lever
  0 siblings, 1 reply; 4+ messages in thread
From: Steve Dickson @ 2011-06-03 14:11 UTC (permalink / raw)
  To: Linux NFS Mailing List

When RPC services are created with svc_create() an
svc_unregister() is done to remove any stale registrations.

This unregister is not needed with the v4 callback
service and will cause the mount to hang if rpcbind
is not running.

This patch makes the nfs4 callback service a hide service
by setting the vs_hidden flag in the nfs4_callback_version4
structure

Signed-off-by: Steve Dickson <steved@redhat.com>
---
 fs/nfs/callback_xdr.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/fs/nfs/callback_xdr.c b/fs/nfs/callback_xdr.c
index c6c86a7..7c8b800 100644
--- a/fs/nfs/callback_xdr.c
+++ b/fs/nfs/callback_xdr.c
@@ -996,4 +996,5 @@ struct svc_version nfs4_callback_version4 = {
 	.vs_proc = nfs4_callback_procedures1,
 	.vs_xdrsize = NFS4_CALLBACK_XDRSIZE,
 	.vs_dispatch = NULL,
+	.vs_hidden = 1,
 };
-- 
1.7.4.4


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] nfs4: v4 mounts should not need rpcbind running
  2011-06-03 14:11 [PATCH] nfs4: v4 mounts should not need rpcbind running Steve Dickson
@ 2011-06-03 14:41 ` Chuck Lever
  2011-06-03 15:13   ` Steve Dickson
  0 siblings, 1 reply; 4+ messages in thread
From: Chuck Lever @ 2011-06-03 14:41 UTC (permalink / raw)
  To: Steve Dickson; +Cc: Linux NFS Mailing List

Hey-

On Jun 3, 2011, at 10:11 AM, Steve Dickson wrote:

> When RPC services are created with svc_create() an
> svc_unregister() is done to remove any stale registrations.
> 
> This unregister is not needed with the v4 callback
> service and will cause the mount to hang if rpcbind
> is not running.

This should no longer be the case.  The kernel uses connected transports to contact rpcbind these days, and should be able to tell immediately that there is no rpcbind running.  If there is still a hang, something else is wrong.

> This patch makes the nfs4 callback service a hide service
> by setting the vs_hidden flag in the nfs4_callback_version4
> structure

One reason to continue to do this is to have some assurance that no-one else takes the same RPC program number.  Not a big deal.

> Signed-off-by: Steve Dickson <steved@redhat.com>
> ---
> fs/nfs/callback_xdr.c |    1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/fs/nfs/callback_xdr.c b/fs/nfs/callback_xdr.c
> index c6c86a7..7c8b800 100644
> --- a/fs/nfs/callback_xdr.c
> +++ b/fs/nfs/callback_xdr.c
> @@ -996,4 +996,5 @@ struct svc_version nfs4_callback_version4 = {
> 	.vs_proc = nfs4_callback_procedures1,
> 	.vs_xdrsize = NFS4_CALLBACK_XDRSIZE,
> 	.vs_dispatch = NULL,
> +	.vs_hidden = 1,
> };

-- 
Chuck Lever
chuck[dot]lever[at]oracle[dot]com





^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] nfs4: v4 mounts should not need rpcbind running
  2011-06-03 14:41 ` Chuck Lever
@ 2011-06-03 15:13   ` Steve Dickson
  2011-06-03 15:27     ` Chuck Lever
  0 siblings, 1 reply; 4+ messages in thread
From: Steve Dickson @ 2011-06-03 15:13 UTC (permalink / raw)
  To: Chuck Lever; +Cc: Linux NFS Mailing List



On 06/03/2011 10:41 AM, Chuck Lever wrote:
> Hey-
> 
> On Jun 3, 2011, at 10:11 AM, Steve Dickson wrote:
> 
>> When RPC services are created with svc_create() an
>> svc_unregister() is done to remove any stale registrations.
>>
>> This unregister is not needed with the v4 callback
>> service and will cause the mount to hang if rpcbind
>> is not running.
> 
> This should no longer be the case.  The kernel uses connected transports to contact rpcbind these days, and should be able to tell immediately that there is no rpcbind running.  If there is still a hang, something else is wrong.
Ok... The hang was just an theory... I didn't test it out... but I do know
for a fact that when a v4 mount is done, a PMAP_UNSET is set to rpcbind 
which obviously is not needed.  
> 
>> This patch makes the nfs4 callback service a hide service
>> by setting the vs_hidden flag in the nfs4_callback_version4
>> structure
> 
> One reason to continue to do this is to have some assurance that no-one else takes the same RPC program number.  Not a big deal.
Personally I think its a waste of cycles especially when a large
number of mounts are happening at once... Its completely overkill IMHO...

steved.

> 
>> Signed-off-by: Steve Dickson <steved@redhat.com>
>> ---
>> fs/nfs/callback_xdr.c |    1 +
>> 1 files changed, 1 insertions(+), 0 deletions(-)
>>
>> diff --git a/fs/nfs/callback_xdr.c b/fs/nfs/callback_xdr.c
>> index c6c86a7..7c8b800 100644
>> --- a/fs/nfs/callback_xdr.c
>> +++ b/fs/nfs/callback_xdr.c
>> @@ -996,4 +996,5 @@ struct svc_version nfs4_callback_version4 = {
>> 	.vs_proc = nfs4_callback_procedures1,
>> 	.vs_xdrsize = NFS4_CALLBACK_XDRSIZE,
>> 	.vs_dispatch = NULL,
>> +	.vs_hidden = 1,
>> };
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] nfs4: v4 mounts should not need rpcbind running
  2011-06-03 15:13   ` Steve Dickson
@ 2011-06-03 15:27     ` Chuck Lever
  0 siblings, 0 replies; 4+ messages in thread
From: Chuck Lever @ 2011-06-03 15:27 UTC (permalink / raw)
  To: Steve Dickson; +Cc: Linux NFS Mailing List


On Jun 3, 2011, at 11:13 AM, Steve Dickson wrote:

> On 06/03/2011 10:41 AM, Chuck Lever wrote:
>> Hey-
>> 
>> On Jun 3, 2011, at 10:11 AM, Steve Dickson wrote:
>> 
>>> This patch makes the nfs4 callback service a hide service
>>> by setting the vs_hidden flag in the nfs4_callback_version4
>>> structure
>> 
>> One reason to continue to do this is to have some assurance that no-one else takes the same RPC program number.  Not a big deal.
> Personally I think its a waste of cycles especially when a large
> number of mounts are happening at once... Its completely overkill IMHO...

Agreed, and I'm not objecting to this specific change.  The above was just a generic observation.

My overall concern, though, was that we might still be hanging at mount or umount time if rpcbind was absent.

-- 
Chuck Lever
chuck[dot]lever[at]oracle[dot]com





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-06-03 15:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-06-03 14:11 [PATCH] nfs4: v4 mounts should not need rpcbind running Steve Dickson
2011-06-03 14:41 ` Chuck Lever
2011-06-03 15:13   ` Steve Dickson
2011-06-03 15:27     ` Chuck Lever

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.