Return-Path: pg_adm@postgres.berkeley.edu
Received: by postgres.Berkeley.EDU (5.61/1.29)
	id AA00874; Mon, 28 Dec 92 02:21:22 -0800
Message-Id: <9212281021.AA00874@postgres.Berkeley.EDU>
From: ilya lybovich <ill@CS.HUJI.AC.IL>
Subject: Re: start up the postmaster in rc.local
To: postgres@postgres.berkeley.edu
Sender: pg_adm@postgres.berkeley.edu
In-Reply-To: Your message of "Mon, 28 Dec 1992 17:32:40 PST."
             <9212280932.AA00774@postgres.Berkeley.EDU> 
Date: Mon, 28 Dec 1992 12:21:43 +0200
From: ilya lybovich <ill@CS.HUJI.AC.IL>

| In order to talk with the backend, I need to start up the postmaster. I
| try to start up the postmaster in /etc/rc.local as follows:

| su - postgres -c "/usr/postgres/bin/postmaster &"

| However, it fails. Although the ps show the postmaster is there, users
| still cannot talk with the backend. I think there is something do with 

| setenv POSTGRESHOME ~postgres.

| I have already created a soft link to /usr/postgres but postmaster
| started from rc.local still cannot work.

| Has anyone encountered this problem before? If you know the solution,
| please send me a e-mial. I will very appreciate it. Thanks.

 we are using the following : 
  1. postmaster setuid'ed by root 
  2. rc.local contains : 
 
   if [ -f /usr/local/etc/postgres.startup ];
     /usr/local/etc/postgres.startup; echo -n ' postgres postmaster'  



  3.  here contents of the  /usr/local/etc/postgres.startup : 
--------------------------------------------------------------------
#! /bin/sh 

if [ -f /usr/local/postgres/bin/postmaster ]; then
         POSTGRESHOME=/usr/local/postgres ; export POSTGRESHOME;
         /usr/local/postgres/bin/postmaster -p `cat /usr/local/postgres/.port`&
fi
---------------------------------------------------------------------


 Ilya Liubovich 
 Department of Computer Science . Hebrew University of the Jerusalem 
 System Group 

E-mail:  ill@cs.huji.ac.il
  
  
