Luk Claes [Sun, 20 Mar 2011 19:18:01 +0000 (20:18 +0100)]
- mountd: fix --manage-gids hang due to int/uint bug (0f05c8a)
(Closes: #528939,585085)
- mount.nfs: Don't do anything fancy if this is a remount (f11547f)
(Closes: #612933)
- mount: Mount should retry unreachable hosts (5a355f4)
(Closes: #560388)
- Try to use kernel function to determine supported Kerberos
enctypes (258f10f) (Closes: #474037)
Luk Claes [Sun, 13 Mar 2011 17:52:57 +0000 (18:52 +0100)]
nfs-common.init, nfs-kernel-server.init: Add warning when portmap is not running (Closes: #612002)
When portmap (or rpcbind) are not running, don't try to start statd, nfsd or mountd, but warn instead that portmap is not running. This means installing nfs-common or nfs-kernel-server would succeed even if the daemons are not started.
In case a local name server is needed to resolve hostnames in
/etc/exports, require $named to start before nfs-kernel-server if
installed (Should-Start not Required-Start).
Chuck Lever [Tue, 24 Aug 2010 11:19:34 +0000 (07:19 -0400)]
exportfs: Use xlog() for error reporting
exportfs already invokes xlog_open() because libexport.a uses xlog()
exclusively for error reporting and debugging messages. If we can
use xlog() throughout exportfs itself, that enables xlog debugging
messages everywhere in the code path.
In addition, use xlog() instead of fprintf(stderr) for reporting
errors in exportfs.c, to be consistent with libexport.a and other
components of nfs-utils.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Steve Dickson <steved@redhat.com>
Chuck Lever [Tue, 24 Aug 2010 11:16:10 +0000 (07:16 -0400)]
statd: statd fails to monitor if no reverse mapping of mon_name exists
Commit 8ce130c4 switched in the new statd_canonical_name() function
that constructs a "unique" name statd can use to uniquely identify a
monitor record.
The legacy statd would monitor a client that sent an IP address with
no reverse map as its caller_name. To remain bug-for-bug compatible,
allow this case in the new statd.
This shouldn't be a problem: statd_canonical_name() needs to create
a unique name for the monitored host so it can keep track of monitor
requests from the same remote. The IP address itself should work as
well as the host's canonical name, in case there is no reverse
mapping.
We still enforce the requirement that a mon_name that is a DNS name
must have a forward map to an IP address.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Steve Dickson <steved@redhat.com>
Chuck Lever [Tue, 24 Aug 2010 11:13:54 +0000 (07:13 -0400)]
libexport: Fix IP address check in check_netgroup()
Neil Brown reports that recent changes to replace
gethostby{addr,name}(3) with get{addr,info}name(3) may have
inadvertently broken netgroup support.
There used to be a gethostbyaddr(3) call in the third paragraph in
check_netgroup(). The reason for that gethostbyaddr(3) call was that
the first innetgr(3) call has already confirmed that hname is not a
member of the netgroup. We also need to confirm that, if hname
happens to be an IP address, the hostname bound to that IP address is
not a member of the netgroup, either.
Fix this by restoring appropriate address to hostname mapping of hname
before retrying the innetgr(3) call.
Steve Dickson [Wed, 4 Aug 2010 14:41:18 +0000 (10:41 -0400)]
Removed warnings from idmapd.c
idmapd.c:120: warning: missing initializer
idmapd.c:120: warning: (near initialization for 'nfsd_ic[0].ic_event')
idmapd.c:121: warning: missing initializer
idmapd.c:121: warning: (near initialization for 'nfsd_ic[1].ic_event')
idmapd.c: In function 'flush_nfsd_cache':
idmapd.c:173: warning: comparison between signed and unsigned integer expressions
idmapd.c: In function 'dirscancb':
idmapd.c:384: warning: unused parameter 'fd'
idmapd.c:384: warning: unused parameter 'which'
idmapd.c: In function 'svrreopen':
idmapd.c:468: warning: unused parameter 'fd'
idmapd.c:468: warning: unused parameter 'which'
idmapd.c:468: warning: unused parameter 'data'
idmapd.c: In function 'clntscancb':
idmapd.c:474: warning: unused parameter 'fd'
idmapd.c:474: warning: unused parameter 'which'
idmapd.c: In function 'nfsdcb':
idmapd.c:488: warning: unused parameter 'fd'
idmapd.c: In function 'nfscb':
idmapd.c:663: warning: unused parameter 'fd'
idmapd.c: In function 'validateascii':
idmapd.c:850: warning: comparison between signed and unsigned integer expressions
idmapd.c:858: warning: comparison between signed and unsigned integer expressions
idmapd.c: In function 'getfield':
idmapd.c:916: warning: comparison between signed and unsigned integer expressions
Steve Dickson [Wed, 4 Aug 2010 14:26:13 +0000 (10:26 -0400)]
Removed warnings from svcgssd_proc.c
svcgssd_proc.c: In function 'send_response':
svcgssd_proc.c:135: warning: unused parameter 'f'
svcgssd_proc.c: In function 'handle_nullreq':
svcgssd_proc.c:434: warning: comparison of unsigned expression < 0 is always false
Steve Dickson [Tue, 20 Jul 2010 22:13:45 +0000 (18:13 -0400)]
Removed warnings from gssd_proc.c
gssd_proc.c: In function 'create_auth_rpc_client':
gssd_proc.c:939: warning: comparison between signed and unsigned integer expressions
gssd_proc.c:939: warning: comparison between signed and unsigned integer expressions
gssd_proc.c: In function 'handle_krb5_upcall':
gssd_proc.c:1164: warning: comparison between signed and unsigned integer expressions
gssd_proc.c: In function 'handle_spkm3_upcall':
gssd_proc.c:1178: warning: comparison between signed and unsigned integer expressions
Steve Dickson [Tue, 20 Jul 2010 22:08:13 +0000 (18:08 -0400)]
Removed warnings from krb5_util.c
krb5_util.c: In function 'realm_and_service_match':
krb5_util.c:617: warning: unused parameter 'context'
krb5_util.c: In function 'limit_krb5_enctypes':
krb5_util.c:1275: warning: unused parameter 'uid'
Steve Dickson [Mon, 19 Jul 2010 18:54:51 +0000 (14:54 -0400)]
Removed warnings from nfsstat.c
nfsstat.c: In function 'print_callstats':
nfsstat.c:797: warning: comparison between signed and unsigned integer
expressions
nfsstat.c:801: warning: comparison between signed and unsigned integer
expressions
nfsstat.c:802: warning: comparison between signed and unsigned integer
expressions
nfsstat.c:805: warning: comparison between signed and unsigned integer
expressions
nfsstat.c: In function 'print_callstats_list':
nfsstat.c:821: warning: comparison between signed and unsigned integer
expressions
nfsstat.c:828: warning: comparison between signed and unsigned integer
expressions
nfsstat.c: In function 'unpause':
nfsstat.c:1111: warning: unused parameter 'sig' Signed-off-by: Steve Dickson <steved@redhat.com>
Steve Dickson [Mon, 19 Jul 2010 18:48:37 +0000 (14:48 -0400)]
Removed warnings from nfssvc.c
nfssvc.c:184: warning: comparison between signed and unsigned integer expressions
nfssvc.c: In function 'nfssvc_setvers':
nfssvc.c:254: warning: comparison between signed and unsigned integer expressions
nfssvc.c: In function 'nfssvc_threads':
nfssvc.c:280: warning: comparison between signed and unsigned integer expressions
Steve Dickson [Mon, 19 Jul 2010 16:17:24 +0000 (12:17 -0400)]
Removed warnings from rpcdispatch.c
rpcdispatch.c: In function 'rpc_dispatch':
rpcdispatch.c:30: warning: comparison between signed and unsigned
integer expressions
rpcdispatch.c:35: warning: comparison between signed and unsigned
integer expressions
Doug Nazar [Mon, 19 Jul 2010 15:08:46 +0000 (11:08 -0400)]
gssd: picking wrong creds
When not using machine credentials for root, if the machine
credential cache file is newer than the root credential file
the wrong file will get picked. Ignore the machine file in
this case.
Chuck Lever [Mon, 19 Jul 2010 14:09:12 +0000 (10:09 -0400)]
nfs-utils: Fix C aliasing rules violation in nfs_getrpccaller()
Squelch compiler warnings reported with -Wextra:
In file included from statd.c:24:
../../support/include/rpcmisc.h: In function nfs_getrpccaller_in:
../../support/include/rpcmisc.h:58: warning: dereferencing type-punned
pointer might break strict-aliasing rules
../../support/include/rpcmisc.h: In function nfs_getrpccaller:
../../support/include/rpcmisc.h:63: warning: dereferencing type-punned
pointer might break strict-aliasing rules
Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Steve Dickson <steved@redhat.com>