Skip site navigation (1) Skip section navigation (2)

Question about initdb -t

From: "Oliver Elphick" <olly(at)lfix(dot)co(dot)uk>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Question about initdb -t
Date: 2000-04-02 06:07:46
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
The man page for initdb says that the -t option will overwrite the template1
database with the up-to-date structure and suggests that this is the way to
upgrade to a newer release:


       -t     Replace  the  template1  database  in  an  existing
              database system, and  don't  touch  anything  else.
              This  is  useful when you need to upgrade your tem­
              plate1 database using initdb from a  newer  release
              of  PostgreSQL, or when your template1 database has
              become corrupted by some system  problem.  Normally
              the  contents of template1 remain constant through­
              out the life of  the  database  system.  You  can't
              destroy  anything by running initdb with the --tem­
              plate option.

How does this relate to pg_upgrade?  Is it necessary to do a pg_dump? If
not, is there a danger of new oids in template1 overwriting old oids in
user data?  (I am not clear whether oids are unique to a database or
to the whole PostgreSQL installation.)

Oliver Elphick                                Oliver(dot)Elphick(at)lfix(dot)co(dot)uk
Isle of Wight                    
               PGP key from public servers; key ID 32B8FAA1
     "If the Son therefore shall make you free, ye shall be 
      free indeed."         John 8:36  


pgsql-hackers by date

Next:From: Michael MeskesDate: 2000-04-02 08:07:50
Subject: Re: Call for porting reports
Previous:From: Tom LaneDate: 2000-04-02 05:41:13
Subject: Re: --enable-locale doesn't work

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group