Re: [PATCH,RFC] nfsd: Make INET6 transport creation failure an informational message
Roland Dreier wrote: The write_ports code will fail both the INET4 and INET6 transport creation if the transport returns an error when PF_INET6 is specified. Some transports that do not support INET6 return an error other than EAFNOSUPPORT. That's the real bug. Any reason the RDMA RPC transport can't return EAFNOSUPPORT in this case? I think Tom's changelog is misleading. Yes, it should read A transport may fail for some reason other than EAFNOSUPPORT. The problem is that the RDMA transport actually does support IPv6, but it doesn't support the IPV6ONLY option yet. So if NFS/RDMA binds to a port for IPv4, then the IPv6 bind fails because of the port collision. Should we fail INET4 if INET6 fails under any circumstances? Implementing the IPV6ONLY option for RDMA binding is probably not feasible for 2.6.34, so the best band-aid for now seems to be Tom's patch. - R. -- To unsubscribe from this list: send the line unsubscribe linux-rdma in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH,RFC] nfsd: Make INET6 transport creation failure an informational message
If this looks right to everyone, I'll post this to linux-nfs. Tom nfsd: Make INET6 transport creation failure an informational message The write_ports code will fail both the IENT4 and INET6 transport creation if the transport returns an error when PF_INET6 is specified. Some transports that do not support INET6 return an error other than EAFNOSUPPORT. We should allow communication on INET4 even if INET6 is not yet supported or fails for some reason. Signed-off-by: Tom Tucker t...@opengridcomputing.com --- fs/nfsd/nfsctl.c |6 -- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c index 0f0e77f..019a89e 100644 --- a/fs/nfsd/nfsctl.c +++ b/fs/nfsd/nfsctl.c @@ -1008,8 +1008,10 @@ static ssize_t __write_ports_addxprt(char *buf) err = svc_create_xprt(nfsd_serv, transport, PF_INET6, port, SVC_SOCK_ANONYMOUS); - if (err 0 err != -EAFNOSUPPORT) - goto out_close; + if (err 0) + dprintk(nfsd: Error creating PF_INET6 listener for transport '%s'\n, +transport); + return 0; out_close: xprt = svc_find_xprt(nfsd_serv, transport, PF_INET, port); -- To unsubscribe from this list: send the line unsubscribe linux-rdma in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH,RFC] nfsd: Make INET6 transport creation failure an informational message
Looks good. Tom Tucker wrote: If this looks right to everyone, I'll post this to linux-nfs. Tom nfsd: Make INET6 transport creation failure an informational message The write_ports code will fail both the IENT4 and INET6 transport creation if the transport returns an error when PF_INET6 is specified. Some transports that do not support INET6 return an error other than EAFNOSUPPORT. We should allow communication on INET4 even if INET6 is not yet supported or fails for some reason. Signed-off-by: Tom Tucker t...@opengridcomputing.com --- fs/nfsd/nfsctl.c |6 -- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c index 0f0e77f..019a89e 100644 --- a/fs/nfsd/nfsctl.c +++ b/fs/nfsd/nfsctl.c @@ -1008,8 +1008,10 @@ static ssize_t __write_ports_addxprt(char *buf) err = svc_create_xprt(nfsd_serv, transport, PF_INET6, port, SVC_SOCK_ANONYMOUS); -if (err 0 err != -EAFNOSUPPORT) -goto out_close; +if (err 0) +dprintk(nfsd: Error creating PF_INET6 listener for transport '%s'\n, + transport); + return 0; out_close: xprt = svc_find_xprt(nfsd_serv, transport, PF_INET, port); -- To unsubscribe from this list: send the line unsubscribe linux-rdma in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH,RFC] nfsd: Make INET6 transport creation failure an informational message
Hi Bruce/Chuck, RDMA Transports are currently broken in 2.6.34 because they don't have a V4ONLY setsockopt. So what happens is that when write_ports attempts to create the PF_INET6 transport it fails because the port is already in use. There is discussion on linux-rdma about how to fix this, but in the interim and perhaps indefinitely, I propose the following: Tom nfsd: Make INET6 transport creation failure an informational message The write_ports code will fail both the INET4 and INET6 transport creation if the transport returns an error when PF_INET6 is specified. Some transports that do not support INET6 return an error other than EAFNOSUPPORT. We should allow communication on INET4 even if INET6 is not yet supported or fails for some reason. Signed-off-by: Tom Tucker t...@opengridcomputing.com --- fs/nfsd/nfsctl.c |6 -- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c index 0f0e77f..934b624 100644 --- a/fs/nfsd/nfsctl.c +++ b/fs/nfsd/nfsctl.c @@ -1008,8 +1008,10 @@ static ssize_t __write_ports_addxprt(char *buf) err = svc_create_xprt(nfsd_serv, transport, PF_INET6, port, SVC_SOCK_ANONYMOUS); - if (err 0 err != -EAFNOSUPPORT) - goto out_close; + if (err 0) + printk(KERN_INFO nfsd: Error creating PF_INET6 listener + for transport '%s'\n, transport); + return 0; out_close: xprt = svc_find_xprt(nfsd_serv, transport, PF_INET, port); -- To unsubscribe from this list: send the line unsubscribe linux-rdma in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html