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 80782 - postgresql init script always returns 0
Summary: postgresql init script always returns 0
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: postgresql
Version: 8.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Tom Lane
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2002-12-31 09:54 UTC by Greg Pyhl
Modified: 2013-07-03 02:59 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2005-01-24 04:36:02 UTC


Attachments (Terms of Use)

Description Greg Pyhl 2002-12-31 09:54:05 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2) Gecko/20021203

Description of problem:
Last line of /etc/rc.d/init.d/postgresql says:

exit 0

This should be changed to

exit $?

in order to get correct exit values when server is running/stopped/dead/etc.
Correct exit value is important for scripts and all other init scripts uses
them, too.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. Start and stop postgresql via init script
2. /etc/init.d/postgresql status
3.
    

Actual Results:  exit value is always 0.

Expected Results:  exit value should depend on server state.

Comment 1 Greg Pyhl 2003-03-04 08:14:34 UTC
So, what's the story here?

Comment 2 Andrew Overholt 2003-03-04 16:45:10 UTC
I am looking into this.

Comment 3 Andrew Overholt 2003-03-12 22:56:28 UTC
Reassigning.

Comment 4 Tom Lane 2005-01-24 04:36:02 UTC
Done in PostgreSQL 8.0 version of init script.


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