[GE users] DRMAA vs. Tomcat

Stefan Metzlaff stefan.metzlaff at gmx.de
Tue Apr 11 19:37:48 BST 2006


    [ The following text is in the "ISO-8859-1" character set. ]
    [ Your display is set for the "ISO-8859-10" character set.  ]
    [ Some special characters may be displayed incorrectly. ]

Thank you Daniel,

I've deleted the drmaa.jar from the web-inf/lib and used the common
classloader and the application seems to work.

Stefan

Daniel Templeton wrote:
> Here's an answer I got internally:
> 
>> JNI has no way to unload a shared library, so
>> a given library can only be loading once per VM.
>>
>> The workaround to this is to have a hierarchy
>> or class loaders just like we have in Sun AS/
>> GlassFish:
>> http://docs.sun.com/app/docs/doc/819-2556/6n4rap8pv?a=view#beadf
>>
>> There's also an old 'will not fix' bug:
>> http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4225434
>>
>> -Alexis
>>
> Daniel
> 
> 
> Stefan Metzlaff wrote On 04/10/06 23:20,:
> 
> Hi,
> 
> I'm developing a drmaa application which should run on the tomcat
> application server with axis. The web front end accesses the application
> through web services (wsdl).
> The application works pretty fine, if it is started from command line.
> But if I'm using the web services the following error occurs frequently:
> 
> java.lang.UnsatisfiedLinkError: Native Library
> /opt/SGE/lib/lx26-amd64/libdrmaa.so already loaded in another classloader
> java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1716)
> java.lang.ClassLoader.loadLibrary(ClassLoader.java:1676)
> java.lang.Runtime.loadLibrary0(Runtime.java:822)
> java.lang.System.loadLibrary(System.java:992)
> com.sun.grid.drmaa.SessionImpl$1.run(SessionImpl.java:58)
> java.security.AccessController.doPrivileged(Native Method)
> com.sun.grid.drmaa.SessionImpl.(SessionImpl.java:56)
> com.sun.grid.drmaa.SessionFactoryImpl.getSession(SessionFactoryImpl.java:59)
> cef.VirtualJob.startDRMAAJob(VirtualJob.java:591)
> cef.VirtualBlastJob.startJob(VirtualBlastJob.java:212)
> cef.ClusterMaster.startNewJob(ClusterMaster.java:91)
> cef.BlastAllWebService.startNewJob(BlastAllWebService.java:47)
> org.apache.jsp.sampleBlastAllWebService.Result_jsp._jspService(Result_jsp.java:81)
> org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> 
> After this error every other drmaa web service call results the
> following error:
> 
> java.lang.NoClassDefFoundError
> com.sun.grid.drmaa.SessionFactoryImpl.getSession(SessionFactoryImpl.java:59)
> cef.VirtualJob.startDRMAAJob(VirtualJob.java:591)
> cef.VirtualBlastJob.startJob(VirtualBlastJob.java:212)
> cef.ClusterMaster.startNewJob(ClusterMaster.java:91)
> cef.BlastAllWebService.startNewJob(BlastAllWebService.java:47)
> org.apache.jsp.sampleBlastAllWebService.Result_jsp._jspService(Result_jsp.java:81)
> org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> 
> After restarting the tomcat and the grid engine the application is
> working for some web service calls, until the UnsatisfiedLinkError occurs.
> 
> I'm using the following environment:
> Linux
> SGE 6.0u4
> 6.0u4 DRMAA.JAR
> jdk1.5.0_06
> Tomcat 5.5
> Axis 1.3
> 
> I think something is going wrong the the factory.getSession() call, but
> I dont't know why. All my sessions are closed (via session.exit()) on
> exit of the application. So there should be no conflict with the drmaa
> library.
> Is it possible that tomcat tries to load the libdrmaa.so more than once,
> if one user calls different methods of the web service or multiple users
> using the web services?
> 
> 
> Best regards
> Stefan Metzlaff
>>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at gridengine.sunsource.net
For additional commands, e-mail: users-help at gridengine.sunsource.net
>>

>>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at gridengine.sunsource.net
For additional commands, e-mail: users-help at gridengine.sunsource.net




More information about the gridengine-users mailing list