"svc: unknown version (3)" when CONFIG_NFSD_V4=y
Subsystems (3)
Hi Neil,
NFS mounting succeeded, but the kernel gives a warning. I'm running 2.6.20-rc2-mm1.
# mount -o vers=3 localhost:/suse /mnt [ 689.651606] svc: unknown version (3) # mount | grep suse localhost:/suse on /mnt type nfs (rw,nfsvers=3,addr=127.0.0.1)
Any clues about it?
Short .config:
#
# Automatically generated make config: don't edit
# Linux kernel version: 2.6.20-rc2-mm1
# Thu Jan 4 15:55:02 2007
#CONFIG_X86_64=yCONFIG_64BIT=yCONFIG_X86=y
......
#
# Network File Systems
#CONFIG_NFS_FS=mCONFIG_NFS_V3=yCONFIG_NFS_V3_ACL=y
# CONFIG_NFS_V4 is not setCONFIG_NFS_DIRECTIO=yCONFIG_NFSD=mCONFIG_NFSD_V2_ACL=yCONFIG_NFSD_V3=yCONFIG_NFSD_V3_ACL=yCONFIG_NFSD_V4=yCONFIG_NFSD_TCP=yCONFIG_LOCKD=mCONFIG_LOCKD_V4=yCONFIG_EXPORTFS=mCONFIG_NFS_ACL_SUPPORT=mCONFIG_NFS_COMMON=yCONFIG_SUNRPC=mCONFIG_SUNRPC_GSS=mCONFIG_RPCSEC_GSS_KRB5=mCONFIG_RPCSEC_GSS_SPKM3=mCONFIG_SMB_FS=m
# CONFIG_SMB_NLS_DEFAULT is not setCONFIG_CIFS=mCONFIG_CIFS_STATS=y
# CONFIG_CIFS_STATS2 is not set
# CONFIG_CIFS_WEAK_PW_HASH is not setCONFIG_CIFS_XATTR=yCONFIG_CIFS_POSIX=y
# CONFIG_CIFS_DEBUG2 is not set
# CONFIG_CIFS_EXPERIMENTAL is not set
# CONFIG_NCP_FS is not set
# CONFIG_CODA_FS is not set
# CONFIG_AFS_FS is not setCONFIG_9P_FS=m
......
Thanks,
Wu
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 9 lines · Fengguang Wu
Hi Neil,
NFS mounting succeeded, but the kernel gives a warning. I'm running 2.6.20-rc2-mm1.
# mount -o vers=3 localhost:/suse /mnt [ 689.651606] svc: unknown version (3) # mount | grep suse localhost:/suse on /mnt type nfs (rw,nfsvers=3,addr=127.0.0.1)
Are you perhaps running the userland NFS server instead of knfsd? The former will only support NFSv2.
Trond
Quoted 6 lines · Trond Myklebust
Quoted 5 lines · Fengguang Wu
Hi Neil,
NFS mounting succeeded, but the kernel gives a warning. I'm running 2.6.20-rc2-mm1.
Quoted 7 lines
Quoted 4 lines
# mount -o vers=3 localhost:/suse /mnt [ 689.651606] svc: unknown version (3) # mount | grep suse localhost:/suse on /mnt type nfs (rw,nfsvers=3,addr=127.0.0.1)Are you perhaps running the userland NFS server instead of knfsd? The former will only support NFSv2.
I'm running kernel nfs servers:
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND root 5451 0.0 0.0 0 0 ? S 19:30 0:00 [nfsd] root 5452 0.0 0.0 0 0 ? S 19:30 0:00 [nfsd] root 5453 0.0 0.0 0 0 ? S 19:30 0:00 [nfsd] root 5454 0.0 0.0 0 0 ? S 19:30 0:00 [nfsd] root 5455 0.0 0.0 0 0 ? S 19:30 0:00 [nfsd] root 5456 0.0 0.0 0 0 ? S 19:30 0:00 [nfsd] root 5457 0.0 0.0 0 0 ? S 19:30 0:00 [nfsd] root 5458 0.0 0.0 0 0 ? S 19:30 0:00 [nfsd] root 5449 0.0 0.0 0 0 ? S< 19:30 0:00 [rpciod/0] root 5450 0.0 0.0 0 0 ? S< 19:30 0:00 [rpciod/1] root 5462 0.0 0.0 7940 672 ? Ss 19:30 0:00 /usr/sbin/rpc.mountd statd 5527 0.0 0.0 7892 1084 ? Ss 19:30 0:00 /sbin/rpc.statd root 5538 0.0 0.0 23168 764 ? Ss 19:30 0:00 /usr/sbin/rpc.idmapd
My system is Debian etch. And I just found that CONFIG_NFSD_V4 is irrelevant, the message remains even if it is disabled. I'll check more kernel versions.
Thanks,
Wu
Quoted 11 lines · On Friday January 5, [email protected] wrote:
Hi Neil,
NFS mounting succeeded, but the kernel gives a warning. I'm running 2.6.20-rc2-mm1.
# mount -o vers=3 localhost:/suse /mnt [ 689.651606] svc: unknown version (3) # mount | grep suse localhost:/suse on /mnt type nfs (rw,nfsvers=3,addr=127.0.0.1)Any clues about it?
Weird.
Please try this patch. It should provide more useful information.
NeilBrown
### Diffstat output
./net/sunrpc/svc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
net/sunrpc/svc.c +2 -1
@@ -910,7 +910,8 @@ err_bad_prog: err_bad_vers:#ifdef RPC_PARANOIA -printk ("svc: unknown version (%d)\n" , vers); +printk ("svc: unknown version (%d for prog %d, %s)\n" , + vers, prog, progp->pg_name);#endif serv->sv_stats->rpcbadfmt++;svc_putnl (resv,RPC_PROG_MISMATCH );
Quoted 29 lines · Neil Brown
Quoted 11 lines · On Friday January 5, [email protected] wrote:
Hi Neil,
NFS mounting succeeded, but the kernel gives a warning. I'm running 2.6.20-rc2-mm1.
# mount -o vers=3 localhost:/suse /mnt [ 689.651606] svc: unknown version (3) # mount | grep suse localhost:/suse on /mnt type nfs (rw,nfsvers=3,addr=127.0.0.1)Any clues about it?
Weird.
Please try this patch. It should provide more useful information.
NeilBrown
Signed-off-by Neil Brown <[email protected]>### Diffstat output
./net/sunrpc/svc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)diff
.prev/net/sunrpc/svc.c./net/sunrpc/svc.c
net/sunrpc/svc.c err_bad_prog: · line 917
Quoted 9 lines
net/sunrpc/svc.c +2
-1@@ -910,7 +910,8 @@ err_bad_prog: err_bad_vers:#ifdef RPC_PARANOIA -printk ("svc: unknown version (%d)\n" , vers); +printk ("svc: unknown version (%d for prog %d, %s)\n" , + vers, prog, progp->pg_name);#endif serv->sv_stats->rpcbadfmt++;svc_putnl (resv,RPC_PROG_MISMATCH );
root ~# mount localhost:/suse /mnt
[ 132.678204] svc: unknown version (3 for prog 100227, nfsd)
I've confirmed that 2.6.20-rc2-mm1, 2.6.20-rc3-mm1, 2.6.19-rc6-mm1 all have this warning, while 2.6.17-2-amd64 is good.
Thanks,
Wu
Quoted 5 lines · Fengguang Wu <fengguang.wu <at> gmail.com> writes:
root ~# mount localhost:/suse /mnt
[ 132.678204] svc: unknown version (3 for prog 100227, nfsd)I've confirmed that 2.6.20-rc2-mm1, 2.6.20-rc3-mm1, 2.6.19-rc6-mm1 all have this warning, while 2.6.17-2-amd64 is good.
I get the same log messages here with 2.6.19. I also noticed the following messages when starting rpc.nfsd:
nfsd[1287]: nfssvc: writting fds to kernel failed: errno 0 (Success) nfsd[1287]: nfssvc: writting fds to kernel failed: errno 0 (Success)
These messages appeared with kernel 2.6.19 too. I however don't know if this could be related to the other messages.
I use nfs-utils 1.0.10 on Debian Etch.
Arnaud Giersch
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 6 lines · On Wednesday January 10, [email protected] wrote:
root ~# mount localhost:/suse /mnt
[ 132.678204] svc: unknown version (3 for prog 100227, nfsd)I've confirmed that 2.6.20-rc2-mm1, 2.6.20-rc3-mm1, 2.6.19-rc6-mm1 all have this warning, while 2.6.17-2-amd64 is good.
Thanks. That helps a lot.
This patch should help too. Please let me know.
NeilBrown
### Diffstat output
./fs/nfsd/nfssvc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
fs/nfsd/nfssvc.c +3 -3
@@ -72,7 +72,7 @@ static struct svc_program nfsd_acl_progr .pg_prog = NFS_ACL_PROGRAM, .pg_nvers = NFSD_ACL_NRVERS, .pg_vers = nfsd_acl_versions, - .pg_name = "nfsd", + .pg_name = "nfsacl", .pg_class = "nfsd", .pg_stats = &nfsd_acl_svcstats, .pg_authenticate = &svc_set_client,
@@ -121,13 +121,13 @@ int nfsd_vers(int vers, enum vers_op chabreak ;#if defined(CONFIG_NFSD_V2_ACL ) || defined(CONFIG_NFSD_V3_ACL )if (vers <NFSD_ACL_NRVERS ) - nfsd_acl_version[vers] = nfsd_acl_version[vers]; + nfsd_acl_versions[vers] = nfsd_acl_version[vers];#endif case NFSD_CLEAR : nfsd_versions[vers] =NULL ;#if defined(CONFIG_NFSD_V2_ACL ) || defined(CONFIG_NFSD_V3_ACL )if (vers <NFSD_ACL_NRVERS ) - nfsd_acl_version[vers] =NULL ; + nfsd_acl_versions[vers] =NULL ;#endif break ;case NFSD_TEST :
Neil,
Quoted 11 lines · Neil Brown
Quoted 6 lines · On Wednesday January 10, [email protected] wrote:
root ~# mount localhost:/suse /mnt
[ 132.678204] svc: unknown version (3 for prog 100227, nfsd)I've confirmed that 2.6.20-rc2-mm1, 2.6.20-rc3-mm1, 2.6.19-rc6-mm1 all have this warning, while 2.6.17-2-amd64 is good.
Thanks. That helps a lot.
This patch should help too. Please let me know.
# mount localhost:/suse /mnt [ 2058.438236] svc: unknown version (3 for prog 100227, nfsd)
# pss nfs USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND root 5488 0.0 0.0 0 0 ? S 22:16 0:00 [nfsd] root 5489 0.0 0.0 0 0 ? S 22:16 0:00 [nfsd] root 5490 0.0 0.0 0 0 ? S 22:16 0:00 [nfsd] root 5491 0.0 0.0 0 0 ? S 22:16 0:00 [nfsd] root 5492 0.0 0.0 0 0 ? S 22:16 0:00 [nfsd] root 5493 0.0 0.0 0 0 ? S 22:16 0:00 [nfsd] root 5494 0.0 0.0 0 0 ? S 22:16 0:00 [nfsd] root 5495 0.0 0.0 0 0 ? S 22:16 0:00 [nfsd] # pss rpc USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND root 5486 0.0 0.0 0 0 ? S< 22:16 0:00 [rpciod/0] root 5487 0.0 0.0 0 0 ? S< 22:16 0:00 [rpciod/1] root 5499 0.0 0.0 7944 668 ? Ss 22:16 0:00 /usr/sbin/rpc.mountd statd 5567 0.0 0.0 7892 1084 ? Ss 22:16 0:00 /sbin/rpc.statd root 5578 0.0 0.0 23180 652 ? Ss 22:16 0:00 /usr/sbin/rpc.idmapd
Thanks,
Wu
Quoted 35 lines
Signed-off-by Neil Brown <[email protected]>### Diffstat output
./fs/nfsd/nfssvc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)diff
.prev/fs/nfsd/nfssvc.c./fs/nfsd/nfssvc.cfs/nfsd/nfssvc.c +3
-3@@ -72,7 +72,7 @@ static struct svc_program nfsd_acl_progr .pg_prog = NFS_ACL_PROGRAM, .pg_nvers = NFSD_ACL_NRVERS, .pg_vers = nfsd_acl_versions, - .pg_name = "nfsd", + .pg_name = "nfsacl", .pg_class = "nfsd", .pg_stats = &nfsd_acl_svcstats, .pg_authenticate = &svc_set_client,@@ -121,13 +121,13 @@ int nfsd_vers(int vers, enum vers_op chabreak ;#if defined(CONFIG_NFSD_V2_ACL ) || defined(CONFIG_NFSD_V3_ACL )if (vers <NFSD_ACL_NRVERS ) - nfsd_acl_version[vers] = nfsd_acl_version[vers]; + nfsd_acl_versions[vers] = nfsd_acl_version[vers];#endif case NFSD_CLEAR : nfsd_versions[vers] =NULL ;#if defined(CONFIG_NFSD_V2_ACL ) || defined(CONFIG_NFSD_V3_ACL )if (vers <NFSD_ACL_NRVERS ) - nfsd_acl_version[vers] =NULL ; + nfsd_acl_versions[vers] =NULL ;#endif break ;case NFSD_TEST :
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 11 lines · On Thursday January 11, [email protected] wrote:
Neil,
Quoted 8 lines · Neil Brown
Quoted 6 lines · On Wednesday January 10, [email protected] wrote:
root ~# mount localhost:/suse /mnt
[ 132.678204] svc: unknown version (3 for prog 100227, nfsd)I've confirmed that 2.6.20-rc2-mm1, 2.6.20-rc3-mm1, 2.6.19-rc6-mm1 all have this warning, while 2.6.17-2-amd64 is good.
Quoted 6 lines
Quoted 3 lines
Thanks. That helps a lot.
This patch should help too. Please let me know.
# mount localhost:/suse /mnt [ 2058.438236] svc: unknown version (3 for prog 100227, nfsd)
Are you really really double-plus sure that you are running a kernel with the patch applied?
Because at the very least it should have changed the message to
Quoted 1 line
[ 2058.438236] svc: unknown version (3 for prog 100227, nfsacl)
NeilBrown
Quoted 14 lines · Neil Brown
Quoted 13 lines · On Thursday January 11, [email protected] wrote:
Neil,
Quoted 10 lines · Neil Brown
Quoted 6 lines · On Wednesday January 10, [email protected] wrote:
root ~# mount localhost:/suse /mnt
[ 132.678204] svc: unknown version (3 for prog 100227, nfsd)I've confirmed that 2.6.20-rc2-mm1, 2.6.20-rc3-mm1, 2.6.19-rc6-mm1 all have this warning, while 2.6.17-2-amd64 is good.
Thanks. That helps a lot.
Quoted 8 lines
Quoted 4 lines
Quoted 1 line
This patch should help too. Please let me know.
# mount localhost:/suse /mnt [ 2058.438236] svc: unknown version (3 for prog 100227, nfsd)Are you really really double-plus sure that you are running a kernel with the patch applied?
Because at the very least it should have changed the message to
Oh, sorry. I recompiled & installed kernel and it output this new message:
[ 133.129919] svc: unknown version (3 for prog 100227, nfsacl)
Regards,
Wu
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 8 lines · On Friday January 12, [email protected] wrote:
Quoted 3 lines
Are you really really double-plus sure that you are running a kernel with the patch applied?
Because at the very least it should have changed the message toOh, sorry. I recompiled & installed kernel and it output this new message:
[ 133.129919] svc: unknown version (3 for prog 100227, nfsacl)
Ok, thanks. I must have missed something else wrong in the code......
Probably this 'break' in the wrong place...
Could you try this patch instead please - or just move the 'break' to where it should be.
Thanks,
NeilBrown
### Diffstat output
./fs/nfsd/nfssvc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
fs/nfsd/nfssvc.c +4 -4
@@ -72,7 +72,7 @@ static struct svc_program nfsd_acl_progr .pg_prog = NFS_ACL_PROGRAM, .pg_nvers = NFSD_ACL_NRVERS, .pg_vers = nfsd_acl_versions, - .pg_name = "nfsd", + .pg_name = "nfsacl", .pg_class = "nfsd", .pg_stats = &nfsd_acl_svcstats, .pg_authenticate = &svc_set_client,
@@ -118,16 +118,16 @@ int nfsd_vers(int vers, enum vers_op chaswitch (change) {case NFSD_SET : nfsd_versions[vers] = nfsd_version[vers]; -break ;#if defined(CONFIG_NFSD_V2_ACL ) || defined(CONFIG_NFSD_V3_ACL )if (vers <NFSD_ACL_NRVERS ) - nfsd_acl_version[vers] = nfsd_acl_version[vers]; + nfsd_acl_versions[vers] = nfsd_acl_version[vers];#endif +break ;case NFSD_CLEAR : nfsd_versions[vers] =NULL ;#if defined(CONFIG_NFSD_V2_ACL ) || defined(CONFIG_NFSD_V3_ACL )if (vers <NFSD_ACL_NRVERS ) - nfsd_acl_version[vers] =NULL ; + nfsd_acl_versions[vers] =NULL ;#endif break ;case NFSD_TEST :
Quoted 7 lines · Neil Brown
Ok, thanks. I must have missed something else wrong in the code......
Probably this 'break' in the wrong place...
Could you try this patch instead please - or just move the 'break' to where it should be.
Now it worked :)
Thanks,
Wu
Quoted 38 lines
Signed-off-by Neil Brown <[email protected]>### Diffstat output
./fs/nfsd/nfssvc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)diff
.prev/fs/nfsd/nfssvc.c./fs/nfsd/nfssvc.cfs/nfsd/nfssvc.c +4
-4@@ -72,7 +72,7 @@ static struct svc_program nfsd_acl_progr .pg_prog = NFS_ACL_PROGRAM, .pg_nvers = NFSD_ACL_NRVERS, .pg_vers = nfsd_acl_versions, - .pg_name = "nfsd", + .pg_name = "nfsacl", .pg_class = "nfsd", .pg_stats = &nfsd_acl_svcstats, .pg_authenticate = &svc_set_client,@@ -118,16 +118,16 @@ int nfsd_vers(int vers, enum vers_op chaswitch (change) {case NFSD_SET : nfsd_versions[vers] = nfsd_version[vers]; -break ;#if defined(CONFIG_NFSD_V2_ACL ) || defined(CONFIG_NFSD_V3_ACL )if (vers <NFSD_ACL_NRVERS ) - nfsd_acl_version[vers] = nfsd_acl_version[vers]; + nfsd_acl_versions[vers] = nfsd_acl_version[vers];#endif +break ;case NFSD_CLEAR : nfsd_versions[vers] =NULL ;#if defined(CONFIG_NFSD_V2_ACL ) || defined(CONFIG_NFSD_V3_ACL )if (vers <NFSD_ACL_NRVERS ) - nfsd_acl_version[vers] =NULL ; + nfsd_acl_versions[vers] =NULL ;#endif break ;case NFSD_TEST :
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 10 lines · On Saturday January 13, [email protected] wrote:
Quoted 7 lines · Neil Brown
Ok, thanks. I must have missed something else wrong in the code......
Probably this 'break' in the wrong place...
Could you try this patch instead please - or just move the 'break' to where it should be.
Now it worked :)
Thanks. I'll try to get those fixes into 2.6.20...
NeilBrown