Re: using pg_ctl over ssh hangs

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Sbob <sbob(at)quadratum-braccas(dot)com>
Cc: Pgsql-admin <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: Re: using pg_ctl over ssh hangs
Date: 2023-10-20 01:32:47
Message-ID: 3667893.1697765567@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Sbob <sbob(at)quadratum-braccas(dot)com> writes:
> I am wanting to run pg_ctl as a command over ssh, however when I pass
> start it hangs until I do a Ctl-C

> $ ssh -T postgres(at)${node3} "/usr/pgsql-14/bin/pg_ctl -D
> /var/lib/pgsql/14/data start"

If you don't specify a log file (-l option to pg_ctl) then the
postmaster's stdout doesn't get dissociated from the calling terminal,
which likely explains why ssh doesn't think the session is done.

regards, tom lane

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Ron 2023-10-20 02:58:12 Re: Binaries for EOL version?
Previous Message David G. Johnston 2023-10-20 01:31:49 Re: using pg_ctl over ssh hangs