From: | Stephen Robert Norris <srn(at)commsecure(dot)com(dot)au> |
---|---|
To: | Shridhar Daithankar <shridhar_daithankar(at)myrealbox(dot)com> |
Cc: | Andrey Mosienko <feo(at)feo(dot)org(dot)ru>, Postgres <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Detaching from controlling terminal |
Date: | 2003-11-19 02:31:54 |
Message-ID: | 1069209114.11546.14.camel@ws12.commsecure.com.au |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Tue, 2003-11-18 at 17:52, Shridhar Daithankar wrote:
> Andrey Mosienko wrote:
>
> > Shridhar Daithankar wrote:
> >
> >>Andrey Mosienko wrote:
> >>
> >>
> >>>We are using PostgreSQL about two years beginning from version 7.0.
> >>>I have one question about starting postmaster:
> >>> Is there way to detach it from the controlling terminal under FreeBSD?
> >>>
> >>>My situation: I start postmaster manually:
> >>>
> >>>su pgsql -c "/usr/local/pgsql/bin/pg_ctl
> >>>-D /usr/local/pgsql/data -l /usr/local/pgsql/log/pgsql.log start"
> >>
> >>You can either use pg_ctl or nohup. Using pg_ctl is recommended.
> >>
> >
> >
> > su pgsql -c "/usr/local/pgsql/bin/pg_ctl -D /usr/local/pgsql/data -l /usr/local/pgsql/log/pgsql.log start"
> > ^^^^^^^
>
> Damn.. Sorry I missed that. Usually pg_ctl detaches from terminal.
> > What is nohup?
>
> When you start a job with nohup and put it in background, the job keeps running
> even if terminal detaches.
>
> When a terminal closes, a sighup is delivered to all applications started from
> that terminal. Nohup just ignores it.
>
> man nohup for more details.
>
> Shridhar
Be aware that nohup lowers the priority of the process by default - this
can be undesirable for a server...
Stephen
From | Date | Subject | |
---|---|---|---|
Next Message | Brian H Mayo | 2003-11-19 02:43:48 | A newbie question |
Previous Message | Martijn van Oosterhout | 2003-11-19 02:30:56 | Re: performance problem |