You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After installing FirebirdCS-2.5.5.26952-0.amd64.rpm on a CentOS 6.7 system and switching into SuperClassic mode, starting the service produces a script type error:
# service firebird start
Starting Firebird server [default] /usr/bin/dirname: extra operand `-daemon'
Try `/usr/bin/dirname --help' for more information.
[ OK ]
This comes from /etc/rc.d/init.d/firebird here:
case "$1" in
start)
echo -n "Starting $FULLNAME "
daemon --user=$FBRunUser "export FIREBIRD LD_LIBRARY_PATH; $GUARDIAN -pidfile $pidfile -daemon -forever"
The issue is that the daemon() shell function is trying to extract the actual executable name (which is $GUARDIAN) from the second parameter, but it's getting confused by the string, attempting to run dirname on te wrong thing. It's very confused.
This causes - among other things - the pid file not to be created properly, and the "service" infrastructure doesn't know if it's running or not.
The fix is to add a
--check="$GUARDIAN"
parameter to the daemon line (I put it first), which provides the executable name so the shell function doesn't have to guess.
This /etc/rc.d/init.d/firebird script is pulled from the install bundle in /opt/firebird/misc/firebird.init.d.mandrake, and this is why I'm not submitting this as a patch.
The fix I mention works great on CentOS 6.7, but I have no idea if it works or breaks on Mandrake, or on other versions of Linux; this requires a bit more installation study that I can't do - I've never used and don't have Mandrake.
Looking in the svn logs, it appears that this behavior was changed to use the "daemon" shell function here:
r43324 \| alexpeshkoff \| 2009\-07\-21 04:02:30 \-0700 \(Tue, 21 Jul 2009\) \| 2 lines
Updated startup script from Philippe Makowski
This is a suspiciously long time ago for this issue to appear to be unreported (I couldn't find it in the tracker), so I'm not sure what introduced the issue.
The text was updated successfully, but these errors were encountered:
An obvious question is whether --check is supported widely enough, and the answer is yes. Looking at CentOS 5.11, which has a kernel much older than one supported by FIrebird 2.5.5, /etc/rc.d/init.d/functions has a daemon() that accepts the --check parameter..
The question of Mandrake is also moot, as that seems to be a dead distribution and I doubt even the most recent release would support 2.5.5, so I guess a better fix would be to also rename the file to http://firebird.init.d.redhat.in but that's a different issue.
Still unaddressed is CentOS 7, on which this still doesn't install, but that's also a different issue.
Submitted by: Steve Friedl (sjfriedl)
Votes: 1
After installing FirebirdCS-2.5.5.26952-0.amd64.rpm on a CentOS 6.7 system and switching into SuperClassic mode, starting the service produces a script type error:
# service firebird start
Starting Firebird server [default] /usr/bin/dirname: extra operand `-daemon'
Try `/usr/bin/dirname --help' for more information.
[ OK ]
This comes from /etc/rc.d/init.d/firebird here:
case "$1" in
start)
echo -n "Starting $FULLNAME "
daemon --user=$FBRunUser "export FIREBIRD LD_LIBRARY_PATH; $GUARDIAN -pidfile $pidfile -daemon -forever"
The issue is that the daemon() shell function is trying to extract the actual executable name (which is $GUARDIAN) from the second parameter, but it's getting confused by the string, attempting to run dirname on te wrong thing. It's very confused.
This causes - among other things - the pid file not to be created properly, and the "service" infrastructure doesn't know if it's running or not.
The fix is to add a
--check="$GUARDIAN"
parameter to the daemon line (I put it first), which provides the executable name so the shell function doesn't have to guess.
daemon --check="$GUARDIAN" --user=$FBRunUser "export FIREBIRD LD_LIBRARY_PATH; $GUARDIAN -pidfile $pidfile -daemon -forever"
This /etc/rc.d/init.d/firebird script is pulled from the install bundle in /opt/firebird/misc/firebird.init.d.mandrake, and this is why I'm not submitting this as a patch.
The fix I mention works great on CentOS 6.7, but I have no idea if it works or breaks on Mandrake, or on other versions of Linux; this requires a bit more installation study that I can't do - I've never used and don't have Mandrake.
Looking in the svn logs, it appears that this behavior was changed to use the "daemon" shell function here:
This is a suspiciously long time ago for this issue to appear to be unreported (I couldn't find it in the tracker), so I'm not sure what introduced the issue.
The text was updated successfully, but these errors were encountered: