Subject: Add nfs-common and nfs-kernel-server launch options removed in debian 13

From: dan <[email-masked]>
Date: Mon, 1 Dec 2025 14:44:01 -0500

Package: nfs-common
Version: 2.8.3-1

Package2: nfs-kernel-server
Version2: 2.8.3-1

Severity: grave

Tags: patch

as peer 
https://salsa.debian.org/kernel-team/nfs-utils/-/blob/debian/latest/debian/nfs-common.NEWS?ref_type=heads

Options related to launching nfs kernel server and support services from

/etc/default/nfs-common
/etc/default/nfs-kernel-server

in liue of /etc/nfs.conf
(by systemd service launching taking over)

now are being ignored by respective init scripts of

/etc/init.d/nfs-common
/etc/init.d/nfs-kernel-server

Propose to bring back the options from previous versions of init files
Until there is support for new /etc/nfs.conf

PS: patches were quick and dirty made on top of unpacked debs not source 
debs, by comparing what was working/needed in devuan5 and missing in 
devuan6.

--- /src/nfs-common_2.8.3-1_amd64/etc/init.d/nfs-common.orig
+++ /src/nfs-common_2.8.3-1_amd64/etc/init.d/nfs-common.new
@@ -20,6 +20,7 @@
  NEED_STATD=
  NEED_GSSD=
  PIPEFS_MOUNTPOINT=/run/rpc_pipefs
+RPCGSSDOPTS=
  if [ -f $DEFAULTFILE ]; then
      . $DEFAULTFILE
  fi
@@ -133,7 +134,7 @@
  	    fi
  	    start-stop-daemon --start --oknodo --quiet \
  		--pidfile /run/rpc.statd.pid \
-	        --exec /usr/sbin/rpc.statd
+	        --exec /sbin/rpc.statd -- $STATDOPTS
  	    RET=$?
  	    if [ $RET != 0 ]; then
  	        log_end_msg $RET
@@ -183,7 +184,7 @@
  		    fi

  		    start-stop-daemon --start --oknodo --quiet \
-			    --exec /usr/sbin/rpc.gssd
+			    --exec /usr/sbin/rpc.gssd -- $RPCGSSDOPTS
  		    RET=$?
  	            if [ $RET != 0 ]; then
          	        log_end_msg $RET

--- /src/nfs-kernel-server_2.8.3-1_amd64/etc/init.d/nfs-kernel-server.orig
+++ /src/nfs-kernel-server_2.8.3-1_amd64/etc/init.d/nfs-kernel-server.new
@@ -25,8 +25,11 @@

  # Read config
  DEFAULTFILE=/etc/default/nfs-kernel-server
+RPCNFSDCOUNT=8
  RPCNFSDPRIORITY=0
+RPCMOUNTDOPTS=
  NEED_SVCGSSD=no
+RPCSVCGSSDOPTS=
  PROCNFSD_MOUNTPOINT=/proc/fs/nfsd
  if [ -f $DEFAULTFILE ]; then
      . $DEFAULTFILE
@@ -98,7 +101,7 @@

  		start-stop-daemon --start --oknodo --quiet \
  		    --nicelevel $RPCNFSDPRIORITY \
-		    --exec $PREFIX/sbin/rpc.nfsd
+		    --exec $PREFIX/sbin/rpc.nfsd -- $RPCNFSDCOUNT
  		RET=$?
  		if [ $RET != 0 ]; then
  			log_end_msg $RET
@@ -121,7 +124,7 @@
  			do_modprobe rpcsec_gss_krb5
  			log_progress_msg "svcgssd"
  			start-stop-daemon --start --oknodo --quiet \
-			    --exec $PREFIX/sbin/rpc.svcgssd
+			    --exec $PREFIX/sbin/rpc.svcgssd -- $RPCSVCGSSDOPTS
  			RET=$?
  			if [ $RET != 0 ]; then
  				log_end_msg $RET
@@ -131,7 +134,7 @@

  		log_progress_msg "mountd"
  		start-stop-daemon --start --oknodo --quiet \
-		    --exec $PREFIX/sbin/rpc.mountd
+		    --exec $PREFIX/sbin/rpc.mountd -- $RPCMOUNTDOPTS
  		RET=$?
  		if [ $RET != 0 ]; then
  			log_end_msg $RET

thanx

dan