JNI_CreateJavaVM failing in PAM environment...

G

ggg_2006

I'm having problems with a call to JNI_CreateJavaVM within my shared
object that is loaded in the context of PAM. I made a C based PAM
driver that uses it for authentication. This failed to correctly start
up the VM until I altered the link options to include "-lthread"
and outputted the following message.

You must install a Solaris patch to run the native threads version of
the Java runtime. The green threads version will work without this
patch.Please check the native threads release notes for more
information.

If you are embedding the VM in a native application, please make sure
that the native application is linked with libthread.so (-lthread).


After I added the link option things worked just fine. When it
doesn't work as when SSH, RSH, telnet, ftp and so on load it, it
appears to hang or crash I can't tell but my logging stops at the
call to JNI_CreateJavaVM.

Now the problem, I can't naturally change the link options for ftp,
telnet, ssh, rsh and so on. How do I get the VM to instantiate?

This is for JRE 1.4.2_08 on Solaris.

I know that in earlier versions of the VM you could have it run using
green threads as opposed to native threading by passing "-green" to
the VM or setting an environment variable but they seem to be ignored
by JRE 1.4.2_08. I have installed all Solaris patches and have tried
it on both Solaris 2.7 and 2.9.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top