Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.

Bug 281

Summary: init.d/functions status() grep for pid can fail
Product: [Retired] Red Hat Linux Reporter: bjn
Component: basesystemAssignee: Bill Nottingham <notting>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.2CC: rvokal
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 1998-12-21 17:29:40 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description bjn 1998-12-03 20:29:18 UTC
The init.d functions script has a shell function called
status().  In the course of getting the status of a daemon
it must find its pid.

If pidof fails, it does a "ps | grep" to find it.  However,
the grep process itself shows up in the output.  This is
a common pitfall with this method; the usual remedy is to
add "| grep -v grep" in the pipeline to strip it out.

Patch en route.

Comment 1 David Lawrence 1998-12-03 20:59:59 UTC
This bug has been assigned to a developer.

Comment 2 Bill Nottingham 1998-12-06 20:52:59 UTC
*** Bug 314 has been marked as a duplicate of this bug. ***

Comment 3 Jeff Johnson 1998-12-21 17:29:59 UTC
This has been fixed in a slightly different way in the
development version of initscripts.