[Pljava-dev] [Fwd: Unable to load class org/postgresql/plsql/internal/Backend]

From: thhal at mailblocks(dot)com (Thomas Hallgren)
To:
Subject: [Pljava-dev] [Fwd: Unable to load class org/postgresql/plsql/internal/Backend]
Date: 2005-06-08 07:54:29
Message-ID: thhal-0uDyCA2N9zjYFsTeW4qhpwnTrEsoK7T@mailblocks.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pljava-dev

I seriously doubt that this has anything to do with Suns Java 1.5 since:

1. I've been using Suns Java 1.5 on all platforms (including amd64)
without problems.
2. The problem you encounter comes *after* the fact that the VM has
loaded successfully.

I'd check the CLASSPATH setting again. If you are using PostgreSQL 8.0.x
(or later) then I suggest you remove the CLASSPATH altogether and assert
that the following lines is in your postgresql.conf:

custom_variable_classes = 'pljava'
pljava.classpath = '<your absolute path to pljava.jar>'

If you still have problems, then verify that the pljava.jar is
accessible (check permissions on files and directories, the user who
owns your postmaster must be able to read) and verify that it isn't
corrupted.

Regards,
Thomas Hallgren

Michael Judd wrote:

>pljava placed my pljava.so.1.1 in /opt/pgsql/lib so I've used that
>instead of your /usr/lib64
>
>I still have the same issue. I have restarted - I'm running it in a
>shell at the moment and I've closed the shell to ensure that the
>environment is reset and the started up postgres again with:
>
>pg_ctl start -D /opt/pgsql/pg_data -l /var/log/pgsql.log -o "-i"
>
>The log file confirms this.
>
>The problem may well be as you suggest java 1.5
>
>I'll try blackdown as I'm on dual opterons (amd64 too) which is the
>reason I didn't go with java1.4 to start.
>
>Thanks again for you help.
>
>Mike
>
>On Tue, 2005-06-07 at 19:08 -0600, Vince Clark wrote:
>
>
>>Here is my dynamic_library_path in postgresql.conf
>>dynamic_library_path =
>>'/usr/lib64/:/home/java/j2sdk1.4.2/jre/lib/amd64/server/'
>>
>>Note that I am running an AMD64 so things will look slightly
>>different. The key in this line is that this path points to a
>>directory that contains a file called libjvm.so. In some JVM's I have
>>seen that file under jre/lib/client (rather than /server)
>>
>>Here is what my LD_LIBRARY_PATH looks like:
>>LD_LIBRARY_PATH=/usr/lib64/:/home/java/j2sdk1.4.2/jre/lib/amd64/server/ export LD_LIBRARY_PATH
>>
>>In my case the pljava build placed pljava.so.1.1 in /usr/lib64 and
>>created soft links with the proper file name of pljava.so
>>
>>Also, you may run into another problem once you get past the library
>>path issue. I was unable to install pljava using a 1.5.x JDK. I ended
>>up using Blackdown 1.4.2. It has something to do with being able to
>>spawn a VM from within Postgres. I don't remember exactly.
>>
>>Finally, I'm serious about restarting postgres. I did two
>>installations where the path settings were right but I had to restart
>>postgres before I could successfully add pljava as a language in the
>>database.
>>
>>Michael Judd wrote:
>>
>>
>>>Hi,
>>>
>>>At your recommendation I changed my LD_LIBRARY_PATH (via /etc/profile)
>>>to /usr/java/jdk1.5.0_03/jre/lib:/usr/java/jdk1.5.0_03/jre/lib/server:/usr/java/jdk1.5.0_03/jre/lib/native_threads:/opt/pgsql/lib
>>>This now matches my dynamic_library_path in postgresql.conf
>>>in /opt/pgsql/pg_data (or should I use this in my pljava.classpath ?
>>>
>>>I'm still getting exactly the same problem.
>>>
>>>Thanks for your help.
>>>
>>>
>>>
>>>On Tue, 2005-06-07 at 17:16 -0600, Vince Clark wrote:
>>>
>>>
>>>
>>>>Michael
>>>>
>>>>You said you were having trouble installing plsql. Do you mean pljava?
>>>>
>>>>Be sure you also have LD_LIBRARY_PATH set with the same values.
>>>>
>>>>Once the library path is established in both places (LD_LIBRARY_PATH)
>>>>and postgresql.conf) I found that restarting postgres before trying to
>>>>install pljava solved the problem.
>>>>
>>>>Michael Judd wrote:
>>>>
>>>>
>>>>
>>>>>____________________________________________________________________
>>>>>
>>>>>Subject: Unable to load class org/postgresql/plsql/internal/Backend
>>>>>From: Michael Judd <michael.judd at jaztek.co.uk>
>>>>>Date: Tue, 07 Jun 2005 23:46:25 +0100
>>>>>To: pljava-dev at gborg.postgresql.org
>>>>>To: pljava-dev at gborg.postgresql.org
>>>>>
>>>>>Hi,
>>>>>
>>>>>I'm having trouble installing plsql and I'm getting the following:
>>>>>
>>>>>Unable to load class org/postgresql/plsql/internal/Backend using
>>>>>CLASSPATH '-Djava.class.path=/opt/pgsql/pljava/build.pljava.jar'
>>>>>
>>>>>when issuing the command to pgsql:
>>>>>
>>>>>SELECT sqlj.install_jar('file://opt/pgsql/lib/sqlj.jar','sqlj',true);
>>>>>
>>>>>I have checked that:
>>>>>- pljava.jar is in /opt/pgsql/pljava/build
>>>>>- sqlj.jar is in /opt/pgsql/lib
>>>>>
>>>>>in my postgres.conf I have dynamic_library_path = '/opt/pgsql/lib:
>>>>>$libdir' where libpljava.so, plpgsql.so resides.
>>>>>
>>>>>my paths are:
>>>>> - postgres /opt/pgsql
>>>>> - pljava /opt/pgsql/pljava
>>>>> - data /opt/pgsql/pg_data
>>>>>
>>>>>Fedora Core 3 x86_64smp
>>>>>
>>>>>I've double checked that Backend is located in the jar exactly where it
>>>>>is supposed to be - so the error being displayed doesn't seem to point
>>>>>in the 'right' direction.
>>>>>
>>>>>Any ideas ?
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>____________________________________________________________________
>>>>>
>>>>>_______________________________________________
>>>>>Pljava-dev mailing list
>>>>>Pljava-dev at gborg.postgresql.org
>>>>>http://gborg.postgresql.org/mailman/listinfo/pljava-dev
>>>>>
>>>>>
>>>>>
>>>>>
>>>>--
>>>>Vince Clark
>>>>Global Era
>>>>The freedom of open source.
>>>>(303) 493-6723
>>>>(303) 455-2409 fax
>>>>vclark at globalera.com
>>>>www.globalera.com
>>>>
>>>>
>>>>
>>>
>>>
>>>
>>--
>>Vince Clark
>>Global Era
>>The freedom of open source.
>>(303) 493-6723
>>(303) 455-2409 fax
>>vclark at globalera.com
>>www.globalera.com
>>
>>
>
>
>_______________________________________________
>Pljava-dev mailing list
>Pljava-dev at gborg.postgresql.org
>http://gborg.postgresql.org/mailman/listinfo/pljava-dev
>
>

In response to

Browse pljava-dev by date

  From Date Subject
Next Message Michael Judd 2005-06-08 08:57:16 [Pljava-dev] VM initialization failure
Previous Message Michael Judd 2005-06-08 07:21:13 [Pljava-dev] Re: [Fwd: Unable to load class org/postgresql/plsql/internal/Backend]