[PATCH nfs-utils v5 0/4] nfsdctl: new nfs-utils tool for managing the kernel NFS server

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Steve,

The new netlink management interfaces [1] have been merged for v6.10
[2]. Please consider merging this series into nfs-utils. I think the
code is fine but it may need some autoconf/automake love. See below...

This series adds a new tool to nfs-utils called nfsdctl, which is
intended as an eventual replacement for rpc.nfsd (and maybe other
tools). It's a subcommand based interface like nmcli or virsh, so we can
easily expand the interface later to deal with new sorts of
configuration.

This version of the tool should be at feature parity with rpc.nfsd, at
least as far as autostarting the server. This posting also includes a
manpage and an update to the nfs-server systemctl service, to start
using the new interface when possible.

I've also included a patch that adds the manpage source. It's much nicer
to edit that and regenerate it if we have to update it later. We can
drop that patch if you just want to keep the result though.

This does ship a copy of nfsd_netlink.h along with the tool that gets
used if the uapi headers aren't new enough. This is a temporary measure.
Once new enough kernels are shipping in the field (in a year or so?), we
can drop that and some related autoconf junk.

[1]: https://lore.kernel.org/linux-nfs/cover.1713878413.git.lorenzo@xxxxxxxxxx/T/#m5fd847189894f58e93706c40340e18858f242a27
[2]: https://lore.kernel.org/linux-nfs/171606732267.14195.18399250065227381901.pr-tracker-bot@xxxxxxxxxx/T/#t

Signed-off-by: Jeff Layton <jlayton@xxxxxxxxxx>
---
Changes in v5:
- add support for pool-mode setting
- fix up the handling of nfsd_netlink.h in autoconf
- Link to v4: https://lore.kernel.org/r/20240604-nfsdctl-v4-0-a2941f782e4c@xxxxxxxxxx

Changes in v4:
- add ability to specify an array of pool thread counts in nfs.conf
- Link to v3: https://lore.kernel.org/r/20240423-nfsdctl-v3-0-9e68181c846d@xxxxxxxxxx

Changes in v3:
- split nfsdctl.h so we can include the UAPI header as-is
- squash the patches together that added Lorenzo's version and convert
  it to the new interface
- adapt to latest version of netlink interface changes
  + have THREADS_SET/GET report an array of thread counts (one per pool)
  + pass scope in as a string to THREADS_SET instead of using unshare() trick

Changes in v2:
- Adapt to latest kernel netlink interface changes (in particular, send
  the leastime and gracetime when they are set in the config).
- More help text for different subcommands
- New nfsdctl(8) manpage
- Patch to make systemd preferentially use nfsdctl instead of rpc.nfsd
- Link to v1: https://lore.kernel.org/r/20240412-nfsdctl-v1-0-efd6dcebcc04@xxxxxxxxxx

---
Jeff Layton (3):
      nfsdctl: asciidoc source for the manpage
      systemd: use nfsdctl to start and stop the nfs server
      nfsdctl: add support for pool-mode

Lorenzo Bianconi (1):
      nfsdctl: add the nfsdctl utility to nfs-utils

 configure.ac                 |   19 +
 systemd/nfs-server.service   |    4 +-
 utils/Makefile.am            |    4 +
 utils/nfsdctl/Makefile.am    |   13 +
 utils/nfsdctl/nfsd_netlink.h |   96 +++
 utils/nfsdctl/nfsdctl.8      |  293 ++++++++
 utils/nfsdctl/nfsdctl.adoc   |  152 ++++
 utils/nfsdctl/nfsdctl.c      | 1584 ++++++++++++++++++++++++++++++++++++++++++
 utils/nfsdctl/nfsdctl.h      |   93 +++
 9 files changed, 2256 insertions(+), 2 deletions(-)
---
base-commit: 94b48ccc0b0304809027fcead03343f4c716c4f4
change-id: 20240412-nfsdctl-fa8bd8430cfd

Best regards,
-- 
Jeff Layton <jlayton@xxxxxxxxxx>





[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux