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 - init.d/functions status() grep for pid can fail
Summary: init.d/functions status() grep for pid can fail
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: basesystem
Version: 5.2
Hardware: i386
OS: Linux
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact:
: 314 (view as bug list)
Depends On:
TreeView+ depends on / blocked
Reported: 1998-12-03 20:29 UTC by bjn
Modified: 2014-03-17 02:08 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 1998-12-21 17:29:40 UTC

Attachments (Terms of Use)

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.

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