Thread: Can't start PostgreSQL

Can't start PostgreSQL

From
Ian Johnson
Date:
Hi List

I want to develop an application in PostgreSQL but when starting the service I get the following message:

An old version of the database format was found.
You need to upgrade the data format before using PostgreSQL.
See /usr/share/doc/postgresql-8.1.4/README.rpm-dist for more information.

I am running Fedora Core 5 but initially had built the system with Fedora Core 3, with PostgreSQL installed and automatically updated it over the past 2 years.  I may have created a test database 2 years ago which may be the source of the problem.  Is this the source of the problem?  I could find nothing in README.rpm-dist that helps.

I would appreciate any advice on how to deal with this problem.


Thank you


Ian Johnson

Re: Can't start PostgreSQL

From
Richard Huxton
Date:
Ian Johnson wrote:
> Hi List
>
> I want to develop an application in PostgreSQL but when starting the
> service I get the following message:
>
> An old version of the database format was found.
> You need to upgrade the data format before using PostgreSQL.
> See /usr/share/doc/postgresql-8.1.4/README.rpm-dist for more
> information.
>
> I am running Fedora Core 5 but initially had built the system with
> Fedora Core 3, with PostgreSQL installed and automatically updated it
> over the past 2 years.  I may have created a test database 2 years ago
> which may be the source of the problem.  Is this the source of the
> problem?  I could find nothing in README.rpm-dist that helps.

Yep - you have an old installation still there. The RPM probably refused
to destroy the old installation without approval from you. You'll need
to initdb the directory (see the online manuals for how to run initdb,
or check the RPM /etc/init.d/ scripts)

--
   Richard Huxton
   Archonet Ltd

Re: Can't start PostgreSQL

From
Casey Duncan
Date:
It seems you were running a pre-8.x postgresql version before, its
data files are not compatible with the new version you have now.
You'll need to find out the version that used to be installed by
looking at the PG_VERSION file in your postgres data directory.

Once you do that you will need to install the old version (you can
download it from postgresql.org), start it against the database
directory and dump the databases. You can use pg_dumpall for this.

Once you have dumped the dbs, you can move the old data directory
aside, and run initdb for the new postgresql (8.1.4) and start it.
Then import the databases you previously dumped.

hth,

-Casey

On Jul 27, 2006, at 9:22 AM, Ian Johnson wrote:

> Hi List
>
> I want to develop an application in PostgreSQL but when starting
> the service I get the following message:
>
> An old version of the database format was found.
> You need to upgrade the data format before using PostgreSQL.
> See /usr/share/doc/postgresql-8.1.4/README.rpm-dist for more
> information.
>
> I am running Fedora Core 5 but initially had built the system with
> Fedora Core 3, with PostgreSQL installed and automatically updated
> it over the past 2 years.  I may have created a test database 2
> years ago which may be the source of the problem.  Is this the
> source of the problem?  I could find nothing in README.rpm-dist
> that helps.
>
> I would appreciate any advice on how to deal with this problem.
>
>
> Thank you
>
>
> Ian Johnson


Re: Can't start PostgreSQL

From
Bruno Wolff III
Date:
On Thu, Jul 27, 2006 at 10:22:33 -0600,
  Ian Johnson <norules@telus.net> wrote:
>
> I want to develop an application in PostgreSQL but when starting the
> service I get the following message:
>
> An old version of the database format was found.
> You need to upgrade the data format before using PostgreSQL.
> See /usr/share/doc/postgresql-8.1.4/README.rpm-dist for more
> information.
>
> I am running Fedora Core 5 but initially had built the system with
> Fedora Core 3, with PostgreSQL installed and automatically updated it
> over the past 2 years.  I may have created a test database 2 years ago
> which may be the source of the problem.  Is this the source of the
> problem?  I could find nothing in README.rpm-dist that helps.

That could certainly be the problem.

> I would appreciate any advice on how to deal with this problem.

Probably you want to delete the old database cluster and do a dbinit to create
a new one. The old one will probably be in /var/lib/pgsql/data .

Re: Can't start PostgreSQL

From
Ian Johnson
Date:
Thank you all

Deleting the old data base cleared up the problem.


Ian


On Thu, 2006-07-27 at 15:59 -0500, Bruno Wolff III wrote:
On Thu, Jul 27, 2006 at 10:22:33 -0600,
  Ian Johnson <norules@telus.net> wrote:
> 
> I want to develop an application in PostgreSQL but when starting the
> service I get the following message:
> 
> An old version of the database format was found.
> You need to upgrade the data format before using PostgreSQL.
> See /usr/share/doc/postgresql-8.1.4/README.rpm-dist for more
> information.
> 
> I am running Fedora Core 5 but initially had built the system with
> Fedora Core 3, with PostgreSQL installed and automatically updated it
> over the past 2 years.  I may have created a test database 2 years ago
> which may be the source of the problem.  Is this the source of the
> problem?  I could find nothing in README.rpm-dist that helps.

That could certainly be the problem.

> I would appreciate any advice on how to deal with this problem.

Probably you want to delete the old database cluster and do a dbinit to create
a new one. The old one will probably be in /var/lib/pgsql/data .

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
       choose an index scan if your joining column's datatypes do not
       match