From f785df8f6823a5a8be8ef212e3973eaf517dbb2c Mon Sep 17 00:00:00 2001 From: Steve Dickson Date: Thu, 18 Aug 2022 09:38:18 -0400 Subject: [PATCH] rpc-statd.service: Stop rpcbind and rpc.stat in an exit race (bz 2112941) Signed-off-by: Steve Dickson Resolves: bz2112941 --- nfs-utils-2.5.4-systemd-rpcstatd.patch | 31 ++++++++++++++++++++++++++ nfs-utils.spec | 4 +++- 2 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 nfs-utils-2.5.4-systemd-rpcstatd.patch diff --git a/nfs-utils-2.5.4-systemd-rpcstatd.patch b/nfs-utils-2.5.4-systemd-rpcstatd.patch new file mode 100644 index 0000000..5b2b3aa --- /dev/null +++ b/nfs-utils-2.5.4-systemd-rpcstatd.patch @@ -0,0 +1,31 @@ +commit 8a835cebb149ba2a54b6518722c79019cf8e3da4 +Author: Benjamin Coddington +Date: Mon Aug 1 13:19:04 2022 -0400 + + rpc-statd.service: Stop rpcbind and rpc.stat in an exit race + + When `systemctl stop rpcbind.socket` is run, the dependency means + that systemd first sends SIGTERM to rpcbind, then sigterm to rpc.statd. + + On SIGTERM, rpcbind tears down /var/run/rpcbind.sock. However, + rpc-statd on SIGTERM attempts to unregister from rpcbind + + systemd needs to wait for rpc.statd to exit before sending + SIGTERM to rpcbind + + Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2100395 + Signed-off-by: Steve Dickson + +diff --git a/systemd/rpc-statd.service b/systemd/rpc-statd.service +index 095629f2..392750da 100644 +--- a/systemd/rpc-statd.service ++++ b/systemd/rpc-statd.service +@@ -5,7 +5,7 @@ Conflicts=umount.target + Requires=nss-lookup.target rpcbind.socket + Wants=network-online.target + Wants=rpc-statd-notify.service +-After=network-online.target nss-lookup.target rpcbind.socket ++After=network-online.target nss-lookup.target rpcbind.service + + PartOf=nfs-utils.service + IgnoreOnIsolate=yes diff --git a/nfs-utils.spec b/nfs-utils.spec index 52ac063..d01d891 100644 --- a/nfs-utils.spec +++ b/nfs-utils.spec @@ -32,6 +32,7 @@ Patch008: nfs-utils-2.5.4-rpcpipefs-warn.patch Patch009: nfs-utils-2.5.4-rpcidmapd-return.patch Patch010: nfs-utils-2.5.4-mount-ebusy.patch Patch011: nfs-utils-2.5.4-rpcctl-xprt.patch +Patch012: nfs-utils-2.5.4-systemd-rpcstatd.patch Patch100: nfs-utils-1.2.1-statdpath-man.patch Patch101: nfs-utils-1.2.1-exp-subtree-warn-off.patch @@ -465,8 +466,9 @@ fi %{_mandir}/*/nfsiostat.8.gz %changelog -* Wed Aug 17 2022 Steve Dickson 2.5.4-15 +* Thu Aug 18 2022 Steve Dickson 2.5.4-15 - Fix uninstall warnings (bz 2048023) +- rpc-statd.service: Stop rpcbind and rpc.stat in an exit race (bz 2112941) * Mon Aug 1 2022 Steve Dickson 2.5.4-14 - Fix the typo of dependency tag "Provides: rpcclt" (bz 2104406)