Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id CE3B29F9B63 for ; Wed, 31 Oct 2007 18:40:26 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 84474-04-5 for ; Wed, 31 Oct 2007 18:39:44 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.173]) by postgresql.org (Postfix) with ESMTP id 2FE759FA423 for ; Wed, 31 Oct 2007 16:58:59 -0300 (ADT) Received: by ug-out-1314.google.com with SMTP id j3so368525ugf for ; Wed, 31 Oct 2007 12:58:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=6MoFtRQH3w4m34/wPko02hMOpPOo5jmoaZZbGbBAL5M=; b=HiYzAnx2u5n8kB1k968ISvz86KvbKOkE+OCMvKeUlZxEfXyCY6+DqVdXDgax4443Fie9iI+tEr6AJCawC/X20HMBkFuYTlPPPnifJkT3hwMgPQTdJwg2ZydDjxXDrqYPM4lgasMZEDa8w5bIzLdWv45GkhLHcZp8bye+RMLQ2MI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=gPz1PenRMJq5ehUrkVvS2AqKwMdVqpOTJ1vhNswbUPjreUMdd7XULJb0Pdq2v5KgPmwLmvnCGBqsi8PAfhw1bDA9aGyR3I5XcH+rSeXSoPSmOO0dhcPzrYir9s0nnAb041c1dsq5R4O4/auwjCTqBEOm3BYEBqwTf7zjDdjigtM= Received: by 10.67.30.13 with SMTP id h13mr1053890ugj.1193860737646; Wed, 31 Oct 2007 12:58:57 -0700 (PDT) Received: by 10.67.40.10 with HTTP; Wed, 31 Oct 2007 12:58:57 -0700 (PDT) Message-ID: Date: Wed, 31 Oct 2007 14:58:57 -0500 From: "Scott Marlowe" To: "Chris Hoover" Subject: Re: Upgrading from 7.2.1 to 8.x Cc: "pgsql-admin@postgresql.org Admin" In-Reply-To: <1d219a6f0710311028s745446aay7dd59c1982af7b03@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <1d219a6f0710311028s745446aay7dd59c1982af7b03@mail.gmail.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200710/323 X-Sequence-Number: 27237 On 10/31/07, Chris Hoover wrote: > Question, > > I have an ancient database that is running Postgresql 7.2.1 on AIX. Is it > safe to directly upgrade the database to 8.1? If not, what steps do I need > to take? It might be better to upgrade to 7.2.xx where xx is the latest version, as some bugs in the older version you have might make dumping data out of it fail. You can't just upgrade it in place to 8.x, you have to dump and restore it. It is standard to use the pg_dump from the later version against the older version. So, you should install 8.2.5 on another directory and another port on your AIX machine (or a new machine if you're migrating hardware at the same time) and run pg_dumpall from 8.2.5 against the 7.2.x database. Generally speaking, you can do something like this: /usr/local/pg82/bin/pg_dumpall -h oldmachine -p 5432 | psql -h newmachine -p5433 template1 and pg_dumpall will handle the dependencies etc for you. > I have been pushing for 3 years to upgrade this database, and with some > upcoming projects, I am going to do another push with management to upgrade > this database. Push hard. They'll thank you later. > Also, I know there are a ton of fixes/improvements from 7.2, but are there > any major data losing bugs in this version that I can use as added pressure > on management? Well, 7.2 is broken and not going to get fixed. It WILL eventually eat your data. In fact, I'm honestly surprised it hasn't failed yet. Besides that, 8.2.5 is about 1,000 times faster (ok, maybe not, but it certainly feels that way). Go right to 8.2.5. 8.2 has been out a year, it's stable, and as long as upgrades seem to take in your shop, being one version further along ain't gonna hurt.