Article 6KZ8V Slackware-current, A manual rc.nfsd start execution , then , rc.nfsd stop , rpc processes still running & patch .

Slackware-current, A manual rc.nfsd start execution , then , rc.nfsd stop , rpc processes still running & patch .

by
babydr
from LinuxQuestions.org on (#6KZ8V)
Hello Pat , When manually running rc.nfsd start , just for a momentary copying of files , then , rc.nfsd stop , I noticed rpc processes still running .
Here is a small patch , not well tested but here goes .

Code:# diff -u rc.nfsd.orig rc.nfsd
--- rc.nfsd.orig 2023-08-06 11:20:50.000000000 -0800
+++ rc.nfsd 2024-04-09 18:14:00.647157981 -0800
@@ -85,6 +85,12 @@
killall nfsd 2> /dev/null
sleep 1
killall -9 nfsd 2> /dev/null # make sure :)
+ # If basic RPC services are running, stop them:
+ if ps axc | grep -q rpc.statd ; then
+ if [ -r /etc/rc.d/rc.rpc ]; then
+ sh /etc/rc.d/rc.rpc stop
+ fi
+ fi
killall rpc.rquotad 2> /dev/null
/usr/sbin/exportfs -au 2> /dev/null
}And attached is what testing I have done ...
ps: I don't use ipv6 so it is disabled at boot .
Attached Files
txt.gifslackware-current-update-20240409.txt (3.8 KB)
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments