Re: trouble with an older version of postgresql

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Krešimir Križanović <Kresimir(dot)Krizanovic(at)fer(dot)hr>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: trouble with an older version of postgresql
Date: 2010-02-08 15:49:49
Message-ID: 10805.1265644189@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

=?UTF-8?B?S3JlxaFpbWlyIEtyacW+YW5vdmnEhw==?= <Kresimir(dot)Krizanovic(at)fer(dot)hr> writes:
> The trouble is there is no database. When i try to create the first one using createdb, i get an error:

> createdb: could not connect to database postgres: FATAL: Database "postgres" does not exist in the system catalog.

It looks like you are trying to use a newer version of the client-side
tools with an older server. The "database does not exist" message
hasn't been spelled exactly that way since 7.3, so your server is at
least that old (and thus way, way, way overdue for an update :-().
Recent versions of the client tools assume that a database named
"postgres" exists, but we didn't start creating one of those by
default until 8.1 or so.

What you'll need to do is tell the client program to connect to one
of the databases that does exist. Try "template1" for starters.
If you feel like it, you can then create a database named "postgres"
so that the client default works --- but it'd be more useful to
spend your time on retiring that ancient server in favor of something
more modern.

regards, tom lane

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message peter 2010-02-08 18:34:56 Re: Incomplete pg_dump operation
Previous Message Tom Lane 2010-02-08 15:37:56 Re: Incomplete pg_dump operation