commit 51309c99d6c70e3c63a885a65bd122ac74ec9395 Author: Ian Kent Date: Sat Oct 19 08:16:17 2024 -0400 nfs-utils: use getpwuid_r() and getpwnam_r() in gssd gssd uses getpwuid(3) and getpwnam(3) in a pthreads context but these functions are not thread safe. Signed-off-by: Ian Kent Signed-off-by: Steve Dickson commit 092971c4741814d831e8172eb3332e53aeaef890 Author: Seiichi Ikarashi Date: Fri Oct 18 08:29:57 2024 -0400 nfsdcld: prevent from accessing /var/lib/nfs/nfsdcld in read-only file system during boot I saw a VMWare guest that hit a rare condition during boot; nfsdcld started too early to check access on /var/lib/nfs/nfsdcld which were still in read-only file system as follows: nfsdcld[...]: Unexpected error when checking access on /var/lib/nfs/nfsdcld: Read-only file system systemd[1]: nfsdcld.service: Main process exited, code=exited, status=226/NAMESPACE systemd[1]: nfsdcld.service: Failed with result 'exit-code'. nfsdcld.service needs to wait the root file system to be remounted at least. Reviewed-by: Jeff Layton Signed-off-by: Seiichi Ikarashi Signed-off-by: Steve Dickson commit 21ded9ee5191002d58caaaf1ff1d7c8236bde1b5 Author: Jeff Layton Date: Wed Oct 16 16:42:21 2024 -0400 systemd: use nfsdctl to start and stop the nfs server Attempt to use nfsdctl to start and stop the nfs-server. If that fails for any reason, use rpc.nfsd to do it instead. Signed-off-by: Jeff Layton Signed-off-by: Steve Dickson commit e32ac9ef2bb4c6a7911acdbd8967140e85054d47 Author: Jeff Layton Date: Wed Oct 16 16:40:08 2024 -0400 nfsdctl: asciidoc source for the manpage Convert to manpage with: asciidoctor -b manpage nfsdctl.adoc Signed-off-by: Jeff Layton Signed-off-by: Steve Dickson commit 8c32613d5311930c17c056d93996bcd8e00e0fa4 Author: Jeff Layton Date: Wed Oct 16 16:36:29 2024 -0400 nfsdctl: add the nfsdctl utility to nfs-utils This tool is based on Lorenzo's original nfsdctl tool [1]. His original tool used getopt_long to indicate the command, but that's somewhat limiting. This converts it to a subcommand-based interface, where each subcommand can take its own options, in the spirit of commands like nmcli or virsh. There are currently 6 different subcommands: pool-mode get/set current pool mode setting listener get/set listener info version get/set supported NFS versions threads get/set nfsd thread settings status get current RPC processing info autostart start server with settings from /etc/nfs.conf Each can take different options, and we can expand this interface later with more commands as necessary. This is based on Lorenzo's original userland tool: https://github.com/LorenzoBianconi/nfsdctl Signed-off-by: Lorenzo Bianconi Signed-off-by: Jeff Layton Signed-off-by: Steve Dickson commit fdc5081a8f48dd161ea94fff11bf0afd8d901747 Author: Salvatore Bonaccorso Date: Fri Sep 20 12:30:07 2024 -0400 rpc.idmapd: nfsopen() failures should not be fatal dirscancb() loops over all clnt* subdirectories of /run/rpc_pipefs/nfs/. Some of these directories contain /idmap files, others don't. nfsopen() returns -1 for the latter; we then want to skip the directory, not abort the entire scan. Reported-by: Sergio Gelato Closes: https://lore.kernel.org/linux-nfs/ZmCB_zqdu2cynJ1M@astro.su.se/ Link: https://bugs.debian.org/1072573 Patch-originally-by: Sergio Gelato Signed-off-by: Salvatore Bonaccorso Signed-off-by: Steve Dickson commit e8edde908903943d40345914e971a26182699368 Author: Dan Aloni Date: Fri Sep 20 08:00:33 2024 -0400 mount.nfs: improve EPROTO error message for RDMA mounts When mounting NFS shares using RDMA, users may encounter this rather unclear error message: mount.nfs: Protocol error Often there are either no RDMA interfaces existing, or that routing is being done via other interfaces. This patch enhances the `mount_error` function to provide a more informative message in such cases. Signed-off-by: Dan Aloni Signed-off-by: Steve Dickson commit 4ddf3188f610a4ccfa8539cd94f5505a1a22db6c Author: Robert Yang Date: Fri Sep 20 07:44:53 2024 -0400 support/junction/path.c: Fix buld for musl Fixed: path.c:164:24: error: implicit declaration of function 'strchrnul'; did you mean 'strchr'? [-Wimplicit-function-declaration] [snip] path.c:239:27: error: 'NAME_MAX' undeclared (first use in this function); did you mean 'AF_MAX'? Signed-off-by: Robert Yang Signed-off-by: Steve Dickson commit 34a7959ddfb50db806c3f0e848947ff1117f37e2 Author: Robert Yang Date: Fri Sep 20 07:43:00 2024 -0400 support/include/junction.h: Define macros for musl Fixed 1: In file included from cache.c:1217: ../../support/include/junction.h:128:21: error: expected ';' before 'char' 128 | __attribute_malloc__ | ^ | ; 129 | char **nfs_dup_string_array(char **array); Fixed 2: junction.c: In function 'junction_set_sticky_bit': junction.c:164:39: error: 'ALLPERMS' undeclared (first use in this function) 164 | stb.st_mode &= (unsigned int)~ALLPERMS; Signed-off-by: Robert Yang Signed-off-by: Steve Dickson commit 71fc2c219ac7c9483feca7f38899f6e7a9ca71c4 Author: Scott Mayhew Date: Fri Sep 20 07:38:03 2024 -0400 nfsdcld: don't send null client ids to the kernel It's apparently possible for the sqlite database to get corrupted and cause one or more rows to have null in the id column. The knfsd fix was posted here: https://lore.kernel.org/linux-nfs/20240903111446.659884-1-lilingfeng3@huawei.com/ nfsdcld should have a similar fix. If we encounter a client record with a null id, just skip it instead of sending it to the kernel. Signed-off-by: Scott Mayhew Signed-off-by: Steve Dickson