[SERVER-1977] condrestart uses wrong filename Created: 20/Oct/10  Updated: 12/Jul/16  Resolved: 17/Mar/11

Status: Closed
Project: Core Server
Component/s: Packaging
Affects Version/s: 1.6.3
Fix Version/s: 1.8.0-rc0

Type: Bug Priority: Trivial - P5
Reporter: Chris Johnson Assignee: Richard Kreuter (Inactive)
Resolution: Done Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

RHEL 5, rpm: mongo-stable-server-20100930-mongodb_1.fc13


Operating System: Linux
Participants:

 Description   

I believe the conditional restart condition of the mongod init script (/etc/init.d/mongod) has a typo for the filename being checked for the conditional restart condition. It is using /var/lock/subsys/mongodb to see if mongo is running and I think it should be using /var/lock/subsys/mongod instead

63 condrestart)
64 [ -f /var/lock/subsys/mongodb ] && restart || :
65 ;;

The start and stop conditions use mongod instead of mongodb

27 start()
28

{ 29 echo -n $"Starting mongod: " 30 daemon --user "$MONGO_USER" $mongod $OPTIONS 31 RETVAL=$? 32 echo 33 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/mongod 34 }

35
36 stop()
37

{ 38 echo -n $"Stopping mongod: " 39 killproc -p /var/lib/mongo/mongod.lock -t30 -TERM /usr/bin/mongod 40 RETVAL=$? 41 echo 42 [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/mongod 43 }

 Comments   
Comment by Richard Kreuter (Inactive) [ 17/Mar/11 ]

Fixed in d039110cb7adf43af9c9c6fc0e19818d76f3800c.

Comment by Travis Whitton [ 09/Feb/11 ]

Just curious, with the fix being so trivial, why wait for 1.9 to fix it?

Generated at Thu Feb 08 02:58:37 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.