Re: trouble with an older version of postgresql - Mailing list pgsql-novice

From Tom Lane
Subject Re: trouble with an older version of postgresql
Date
Msg-id 10805.1265644189@sss.pgh.pa.us
Whole thread Raw
In response to Re: trouble with an older version of postgresql  (Krešimir Križanović <Kresimir.Krizanovic@fer.hr>)
List pgsql-novice
=?UTF-8?B?S3JlxaFpbWlyIEtyacW+YW5vdmnEhw==?= <Kresimir.Krizanovic@fer.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

pgsql-novice by date:

Previous
From: Tom Lane
Date:
Subject: Re: Incomplete pg_dump operation
Next
From: peter@vfemail.net
Date:
Subject: Re: Incomplete pg_dump operation