Return-Path: Delivered-To: apmail-ws-axis-user-archive@www.apache.org Received: (qmail 27467 invoked from network); 26 Oct 2004 18:34:52 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 26 Oct 2004 18:34:52 -0000 Received: (qmail 85722 invoked by uid 500); 26 Oct 2004 18:34:26 -0000 Delivered-To: apmail-ws-axis-user-archive@ws.apache.org Received: (qmail 85626 invoked by uid 500); 26 Oct 2004 18:34:25 -0000 Mailing-List: contact axis-user-help@ws.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-user@ws.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list axis-user@ws.apache.org Received: (qmail 85549 invoked by uid 99); 26 Oct 2004 18:34:22 -0000 X-ASF-Spam-Status: No, hits=0.2 required=10.0 tests=DNS_FROM_RFC_ABUSE,NO_REAL_NAME X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from [199.228.142.104] (HELO plgmler4.imr.gm.com) (199.228.142.104) by apache.org (qpsmtpd/0.28) with ESMTP; Tue, 26 Oct 2004 11:34:18 -0700 Received: from plgmlir1.imr.gm.com (plgmlir1-2.imr.gm.com [199.228.142.169]) by plgmler4.imr.gm.com (8.12.10/8.12.10) with ESMTP id i9QIY5CU005743 for ; Tue, 26 Oct 2004 14:34:11 -0400 Received: from plgmlir1.imr.gm.com (localhost [127.0.0.1]) by plgmlir1.imr.gm.com (8.12.10/8.12.10) with ESMTP id i9QIXVPG006431 for ; Tue, 26 Oct 2004 13:33:32 -0500 Received: from usabhmg02.mail.gm.com (USABHMG02.mail.gm.com [164.56.166.171]) by plgmlir1.imr.gm.com (8.12.10/8.12.10) with ESMTP id i9QIXVeh006417 for ; Tue, 26 Oct 2004 13:33:31 -0500 Subject: Re: Having difficulty using native libraries (Tomcat and SHLIB) To: axis-user@ws.apache.org X-Mailer: Lotus Notes Release 5.0.11 July 24, 2002 Message-ID: From: charles.rosa@gm.com Date: Tue, 26 Oct 2004 14:33:29 -0400 X-MIMETrack: Serialize by Router on USABHMG02/G/GMSERVER/GMC(Release 5.0.11GM5 |January 20, 2004) at 10/26/2004 02:33:31 PM MIME-Version: 1.0 Content-type: text/plain; charset=us-ascii X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N ------------------------- Charles H. Rosa, Ph.D. Staff Research Engineer General Motors Corporation R&D and Planning Mail Code 480-106-359 30500 Mound Rd Warren, MI 48090-9055 Tel/work/cell: +1 248 670-8389 Fax/work: +1 586 986-0574 Email: charles.rosa@gm.com ----- Forwarded by Charles H Rosa/US/GM/GMC on 10/26/2004 02:33 PM ----- Charles H Rosa To: axis-user@ws.apache.org 10/26/2004 01:33 cc: PM Subject: Re: Having difficulty using native libraries (Tomcat and SHLIB) ------------------------- Charles H. Rosa, Ph.D. Staff Research Engineer General Motors Corporation R&D and Planning Mail Code 480-106-359 30500 Mound Rd Warren, MI 48090-9055 Tel/work/cell: +1 248 670-8389 Fax/work: +1 586 986-0574 Email: charles.rosa@gm.com ----- Forwarded by Charles H Rosa/US/GM/GMC on 10/26/2004 01:33 PM ----- Charles H Rosa To: noah.fiedel@jeppesen.com 10/26/2004 01:32 cc: PM Subject: Re: Having difficulty using native libraries (Tomcat and SHLIB)(Document link: Charles H Rosa) Noah, I'm fairly new to Tomcat. Can you clarify for me where the tomcat-startup shell script is located? Is this the file called: startup.sh found in /home/or/bzmclr/tomcat-jwsdp-1.4/bin where /home/or/bzmclr/tomcat-jwsdp-1.4/ is the home directory for tomcat on my machine. Also, if I do put a line into this file that points to the location of the binary (which in my case is equal to: /export/rainier/cplex90/bin/ultrasparc32_8_6.2 ) will this overwrite some other locations that are part of SHLIB_PATH by default. In particular, how do I add /export/rainier/cplex90/bin/ultrasparc32_8_6.2 to SHLIB_PATH without overwriting what's in SHLIB_PATH by default? Thanks for the clarification. Best regards, Charlie ------------------------- Charles H. Rosa, Ph.D. Staff Research Engineer General Motors Corporation R&D and Planning Mail Code 480-106-359 30500 Mound Rd Warren, MI 48090-9055 Tel/work/cell: +1 248 670-8389 Fax/work: +1 586 986-0574 Email: charles.rosa@gm.com noah.fiedel@jeppe sen.com To: axis-user@ws.apache.org cc: 10/22/2004 02:07 Subject: Re: Having difficulty using native libraries (Tomcat and SHLIB) PM Please respond to axis-user Hi, I had a similar issue on an HP-UX server recently. The solution was to make sure that the SHLIB environment variable is set in the shell/environment that runs your java process. In my tomcat-startup shell script, I added the line: export SHLIB_PATH=$CATALINA_HOME/lib/ In this case, $CATALINA_HOME was my tomcat home directory, and the library file was in the lib subdirectory. Hope this helps, Noah charles.rosa@gm.co m To axis-user@ws.apache.org 10/22/2004 10:36 cc AM Subject Re: Having difficulty using native libraries Please respond to within Web Service running on Axis axis-user@ws.apac he.org - I am trying to create a web service (that runs on a Sun Unix workstation) that includes an optimization library called CPLEX. I have added the jar file: cplex.jar to the directory: /home/or/bzmclr/tomcat-jwsdp-1.4/webapps/axis/WEB-INF/lib I found that I had to do this even though I set my CLASSPATH to include the location of cplex.jar (which was originally stored somewhere else). Now, I'm having trouble because Axis can't seem to find the location of the CPLEX binaries This is inspite of the fact that I added the location of the CPLEX Unix binaries to the path. In particular, PATH=/usr/local/bin:/common/site/scripts/midrange:/apps/lsf_appl/bin:/apps/lsf_d ata:/apps/local/bin:/apps/local/bin/SunOS/5:/usr/openwin/bin:/usr/sbin:/apps/fra me/bin:/usr/local/bin:/bin:/usr/bin:/usr/dt/bin:/usr/ucb:/usr/bsd:/usr/bin/X11:/ common/ce/scripts:/apps/tex/bin/sparc-sun-solaris2.8:/home/or/bzmclr:/home/or/bz mclr/bin:.:/usr/openwin/bin:/export/rainier/cplex90/bin/ultrasparc32_8_6.2 and the CPLEX binary is contained in the subdirectory /export/rainier/cplex90/bin/ultrasparc32_8_6.2 Still, I get the message: java.lang.UnsatisfiedLinkError: no cplex90 in java.library.path java.library.path must point to the directory containing the CPLEX shared librar y try invoking java with java -Djava.library.path=... ModelGenerator::solveModelViaIterativeAlgorithm() - java.lang.UnsatisfiedLinkErr or: CPXopenCPLEX java.lang.Exception: ModelGenerator::solveModelViaIterativeAlgorithm() - java.la ng.UnsatisfiedLinkError: CPXopenCPLEX at portfoliooptimization_webservice.ModelGenerator.solveModelViaIterativ eAlgorithm(ModelGenerator.java:1829) at portfoliooptimization_webservice.ModelGenerator_wrapper.solveModelVia IterativeAlgorithm(ModelGenerator_wrapper.java:1597) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.j ava:402) Also, before the java.lang.UnsatisfiedLinkError is thrown, when I print out System.err.println(AxisProperties.getProperty("java.library.path")); I see: /usr/j2se/jre/lib/sparc/client:/usr/j2se/jre/lib/sparc:/usr/j2se/jre/../lib/spar c:/usr/lib which, as you can see, doesn't include: /export/rainier/cplex90/bin/ultrasparc32_8_6.2 So, even though I have added the directory that contains the necessary binaries to the path, once inside the web service, axis seems to overwrite the path to include only: /usr/j2se/jre/lib/sparc/client:/usr/j2se/jre/lib/sparc:/usr/j2se/jre/../lib/spar c:/usr/lib If anyone has any thoughs on how to get Axis to correctly read in the path so that it knows where to search for the binaries, I would be much obliged. Thanks, Charlie ------------------------- Charles H. Rosa, Ph.D. Staff Research Engineer General Motors Corporation R&D and Planning Mail Code 480-106-359 30500 Mound Rd Warren, MI 48090-9055 Tel/work/cell: +1 248 670-8389 Fax/work: +1 586 986-0574 Email: charles.rosa@gm.com