Bug 1300858

Summary: nfs-ganesha won't start on ubuntu trusty
Product: [Retired] nfs-ganesha Reporter: Ben Werthmann <ben>
Component: SupportAssignee: Frank Filz <ffilz>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: medium Docs Contact:
Priority: unspecified    
Version: 2.3CC: jack.wong, kkeithle, rainer.weinhold
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-06-24 11:17:56 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Ben Werthmann 2016-01-21 23:15:50 UTC
Description of problem:
The init script provided in the PPA for nfs-ganesha for Ubuntu Trusty will not start the daemon.  

Version-Release number of selected component (if applicable):


How reproducible:
Always

Actual results:
$ service nfs-ganesha start
/etc/init.d/nfs-ganesha: line 22: /etc/rc.d/init.d/functions: No such file or directory
Starting ganesha.nfsd: /etc/init.d/nfs-ganesha: line 46: failure: command not found

Expected results:
Daemon should start

Additional info:
Attempted this patch, but run into issues because /etc/rc.d/init.d/functions and /lib/lsb/init-functions are not compatible.

diff --git a/src/scripts/init.d/nfs-ganesha b/src/scripts/init.d/nfs-ganesha
index b13416e..7a5bfa8 100644
--- a/src/scripts/init.d/nfs-ganesha
+++ b/src/scripts/init.d/nfs-ganesha
@@ -19,7 +19,7 @@


 # source function library
-. /etc/rc.d/init.d/functions
+. /lib/lsb/init-functions

 PATHPROG=/usr/bin/ganesha.nfsd

@@ -46,7 +46,7 @@ start() {
                 failure
         else
                ulimit -n $NOFILE
-                daemon --pidfile $PID_FILE $PATHPROG $OPTIONS
+                daemon --pidfile $PID_FILE $PATHPROG -- $OPTIONS
                 RETVAL=$?
                 if [ $RETVAL -eq 0 ]; then
                            touch $LOCK_FILE

I suspect the best way forward is to have a Debian/Ubunutu specific, LSB compliant init script going forward. I'm open to other ideas as well.

Comment 1 RainerW 2016-05-02 15:01:33 UTC
a) I also cannot start ganesha on any Debian based OS, including the old LTS version, Ubuntu 14 LTS.

b) the above diff does not fix "status" & "stop" etc.

c) The same bug is also in debian repo ( http://download.gluster.org/pub/gluster/glusterfs/LATEST/Debian/jessie/ )

Comment 2 Ben Werthmann 2017-03-15 15:31:19 UTC
Our workaround is to use runit to manage nfs-ganesha.

Comment 3 Kaleb KEITHLEY 2020-06-24 11:17:56 UTC
If this is still an issue please open an issue in the github tracker at https://github.com/nfs-ganesha/nfs-ganesha/issues