Thank you Zdenek! In the meantime I realized that the SMF configuration in the Sun document referenced in my posting is meant to be used with a version of PostgreSQL which is optimized for Solaris. My understanding is that the improvements by Sun include changes to pg_ctl so that the OpenSolaris pg_ctl effectively duplicates the functionality of checking the pid file's status in postmaster. The OpenSolaris pg_ctl performs the same check on pids as postmaster does and starts up postmaster, if it deems safe deleting the pid file.
The SMF configuration in the Sun document achieves therefore the same functional behaviour as the example Linux startup script command suggested by Tom Lane. At least, this is how I understand the state of affairs. Thanks again Peter PS: It is not entirely clear though why Sun's version of PostgreSQL has changed pg_ctl instead of leaving it intact and adding a new executable with the modified functionality. Creating their own pg_ctl equivalent would have had two advantages: (a) Fork-related confusions such as I have experienced would have been minimized; (b) The Open Solaris contribution could have been added to the common PostgreSQL source tree for the benefit of the larger community (or may be they didn't want to do it for legal reasons?) -- This message posted from opensolaris.org
