Bug 441605 - /etc/init.d/nfslock status gives incorrect return code
Summary: /etc/init.d/nfslock status gives incorrect return code
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: nfs-utils
Version: 9
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Steve Dickson
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-04-08 23:11 UTC by Michal Schmidt
Modified: 2008-11-24 17:11 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-11-24 17:11:36 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
return correct exit code from nfslock status (220 bytes, patch)
2008-04-08 23:11 UTC, Michal Schmidt
no flags Details | Diff

Description Michal Schmidt 2008-04-08 23:11:01 UTC
Description of problem:

Quoting http://fedoraproject.org/wiki/Packaging/SysVInitScript :
If the status action is requested, the initscript must return the correct exit
status code, from this list:
 0:     program is running or service is OK
...
 3:     program is not running
---

"/etc/init.d/nfslock status" always returns 0. Therefore nfslock always appears
as running in system-config-services.

Version-Release number of selected component (if applicable):
nfs-utils-1.1.2-1.fc9.x86_64

How reproducible:
always

Steps to Reproduce:
1. Make sure nfslock is stopped.
2. /etc/init.d/nfslock status ; echo $?
  
Actual results:
rpc.statd is stopped
0


Expected results:
rpc.statd is stopped
3


Additional info:
The attached patch applies on top of my patch from bug 441604.

Comment 1 Michal Schmidt 2008-04-08 23:11:01 UTC
Created attachment 301726 [details]
return correct exit code from nfslock status

Comment 2 Steve Dickson 2008-04-25 15:41:47 UTC
Fixed in nfs-utils-1.1.2-3

Comment 3 Bug Zapper 2008-05-14 09:09:55 UTC
Changing version to '9' as part of upcoming Fedora 9 GA.
More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping


Note You need to log in before you can comment on or make changes to this bug.