| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
| |
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
| |
Some of the latest compiler warnings flags are not available
on older compilers so this adds macros to test they are supported
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
| |
A mistake when cleaning up the ABI caused certain values to not
be available to libnfsidmap plugins, requiring code reorganisation
to not expose further unneccesary symbols. Adds one symbol reporting
the configuration file path used.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
| |
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
mount -t nfs or mount -t nfs4 and setting minorversion
should set the v4 minor version. This patch adds a few
checks to make sure the minor version is set.
The patch also translate the minorversion= option
to vers=4.x in the arguments passed to the kernel
when the kernel is later then v3.4.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
| |
Add some more -Werror warning flags that
didn't cause warnings but could catch
some in the future.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
| |
Added the -Werror=missing-include-dirs warning flag
then moved some include directories around.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
| |
Added the -Werror=undef warning flag and
then fixed a few #ifdefs
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
| |
Added the -Werror=format=2 warning flag
and added couple pragma statments to ignore
the warning where it could not be avoided.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
| |
Added the -Werror=format-overflow=2 warning flag
and then cleaned up the mess
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
| |
Added the -Werror=missing-prototypes warning flag
then cleaned up the mess.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
| |
Remove ARCHFLAGS since it has not been needed for years.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
| |
Clean up.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
nfs-utils is not going to provide an implementation of the FedFS
ADMIN protocol, so there's no need to include the entire .x file
for that protocol.
The only piece needed (for the moment) is the enum that defines
the FEDFS_ERR codes, which are used by the internal and external
libjunction APIs.
Suggested-by: Neil Brown <neilb@suse.com>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
| |
This is a display helper function that is not needed in nfs-utils
because nfs-utils does not implement the FedFS ADMIN protocol (and
therefore does not need to display ADMIN protocol-related security
settings).
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The xdr c-files, generated from .x by rpcgen, in both
libnsm.a and libexport.a libraries cause the
following warnings:
mount_xdr.c:43:20: warning: unused variable 'buf' [-Wunused-variable]
sm_inter_xdr.c:37:20: warning: unused variable 'buf' [-Wunused-variable]
sm_inter_xdr.c:51:6: warning: unused variable 'i' [-Wunused-variable]
These warnings are caused by rpcgen trying in inline
the xdr routines. It turns out no inlining was happening,
except for one routine. So turning off inlining eliminated
these warnings.
This patch also eliminates a Werror missing-prototypes in sm_inter.h
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
| |
This file is not part of "git clone" and is not #included from any C file.
Reviewed-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
| |
The 'nfsref' command administers junctions. On an NFS server, it
can create new junctions, remove existing junctions, or display
the contents of junctions.
A man page with more details is included.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch does two things:
1. Reverts ab74900ff59e ("mountd: Support junction management
plug-ins")
2. Re-implements support for NFS basic junctions directly in mountd
So no more support for FedFS junctions, and no more need to have a
dynamically load component installed from another package.
The downside is that mountd has to be linked with libxml2 to get
this support. Thus to make the use of libxml2 optional, built-in
support for junctions is enabled only when --enable-junction is
specified on the command line.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A "junction" is a physical filesystem object that contains an NFS
referral. On Linux, a junction is a directory with special mode bits
that has an extended attribute containing referral location
information, represented as XML.
A junction can contain either a list of target locations, or it
can contain the location of an LDAP directory entry where the actual
referral information is maintained. The former is called an "NFS
basic junction", the latter is a "FedFS junction".
libjunction contains support for reading or updating a junction
that resides on an NFS server.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The source code for libjunction used to be maintained in
fedfs-utils, but fedfs-utils is being retired. Although interest in
FedFS junctions has waned, NFS basic junctions are still appealing
enough that we've decided we want to continue supporting them.
Therefore this patch moves the non-LDAP parts of libjunction into
nfs-utils, to enable nfs-utils to also support the user-visible
pieces of NFS basic junctions.
I've added yet another configure command line option to control
whether libjunction is built. It defaults to "disabled" for the
moment. Reasons you might want to leave it disabled:
- Your distribution still provides fedfs-utils, which already has
a working libjunction which is installed separately
- Your distribution does not provide libxml2, which is required
to support libjunction
When it's disabled, nfs-utils builds just like it did before this
patch, and there's no new dependency on libxml2.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
libjunction contains support for reading or updating a junction
that resides on an NFS server. It is used by mountd to read junction
information from an exported filesystem, and by the nfsref command
line tool. These will be introduced in subsequent patches.
The source code for libjunction used to be maintained in
fedfs-utils, but fedfs-utils is being retired. Although interest in
FedFS junctions has waned, NFS basic junctions are still appealing
enough that we've decided we want to continue supporting them.
Therefore this patch moves the non-LDAP parts of libjunction into
nfs-utils, to enable nfs-utils to also support the user-visible
pieces of NFS basic junctions.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
according https://bugzilla.redhat.com/show_bug.cgi?id=1532688#c3
ro/rw options should be in secinfo_flag_displaymap[]
test pass:
'''
[yjh@test ~]$ cat /etc/exports
/export_test 127.0.0.1(rw,wdelay,no_root_squash,no_subtree_check,sec=sys,root_squash,all_squash,sec=krb5,ro,root_squash,no_all_squash,sec=krb5i,rw,root_squash,no_all_squash,sec=krb5p,no_root_squash,no_all_squash)
[yjh@test ~]$ sudo service nfs restart
Redirecting to /bin/systemctl restart nfs.service
[yjh@test ~]$ sudo exportfs -v
/export_test 127.0.0.1(sync,wdelay,hide,no_subtree_check,sec=sys,rw,secure,root_squash,all_squash,sec=krb5,ro,secure,root_squash,no_all_squash,sec=krb5i,rw,secure,root_squash,no_all_squash,sec=krb5p,rw,secure,no_root_squash,no_all_squash)
'''
Signed-off-by: Jianhong Yin <yin-jianhong@163.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
| |
In the latest glib-headers libio.h has been deprecated
This patch removes this warning:
/usr/include/libio.h:21:2: warning: #warning "<libio.h> is deprecated; use <stdio.h> instead." [-Wcpp]
#warning "<libio.h> is deprecated; use <stdio.h> instead."
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
| |
Since a15bd948 the --enable-svcgss option no longer builds
as svcgssd references functions which were changed at that time.
Fix those, and other function changes since then.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
| |
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Prior to its merger with nfs-utils the libnfsidmap library leaked
a lot of internal functions and variables that were not defined
in its API, some of which were used by its various plugins.
This created an accidentally large ABI which restricts attempts to
clean up the code base.
These patches aim to trim the ABI down, whilst adding to the API
only the minimal required to still support both bundled and 3rd
party plugins.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
| |
The kernel is counting RDMA segments, not chunks. Correct the units
labels displayed by "mountstats -x", and fix up the internal names
of the counters.
Fixes: 6742ba53ae79 ("mountstats: Add option to pretty-print ...")
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
| |
Add "-x" option to display the statistics reported on the "xprt:"
line in mountstats. This is not terribly interesting for UDP and
TCP, but it can be for RDMA transports.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When "-o remount" is used, the device/special name
is ignored. So don't parse it and risk generating a
useless error.
This is particularly important when nfs-root is used
as the "device name" is listed as "/dev/nfs".
Because mount.nfs doesn't think that is valid,
mount -o remount,rw /
will fail.
Link: https://github.com/systemd/systemd/issues/3590
Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
| |
Prior to merge libnfsidmap leaked many private symbols that were
not defined in its API, creating an accidental ABI.
This patch renames and unhides symbols in order to match that ABI
until a cleaned up API can be established and released.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
| |
libnfsidmap.pc is generated during the compiling of libnfsidmap
which needed to be ignored.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
| |
With commit a867b45 (Release: 2.2.1) the libnfsidmap-devel
package is now build from with the nfs-utils source tree.
So the programs dependent on libnfsidmap-devel need to
look inward verses outward for the nfsidmap.h header file.
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
| |
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
| |
Display the NFS queue statistics for mountstats and nfsiostat
exported in /proc/self/mountstats. The RTT and total execution
time is currently displayed but it's also useful displaying
how long the task was queued for too
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
| |
Clean up a bunch of warnings about unused parameters,
signedness differences, etc that we inherited from
the merged libnfsidmap code.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
| |
Modify libnfsidmap to use the now shared conffile code,
adjust the build structure to generate everything correctly,
and modify the other utils to use the merged version of libnfsidmap
instead of testing for an external dependancy.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
| |
Merge the libnfsidmap code tree into nfs-utils.
These are the original unmodified files, cherry picked only the
necessary files that dont duplicate code, so will not build
correctly at this stage.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
| |
To allow better reuse of the code we split conffile and xlog
into their own separate convenience library, then merge it
back so as to not create extra dependancies for everything
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
| |
The similar config code in libnfsidmap had one additional feature of
a get_str function with a default value option, include an equivalent
function here to maintain compatibility.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
| |
conf_get_section() started as conf_get_str() with one extra search
parameter, subsequent patches have not maintained feature parity,
combine the code to make a single more generic function and just call
that differently where required.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
| |
Tighten up the conffile interface by switching to const
arguments where appropriate.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
| |
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=625531
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
| |
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
| |
From: "J. Bruce Fields" <bfields@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
From: "J. Bruce Fields" <bfields@redhat.com>
We've seen some confusion from people not understanding why newer
clients may not support NFSv2. It might help a little to note in the
man page that version support depends on how the kernel was built.
While we're there:
- update some references to NFS protocol versions.
- update 4.0 RFC, and add references to 4.1 and 4.2 RFCs.
- rename "BUGS" to "NOTES"; the section mostly isn't about bugs.
(Might be time to remove some of the linux-2.4 notes too.)
- remove some outdated references to optional NFSv4+ features.
(Or should we try to keep this information up to date?)
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Both auth-rpcgss-module and rpc-statd-notify only
ever need to be run once - the effect they have
is permanent.
We can give this information to systemd by setting
RemainAfterExit=yes
This avoids the minor cost of running them a second time
if something "Wants" either service after it was first run,
(e.g. both client and server startup can Want these),
and avoids systemd complaining that it restarts to fast
if multiple Wants happen at nearly the same time.
Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
|
|
| |
When using mount.nfs if an nfsvers= option is set in a config file,
and a vers= option is given on the commandline, then they are not
always correctly combined and this can result in both being present
in the resulting mount call.
Signed-off-by: Justin Mitchell <jumitche@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
|
| |
|
|
|
|
|
|
| |
Commit 2f8a6020 introduce a regression causing rpc.nfsd
to fail when IPv6 is not supported. rpc.nfsd should not
fail when there is at least one bounded socket.
Signed-off-by: Steve Dickson <steved@redhat.com>
|