Re: Unexplained createdb mydb response

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: rltenney(at)gmail(dot)com
Cc: pgsql-docs(at)lists(dot)postgresql(dot)org
Subject: Re: Unexplained createdb mydb response
Date: 2019-06-09 14:55:16
Message-ID: 8174.1560092116@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs

PG Doc comments form <noreply(at)postgresql(dot)org> writes:
> I tried the first example in section 1.3 of the initial tutorial,
> createdb mydb
> The tutorial says
>> If this produces no response then this step was successful and you can
>> skip over the remainder of this section.

Well, it's right --- the normal behavior is to just do it without
printing anything:

$ createdb mydb
$

Or you might get an error:

$ createdb mydb
createdb: error: database creation failed: ERROR: database "mydb" already exists
$

> Well, it produces no response, no response at all. It doesn't even return
> control to the shell. I have to use ^C to kill it.

That's weird, but I think it's not in-scope for the docs (especially a
tutorial) to explain behavior that shouldn't be happening.

One idea is that you have a firewall or packet filter blocking the
connection attempt. In that case I'd expect createdb to time out and
report a connection failure when it gets no response, but the timeout
is probably a few minutes ... how long did you wait?

Another possibility is that createdb is trying to prompt for a database
password but for some reason the "Password:" prompt is not showing up
on your terminal. That could be a bug, but I'm not familiar enough
with the Cygwin environment to diagnose it.

> Any suggestions on what to do would be appreciated.

You'd probably be better off asking for help about this on the -novice
or -bugs lists than -docs.

regards, tom lane

In response to

Browse pgsql-docs by date

  From Date Subject
Next Message Ian Barwick 2019-06-10 02:06:54 doc: clarify "pg_signal_backend" default role
Previous Message Tom Lane 2019-06-07 14:22:49 Can we bring some organization to the configure options list?