Bug in all version with encryption
Dear Team,
I had recently upgraded my pgsql 7.4.2 to pgsql 8.2.5 on Solaris 9 Sparc
machine. All the installation went normally as per install documents of
Postgresql. In between the installation, I got the following error. But
at the end I could create database and can use the DB as normal.
-------
ERROR: incompatible library "/usr/lib/pgsql_clcrypt.so": missing magic
block
HINT: Extension libraries are required to use the PG_MODULE_MAGIC macro.
STATEMENT: CREATE FUNCTION blowfish_encrypt(text, text) RETURNS text
AS '/usr/lib/pgsql_clcrypt.so', 'blowfish_encrypt'
LANGUAGE c;
psql:pgsql7.4_dump_10012008:877: ERROR: incompatible library
"/usr/lib/pgsql_clcrypt.so": missing magic block
HINT: Extension libraries are required to use the PG_MODULE_MAGIC macro.
ERROR: incompatible library "/usr/lib/pgsql_clcrypt.so": missing magic
block
HINT: Extension libraries are required to use the PG_MODULE_MAGIC macro.
STATEMENT: CREATE FUNCTION blowfish_decrypt(text, text) RETURNS text
AS '/usr/lib/pgsql_clcrypt.so', 'blowfish_decrypt'
LANGUAGE c;
psql:pgsql7.4_dump_10012008:887: ERROR: incompatible library
"/usr/lib/pgsql_clcrypt.so": missing magic block
HINT: Extension libraries are required to use the PG_MODULE_MAGIC macro.
-----------
This problem is coming with all the versions of PGSQL. We had a good
experience with similar error when we were upgraded with 7.4.2 long
back. Can you pls advice what to do to rectify this error in Postgresql
8.2.5.
--Suresh Gupta
Regards,
G. V. Suresh Gupta
------------------------------------------------------------------------
---------------------------------------------------------
Innovative Technology Solutions(ITS), Zensar Technologies
Zensar Knowledge Park, Plot#5, MIDC IT Tower,
Kharadi, Off Nagar Road, Pune - 411014
Landline : +91-20-66453471 | +91-9890898688
Email : suresh.g@zensar.com | website: www.zensar.com
<http://www.zensar.com/>
DISCLAIMER:
This email may contain confidential or privileged information for the intended recipient(s) and the views expressed in the same are not necessarily the views of Zensar Technologies Ltd. If you are not the intended recipient or have received this e-mail by error, its use is strictly prohibited, please delete the e-mail and notify the sender. Zensar Technologies Ltd. does not accept any liability for virus infected mails.
Attachments:
Suresh Gupta VG wrote:
I had recently upgraded my pgsql 7.4.2 to pgsql 8.2.5 on Solaris 9
Sparc machine. All the installation went normally as per install
documents of Postgresql. In between the installation, I got the
following error. But at the end I could create database and can use
the DB as normal.
-------
ERROR: incompatible library "/usr/lib/pgsql_clcrypt.so": missing magic
block
HINT: Extension libraries are required to use the PG_MODULE_MAGIC macro.
STATEMENT: CREATE FUNCTION blowfish_encrypt(text, text) RETURNS text
AS '/usr/lib/pgsql_clcrypt.so', 'blowfish_encrypt'
LANGUAGE c;
...
-----------This problem is coming with all the versions of PGSQL. We had a good
experience with similar error when we were upgraded with 7.4.2 long
back. Can you pls advice what to do to rectify this error in
Postgresql 8.2.5.
this does not look like a postgres bug to me.
Offhand, it looks like your database loads custom functions from the
shared object library /usr/lib/pgsql_clcrypt.so which was probably built
for your older 7.4... you'd either need to rebuild that library to be
8.2 compatible, or remove the CREATE FUNCTION statements that reference
it (and modify any SQL code you have which calls these
blowfish_encrypt() etc functions...)
Thanks for your reply.
As per your suggestion, if we remove "CREATE FUNCTION" statement, we
cannot use that function.
Actually, we need this feature.
Can you pls suggest some url or docs to help us in developing the
c-language code to rectify this as we had done earlier for pgsql7.4.2.
And pls provide us with new macros introduced in 8.2.5 later to 7.4.2,
so that it can help us in our coding very mush
Thanks in advice.
Regards,
G. V. Suresh Gupta
------------------------------------------------------------------------
---------------------------------------------------------
Innovative Technology Solutions(ITS), Zensar Technologies
Zensar Knowledge Park, Plot#5, MIDC IT Tower,
Kharadi, Off Nagar Road, Pune - 411014
Landline : +91-20-66453471 | +91-9890898688
Email : suresh.g@zensar.com | website: www.zensar.com
-----Original Message-----
From: John R Pierce [mailto:pierce@hogranch.com]
Sent: Thursday, January 17, 2008 2:31 PM
To: Suresh Gupta VG
Cc: pgsql-bugs@postgresql.org
Subject: Re: [BUGS] Bug in all version with encryption
Suresh Gupta VG wrote:
I had recently upgraded my pgsql 7.4.2 to pgsql 8.2.5 on Solaris 9
Sparc machine. All the installation went normally as per install
documents of Postgresql. In between the installation, I got the
following error. But at the end I could create database and can use
the DB as normal.
-------
ERROR: incompatible library "/usr/lib/pgsql_clcrypt.so": missing magic
block
HINT: Extension libraries are required to use the PG_MODULE_MAGIC
macro.
STATEMENT: CREATE FUNCTION blowfish_encrypt(text, text) RETURNS text
AS '/usr/lib/pgsql_clcrypt.so', 'blowfish_encrypt'
LANGUAGE c;
...
-----------
This problem is coming with all the versions of PGSQL. We had a good
experience with similar error when we were upgraded with 7.4.2 long
back. Can you pls advice what to do to rectify this error in
Postgresql 8.2.5.
this does not look like a postgres bug to me.
Offhand, it looks like your database loads custom functions from the
shared object library /usr/lib/pgsql_clcrypt.so which was probably built
for your older 7.4... you'd either need to rebuild that library to be
8.2 compatible, or remove the CREATE FUNCTION statements that reference
it (and modify any SQL code you have which calls these
blowfish_encrypt() etc functions...)
DISCLAIMER:
This email may contain confidential or privileged information for the intended recipient(s) and the views expressed in the same are not necessarily the views of Zensar Technologies Ltd. If you are not the intended recipient or have received this e-mail by error, its use is strictly prohibited, please delete the e-mail and notify the sender. Zensar Technologies Ltd. does not accept any liability for virus infected mails.
Import Notes
Resolved by subject fallback
Suresh Gupta VG wrote:
As per your suggestion, if we remove "CREATE FUNCTION" statement, we
cannot use that function.
Add the PG_MODULE_MAGIC stuff to your code and recompile it. This is
mentioned in the documentation.
--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Suresh Gupta VG wrote:
Thanks for your reply.
As per your suggestion, if we remove “CREATE FUNCTION” statement, we
cannot use that function.Actually, we need this feature.
Can you pls suggest some url or docs to help us in developing the
c-language code to rectify this as we had done earlier for pgsql7.4.2.
http://www.postgresql.org/docs/current/static/xfunc-c.html
again, this isn't a postgres bug. you're posting this on the wrong list.