pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Sbob <sbob@quadratum-braccas.com>
Cc: Pgsql-admin <pgsql-admin@lists.postgresql.org>
Subject: Re: using pg_ctl over ssh hangs
Date: Thu, 19 Oct 2023 21:32:47 -0400
Message-ID: <3667893.1697765567@sss.pgh.pa.us> (raw)
In-Reply-To: <b4603ebf-afef-4b6a-af75-de7fd26c9924@quadratum-braccas.com>
References: <b4603ebf-afef-4b6a-af75-de7fd26c9924@quadratum-braccas.com>

Sbob <sbob@quadratum-braccas.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@${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





view thread (4+ messages)  latest in thread

Message-ID: <3667893.1697765567@sss.pgh.pa.us>
Permalink:  ../3667893.1697765567@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/3667893.1697765567@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: tgl@sss.pgh.pa.us, sbob@quadratum-braccas.com, pgsql-admin@lists.postgresql.org
  Subject: Re: using pg_ctl over ssh hangs
  In-Reply-To: <3667893.1697765567@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox