database files are incompatible with server

Posted on 2005-05-16
Last Modified: 2008-02-01
Hi to All,
I installed Postgresql 7.3.2 on linux.It was working fine upto now.
By mistake somebody restarted the linux.Now after restarting the postgresql it is giving the error below.
Please help me.I am not a DB guy.

FATAL:  database files are incompatible with server
DETAIL:  The data directory was initialized by PostgreSQL version 7.3, which is not compatible with this version 7.4.3.

Thanks in advance
Question by:m_sharma98
    LVL 4

    Expert Comment

    It seems that you have two versions of PostgreSQL installed: 7.3 and 7.4.3. I suppose that someone started 7.3 version manually, initialized database with it, but did not put it in initialization scripts. After the restart version 7.4 started (why did you need older version for?).

    Stop it, start version 7.3 and this time put it in initscripts.

    LVL 22

    Expert Comment

    by:earth man2
    Reinstall Postgresql 7.3
    Reinstall PostgreSQL 8.3
    install database dump.

    I would not use 7.4 for production use.

    Author Comment

    Thanks Robson,
    But how can I get the verion number which is running on .
    And How can I put it in initialization scripts?
    Actuallu I am new to postgresql.Please help me

    Author Comment

    I am trying to start my db with the command below

    /usr/local/pgsql/bin/postmaster -i -D /usr/local/pgsql/data dblog 2>&1 &

    But it is also giving the same error.
    LVL 22

    Accepted Solution

    You MUST use PostgreSQL 7.3 FULL STOP.

    If you want ro upgrade you export the database using pg_dump utility.  Import to Postgres 7.4 or 8.3 using psql.
    LVL 4

    Assisted Solution

    > But how can I get the verion number which is running on .
    select version();

    > And How can I put it in initialization scripts?
    Thats not postgresql stuff: it depends on your system.


    Featured Post

    What Is Threat Intelligence?

    Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

    Join & Write a Comment

    Best database to use for Maps is PostgreSQL. This is an open source database. Comes as a package with most Linux OS. For more info visit the following site: ( This requires some add-o…
    Many developers have database experience, but are new to PostgreSQL. It has some truly inspiring capabilities. I have several years' experience with Microsoft's SQL Server. When I began working with MySQL, I wanted a quick-reference to MySQL (htt…
    Steps to create a PostgreSQL RDS instance in the Amazon cloud. We will cover some of the default settings and show how to connect to the instance once it is up and running.
    In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor ( If you're interested in additional methods for monitoring bandwidt…

    755 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    22 Experts available now in Live!

    Get 1:1 Help Now