Re: upgrading postgres 7.3.4 to 9.1.9

From: Khangelani Gama <kgama(at)argility(dot)com>
To: pgsql-admin(at)postgresql(dot)org
Subject: Re: upgrading postgres 7.3.4 to 9.1.9
Date: 2014-08-04 12:14:14
Message-ID: 8e62fc3c2be3628fefbc9395c895f52b@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

P.S

plperl.control file is in

=>/home/ellerines/pgsql9_upgrade/postgresql-9.1.9/src/pl/plperl

=> l -ltrh

total 364K

-rw-r--r-- 1 1107 1107 4.8K Apr 1 2013 Util.xs

-rw-r--r-- 1 1107 1107 2.2K Apr 1 2013 text2macro.pl

-rw-r--r-- 1 1107 1107 3.5K Apr 1 2013 SPI.xs

-rw-r--r-- 1 1107 1107 462 Apr 1 2013 README

-rw-r--r-- 1 1107 1107 171K Apr 1 2013 ppport.h

-rw-r--r-- 1 1107 1107 376 Apr 1 2013 plperlu--unpackaged--1.0.sql

-rw-r--r-- 1 1107 1107 367 Apr 1 2013 plperl--unpackaged--1.0.sql

-rw-r--r-- 1 1107 1107 187 Apr 1 2013 plperlu.control

-rw-r--r-- 1 1107 1107 337 Apr 1 2013 plperlu--1.0.sql

-rw-r--r-- 1 1107 1107 2.0K Apr 1 2013 plperl_opmask.pl

-rw-r--r-- 1 1107 1107 2.9K Apr 1 2013 plperl_helpers.h

-rw-r--r-- 1 1107 1107 2.7K Apr 1 2013 plperl.h

-rw-r--r-- 1 1107 1107 176 Apr 1 2013 plperl.control

-rw-r--r-- 1 1107 1107 100K Apr 1 2013 plperl.c

-rw-r--r-- 1 1107 1107 323 Apr 1 2013 plperl--1.0.sql

-rw-r--r-- 1 1107 1107 922 Apr 1 2013 plc_trusted.pl

-rw-r--r-- 1 1107 1107 1.9K Apr 1 2013 plc_perlboot.pl

-rw-r--r-- 1 1107 1107 253 Apr 1 2013 nls.mk

-rw-r--r-- 1 1107 1107 3.8K Apr 1 2013 GNUmakefile

drwxrwxrwx 2 1107 1107 4.0K Apr 1 2013 sql

drwxrwxrwx 2 1107 1107 4.0K Apr 1 2013 po

drwxrwxrwx 2 1107 1107 4.0K Apr 1 2013 expected

*From:* Khangelani Gama [mailto:kgama(at)argility(dot)com]
*Sent:* 04 August 2014 12:35 PM
*To:* 'pgsql-admin(at)postgresql(dot)org'
*Subject:* upgrading postgres 7.3.4 to 9.1.9

Hi

Please help me here, there was an upgrade done by someone who left the
company but there is one database which was not upgraded. The server has
several instances running on it but this one instance is still on postgres
7.

I dumped postgres 7 database using pg_dump –Fc on postgres 7 binaries and
then attempted pg_restore –Fc (using postgres9.1.9 binaries) which threw
out the following errors. Note that postgres 7 is still running on it’s own
instance. I am doing this postgres 9 restore on a different port and
different instance to get it right first before implementing the change.

ERROR: language "plpgsql" already exists

DETAIL: Proceeding with relation creation anyway.

ERROR: could not access file "$libdir/plperl": No such file or directory

ERROR: function public.plperl_call_handler() does not exist

ERROR: could not access file "$libdir/plperl": No such file or directory

ERROR: language "plperlu" does not exist

Because of the above errors I tried the following

/usr/local/pgsql9/bin/createlang -p59999 plperl template1

createlang: language installation failed: ERROR: could not open extension
control file "/usr/local/pgsql9/share/extension/plperl.control": No such
file or directory

Then I looked for where extention is located:

~> locate plperl.control

/home/ellerines/pgsql9_upgrade/postgresql-9.1.9/src/pl/plperl/plperl.control

> /home/ellerines/pgsql9_upgrade/postgresql-9.1.9/src/bin

total 44K

-rw-r--r-- 1 1107 1107 658 Apr 1 2013 Makefile

drwxrwxrwx 2 1107 1107 4.0K Apr 1 2013 pgevent

drwxrwxrwx 3 1107 1107 4.0K Aug 18 2013 initdb

drwxrwxrwx 3 1107 1107 4.0K Aug 18 2013 pg_ctl

drwxrwxrwx 3 1107 1107 4.0K Aug 18 2013 pg_dump

drwxrwxrwx 3 1107 1107 4.0K Aug 18 2013 psql

drwxrwxrwx 3 1107 1107 4.0K Aug 18 2013 scripts

drwxrwxrwx 3 1107 1107 4.0K Aug 18 2013 pg_controldata

drwxrwxrwx 3 1107 1107 4.0K Aug 18 2013 pg_config

drwxrwxrwx 3 1107 1107 4.0K Aug 18 2013 pg_resetxlog

drwxrwxrwx 3 1107 1107 4.0K Aug 18 2013 pg_basebackup

How can then do a pg_restore to prevent errors above?

Kind regards,

Khangelani

CONFIDENTIALITY NOTICE
The contents of and attachments to this e-mail are intended for the addressee only, and may contain the confidential
information of Argility (Proprietary) Limited and/or its subsidiaries. Any review, use or dissemination thereof by anyone
other than the intended addressee is prohibited.If you are not the intended addressee please notify the writer immediately
and destroy the e-mail. Argility (Proprietary) Limited and its subsidiaries distance themselves from and accept no liability
for unauthorised use of their e-mail facilities or e-mails sent other than strictly for business purposes.

Browse pgsql-admin by date

  From Date Subject
Next Message Kevin Grittner 2014-08-04 13:30:08 Re: upgrading postgres 7.3.4 to 9.1.9
Previous Message Khangelani Gama 2014-08-04 10:34:52 upgrading postgres 7.3.4 to 9.1.9