Re: Tomcat 8.0.9 native library not found
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Mark, On 8/20/14, 12:28 PM, Mark Eggers wrote: On 8/20/2014 8:35 AM, Neil Aggarwal wrote: Mark: CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib I already have this in my startup script: CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib -Djava.awt.headless=true -Xmx2048m And the log has this: INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: / usr/local/apr/lib I think /usr/local/apr/lib is already in the java.library.path variable. Thanks, Neil Neil, The ld.so.conf.d information I gave is completely wrong it seems. Java doesn't appear to respect ld.so.conf.d configuration files, because when I placed the apr.conf in that directory and ran ldconfig, I got the following: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/java /packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib I'm not ld master, but I think you might need to reboot in order for changes to ld.conf and friends to change anything. However, adding the following line to setenv.sh worked. CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib Loaded APR based Apache Tomcat Native library 1.1.31 using APR version 1.5.1. I'm running the following environment: Fedora 20 64 bit latest updates apr-util-1.5.3-1.fc20.x86_64 apr-util-devel-1.5.3-1.fc20.x86_64 apr-devel-1.5.1-1.fc20.x86_64 apr-util-ldap-1.5.3-1.fc20.x86_64 apr-1.5.1-1.fc20.x86_64 openssl-libs-1.0.1e-39.fc20.i686 openssl-1.0.1e-39.fc20.x86_64 openssl-libs-1.0.1e-39.fc20.x86_64 openssl-devel-1.0.1e-39.fc20.x86_64 Oracle JRE/JDK 1.7.0_67 64 bit Tomcat 8 built from source - revision 1619129 I built and installed the library with: ./configure --with-apr=/usr --with-ssl=/usr make make install About the only difference I see is that the configure command is different. In CentOS 6.5 I use the same configure command as I listed above. Does CentOS 7 change how APR is set up? I don't know since I've not installed CentOS 7 yet. Neil, It is certainly possible that loading libtcnative isn't the problem, but loading one of the dependent libraries is the problem. Given that you were able to build the library on the target machine (you built and ran on the same machine, right?), the chances that those support libraries (e.g. libssl, libcrypt, etc.) are not available is very low. Can you write a simple Java program that calls System.loadLibrary and see if you get better error messages? Tomcat might be hiding some error and masking the underlying error. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1 Comment: GPGTools - http://gpgtools.org iQIcBAEBCAAGBQJT9gpbAAoJEBzwKT+lPKRYWIAQAMu+qC+KTCXBGHRHBaF2tfMd ZDrrKWLIqDZdT/Pvc1ynhL9t22WAuavpC+A28yzXXP3zpYFiJ8QJv9KHpYYcrapI AYsb/5G9nYfor/C8YqeBYdvyBmck4XG9Z+Y7ILgLnjKjwev3df6DrNcQOu8SnMwj flcBQTNyXPoq0PMCjCAR8kOcPDKc0bEyul4L4la9VTKL38y7wT778Vuwf8LuG5EC 0LKCs9zxVx1u9Fox9y3I2sNpSUvXVXRwdPBnoKnksIk5Hv+kaDWG+BaVYX4VOoca xdHruv6pqAVCmRsuzPXYbUQCPCHOeLxgUb10wC6WLf0PUjZdpoxIxBYDQesoqXEt XyxNCW2ig9+3NwuZdKhC9xiVmfUyMgcYgFT3fq+68ncIZd/hUMm10Y6i9a5xaSzF JL90EwVws2nn9id2UUBaCDa0pa3e90Wuyb3VmqtN5/f9JcDbJzAHzGjhl0Qs43k5 JCYDYzRwWn9ZCUpR8YsxivJmKBY0juldKTgZKbxOZifDEDhDwwZ/h2k7WpBOgBt9 q0vv+86mzAnrdDQUS8QpKfIo0RHoTYAzGT0sreP9GwnGL70kc+GxBJAofINpTqTB AEy8FUrcFAFgmofelxt+YOAkHfzLJnYjeto013iaAaQKkg4/PkImXt+mTgGBaMAz Up/Fr7gDThLaJOgy3hIk =plEt -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat 8.0.9 native library not found
From: Christopher Schultz [mailto:ch...@christopherschultz.net] Subject: Re: Tomcat 8.0.9 native library not found I'm not ld master, but I think you might need to reboot in order for changes to ld.conf and friends to change anything. Just run the ldconfig utility (as root) to rebuild the cache. Normally without options, but -v might provide some pertinent information. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 8.0.9 native library not found
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 8/21/2014 8:10 AM, Caldarale, Charles R wrote: From: Christopher Schultz [mailto:ch...@christopherschultz.net] Subject: Re: Tomcat 8.0.9 native library not found I'm not ld master, but I think you might need to reboot in order for changes to ld.conf and friends to change anything. Just run the ldconfig utility (as root) to rebuild the cache. Normally without options, but -v might provide some pertinent information. - Chuck Chuck, I probably should have run it with the -v option, but catalina.out didn't list all of the paths specified in the files in /etc/ld.so.conf.d. Neil, I didn't notice --with-ssl=/usr in your configuration. Here's the gory details of what I just did: My quick and dirty CentOS 7 system: 3.10.0-123.6.3.el7.x86_64#1 SMP Wed Aug 6 21:12:36 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux apr-devel-1.4.8-3.el7.x86_64 apr-1.4.8-3.el7.x86_64 apr-util-1.5.2-6.el7.x86_64 apr-util-devel-1.5.2-6.el7.x86_64 openssl-1.0.1e-34.el7_0.4.x86_64 openssl-devel-1.0.1e-34.el7_0.4.x86_64 openssl-libs-1.0.1e-34.el7_0.4.x86_64 openssl098e-0.9.8e-29.el7.centos.2.x86_64 Java / JRE Oracle 1.7.0_67 64 bit Ant 1.8.1 Tomcat 8 from SVN Revision: 1619129 Steps to install Tomcat native: 1. ant (to build Tomcat) 2. cd output/build/bin 3. tar xvfz tomcat-native.tar.gz 4. cd tomcat-native-1.1.31-src/jni/native/ 5. ./configure --with-apr=/usr --with-ssl=/usr 6. make 7. make install (as root) 8. Create apr.conf in /etc/ld.so.conf.d with the following content /usr/local/apr/lib 9. ldconfig -v (partial output below) libtcnative-1.so.0 - libtcnative-1.so.0.1.31 libssl.so.6 - libssl.so.0.9.8e libevent_openssl-2.0.so.5 - libevent_openssl-2.0.so.5.1.9 libssl3.so - libssl3.so libssl.so.10 - libssl.so.1.0.1e libgstdataprotocol-0.10.so.0 - libgstdataprotocol-0.10.so.0.30.0 libaprutil-1.so.0 - libaprutil-1.so.0.5.2 libapr-1.so.0 - libapr-1.so.0.4.8 libgnutls-xssl.so.0 - libgnutls-xssl.so.0.0.0 This is catalina.out without setenv.sh: 21-Aug-2014 08:36:50.460 INFO [main] org.apache.catalina.core.AprLifecycleListener.init The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/java /packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib The following setenv.sh was created: CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib This is catalina.out with the above setenv.sh: 21-Aug-2014 08:44:23.168 INFO [main] org.apache.catalina.core.AprLifecycleListener.init Loaded APR based Apache Tomcat Native library 1.1.31 using APR version 1.4.8. 21-Aug-2014 08:44:23.180 INFO [main] org.apache.catalina.core.AprLifecycleListener.init APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true]. I noticed that you did not include --with-ssl=/usr in your last mail message. Do you have the openssl development libraries installed? . . . just my (rather long) 2 cents /mde/ -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.13 (MingW32) iQEcBAEBAgAGBQJT9hfVAAoJEEFGbsYNeTwtzzcH/3JgjkNcMUzBLBKrJejAyjfg xPHmq37UzJv9sjNN3I4FDjgIduwJrzSMEDEUJyMh4MFm0RuEFmgFSkYgsjmSRdsY VvW4hQYy6Qb98jyr7FB+K9GtQ0M0cEbd2JApgyOSniB45uJkI+0b+6qUxM6VO4qV oXG37Xp0HfRVeHmTzlFQW8yRSbGTM6uNfdNbM8nXQi6RyfI/83+QVAqx0BWJBUfQ S7VxcG7WG+J1Mw7WTUhXAX0FCgLZ34jxHqqOkuyFWSt/8cQTeDABcO4dP8hZYOd9 2LNG4+PF9QjdqlL0YnfT2czC9SaewDxzUl0boMfnJh/pgF221fZyn+ALk01o7Ok= =MbrH -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 8.0.9 native library not found
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Mark, On 8/21/14, 12:01 PM, Mark Eggers wrote: On 8/21/2014 8:10 AM, Caldarale, Charles R wrote: From: Christopher Schultz [mailto:ch...@christopherschultz.net] Subject: Re: Tomcat 8.0.9 native library not found I'm not ld master, but I think you might need to reboot in order for changes to ld.conf and friends to change anything. Just run the ldconfig utility (as root) to rebuild the cache. Normally without options, but -v might provide some pertinent information. - Chuck Chuck, I probably should have run it with the -v option, but catalina.out didn't list all of the paths specified in the files in /etc/ld.so.conf.d. Neil, I didn't notice --with-ssl=/usr in your configuration. Here's the gory details of what I just did: My quick and dirty CentOS 7 system: 3.10.0-123.6.3.el7.x86_64#1 SMP Wed Aug 6 21:12:36 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux apr-devel-1.4.8-3.el7.x86_64 apr-1.4.8-3.el7.x86_64 apr-util-1.5.2-6.el7.x86_64 apr-util-devel-1.5.2-6.el7.x86_64 openssl-1.0.1e-34.el7_0.4.x86_64 openssl-devel-1.0.1e-34.el7_0.4.x86_64 openssl-libs-1.0.1e-34.el7_0.4.x86_64 openssl098e-0.9.8e-29.el7.centos.2.x86_64 Java / JRE Oracle 1.7.0_67 64 bit Ant 1.8.1 Tomcat 8 from SVN Revision: 1619129 Steps to install Tomcat native: 1. ant (to build Tomcat) 2. cd output/build/bin 3. tar xvfz tomcat-native.tar.gz 4. cd tomcat-native-1.1.31-src/jni/native/ 5. ./configure --with-apr=/usr --with-ssl=/usr 6. make 7. make install (as root) 8. Create apr.conf in /etc/ld.so.conf.d with the following content /usr/local/apr/lib I really wouldn't recommend messing-around with ld.so.conf. There's no reason not to use -Djava.library.path. 9. ldconfig -v (partial output below) libtcnative-1.so.0 - libtcnative-1.so.0.1.31 libssl.so.6 - libssl.so.0.9.8e libevent_openssl-2.0.so.5 - libevent_openssl-2.0.so.5.1.9 libssl3.so - libssl3.so libssl.so.10 - libssl.so.1.0.1e libgstdataprotocol-0.10.so.0 - libgstdataprotocol-0.10.so.0.30.0 libaprutil-1.so.0 - libaprutil-1.so.0.5.2 libapr-1.so.0 - libapr-1.so.0.4.8 libgnutls-xssl.so.0 - libgnutls-xssl.so.0.0.0 This is catalina.out without setenv.sh: 21-Aug-2014 08:36:50.460 INFO [main] org.apache.catalina.core.AprLifecycleListener.init The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/java /packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib The following setenv.sh was created: CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib This is catalina.out with the above setenv.sh: 21-Aug-2014 08:44:23.168 INFO [main] org.apache.catalina.core.AprLifecycleListener.init Loaded APR based Apache Tomcat Native library 1.1.31 using APR version 1.4.8. 21-Aug-2014 08:44:23.180 INFO [main] org.apache.catalina.core.AprLifecycleListener.init APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true]. I noticed that you did not include --with-ssl=/usr in your last mail message. Do you have the openssl development libraries installed? I wonder if the JVM requires that you have java.library.path set to where your initial libraries are loaded to protect processes against a class of security problems. If all of ld.so.conf were available, evil Java classes could try to load arbitrary libraries from /usr/lib that are known to have certain vulnerabilities and exploit them. Reducing the attack surface can make the JVM a safer place to live... - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1 Comment: GPGTools - http://gpgtools.org iQIcBAEBCAAGBQJT9ki4AAoJEBzwKT+lPKRYwyIP/2dU+FH8khya6Px98YLVP/o3 1rVL+/yc0c+kv4Z4lOpFpW1uzzJfV+fvoUrTeBgVRTXFPDdi+MmD5u7H8jaQdbBR U1PhhbFUq7vbdCIMvUZ0YhzQY5kTs8GOUQ6uGJAoHGhTMc59dhsXY41fG4SEjgC1 zf9sZB5fGgvSnmm3tTU9L54WXC5YbMiiZRRd2HqamLZMVnyVvv43zaUO5243QUfo h7+U1QeEn5+SBxu5kaOzx86Lpq8soRgEVVrvRgIW7MziWfZ4HKmef3v9oPZ+ZUiP hrz326EOnehkz3ZcWZTPG6+MRs2F72jOKo9LAiK+ByxZc77FQ9hVar3gfKhARcO6 OsjgsNIF6w4g0zNOApFJ0SyK0DuK/MU00fgGUEXfgD5W3pw3qunuZX2kbf0uUI71 xNiBS8qknOzD3g4liBsYufo9HarrAajhK4Mp666b4AxSZ0LWf4ZxTqRLZGq9Z26w f/k84wXrKHgLD7iAUTeGC8KpX0+XHnp/oRVzZjJeYyMnUNuGhZ1rei5fM3xsVPX0 mfdzig7Nn6ymU6ndtcvynOMgwZ97uyv9+ZsucoVs7hgSGcRzI54Yy8YIHbYXQu70 NEUUhCryskjko5Me67tUbUHJcZbo7YfdfWzmOWPlOTEG9Gp8pQiahLJCEkMOkBq9 r6Nhe+K25sJOsi9RlJZo =YUTy -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat 8.0.9 native library not found
Mark: CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib I already have this in my startup script: CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib -Djava.awt.headless=true -Xmx2048m And the log has this: INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: / usr/local/apr/lib I think /usr/local/apr/lib is already in the java.library.path variable. Thanks, Neil -- Neil Aggarwal, (972) 834-1565 We lend money to investors to buy or refinance single family rent houses. No origination fees, quick approval, no credit check. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 8.0.9 native library not found
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 8/20/2014 8:35 AM, Neil Aggarwal wrote: Mark: CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib I already have this in my startup script: CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib -Djava.awt.headless=true -Xmx2048m And the log has this: INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: / usr/local/apr/lib I think /usr/local/apr/lib is already in the java.library.path variable. Thanks, Neil Neil, The ld.so.conf.d information I gave is completely wrong it seems. Java doesn't appear to respect ld.so.conf.d configuration files, because when I placed the apr.conf in that directory and ran ldconfig, I got the following: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/java /packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib However, adding the following line to setenv.sh worked. CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib Loaded APR based Apache Tomcat Native library 1.1.31 using APR version 1.5.1. I'm running the following environment: Fedora 20 64 bit latest updates apr-util-1.5.3-1.fc20.x86_64 apr-util-devel-1.5.3-1.fc20.x86_64 apr-devel-1.5.1-1.fc20.x86_64 apr-util-ldap-1.5.3-1.fc20.x86_64 apr-1.5.1-1.fc20.x86_64 openssl-libs-1.0.1e-39.fc20.i686 openssl-1.0.1e-39.fc20.x86_64 openssl-libs-1.0.1e-39.fc20.x86_64 openssl-devel-1.0.1e-39.fc20.x86_64 Oracle JRE/JDK 1.7.0_67 64 bit Tomcat 8 built from source - revision 1619129 I built and installed the library with: ./configure --with-apr=/usr --with-ssl=/usr make make install About the only difference I see is that the configure command is different. In CentOS 6.5 I use the same configure command as I listed above. Does CentOS 7 change how APR is set up? I don't know since I've not installed CentOS 7 yet. . . . just my two cents /mde/ -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.13 (MingW32) iQEcBAEBAgAGBQJT9My1AAoJEEFGbsYNeTwtXjAH/3rsdil3Oz+Wcu8FQI5fvMG0 R0VeFGJkV6JMVOomQ9FixEo8TX9Tvm0i6ks6TgCbc+AFOCzm1dbek3qXodldfMWi t61m42+a5p8swxz/zpnK9l48Z3g3rMyFx1VuHS9i0kLbSF6imXsFy8Kr22OyIG4B KT7UdeqLAv5oJchYbklAmJZs+sqzsFXFRZp50rYYK1SRAMOIYIjx7Vt/uRZlodZa NbdwuVCnvEfgeT1y3VLpHNi9nU0xrajaGe4/d/itnvVjzD00dUPWbfgy5miANa6h 5VwsznyPDlmDCLO3IG/fsQUbOWngLrFt62vOruJQysb3aGCDOu61k66jtS3WWAM= =pzW8 -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat 8.0.9 native library not found
Mark: About the only difference I see is that the configure command is different I tried deleting the tcnative files in /usr/local/apr/lib and the tomcat native source directory. I untarred it again and ran these commands: ./configure --with-apr=/usr --with-java-home=/usr/lib/jvm/java-1.7.0-openjdk make make install Everything seemed to build fine, but I still get the warning about the native library not being found when I start Tomcat so it seems the configure command difference is not the problem. Does CentOS 7 change how APR is set up? It does not seem like it changed but who knows. There have been many changes to the system when they went from v6 to v7, maybe they broke something. Thanks, Neil -- Neil Aggarwal, (972) 834-1565 We lend money to investors to buy or refinance single family rent houses. No origination fees, quick approval, no credit check. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 8.0.9 native library not found
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Carl, On 8/17/14, 7:18 PM, carl hansen wrote: I can do /usr/bin/apr-1-config and I get the usage page for APR. I assume that means it is there. Don't assume. Your command lines said is was in /usr/lib/apr Is it in /usr/lib/apr? from what you said above, it isn't. I suggest you get APR from http://apr.apache.org/ and reinstall it. When I did, it went in /usr/lib/apr/ which is convenient Downloading and building libapr yourself usually isn't necessary: the local package manager will do just fine. Neil, what output does this produce? $ ldd /usr/local/apr/lib/libtcnative-1.so Also: $ echo $LD_LIBRARY_PATH - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1 Comment: GPGTools - http://gpgtools.org iQIcBAEBCAAGBQJT810DAAoJEBzwKT+lPKRYdKYP/iNVenBYIXyLGfAhhkbIEncT i8zr100knzxZeR2FNVBFQl9YVa8/SjPKDRU3iztPkkcDGbAf7EWAZXhvTid9fork dolcdDZn600O5VoQpN+7d/y27Px/FJvh8bNb3UYP96w9ts5iyW1kvoXRRlYgvm5C 4lfsISM/NC/9IiSlHL/jNYJvhzEvE2mn/s6DWVDcetTMIccMH08k309HbiVQvAQs NYeTZ69Gdd1qgOu9HVHk8oistBcY1VPJP5gteFe7KnSRIGxdq8rmGhhjegHApk/l qBI7copbV1jP7JbWL7pswD00xO+IKRrKt77TKTSdOHNMEcqUuO8/SrkNTXRTIThU NN7md+tLkY3XHMyWya6feMueOmWUB8J8h1pYCeU403MxC6uP1YC8oCdWGVVmFxAW zToaowq7LnuISq2YhxmMnhZP/jSeJrgthPdJgDuMql5iHxO5Kt5ligTaTqkfvGN+ X2Ob5I1rWdfJOqvHmmzb7EVuPuOxubYuxJ4FYSLOP1rJebFcKP+DCdxRNm+HVCHh AyP7hMznt+9nuE04n6j7SRrKI2V/5csdowq7R2A5nS5QgDQS6eSBT4bfmfE3kreA YKJ+enT0RBFWCHiXSU9t9lEZMk0RPClCii3KC9hFuOLVDgfcZkph7bns8AePMz19 +EmuzdKLWsWw3usIHqXZ =JEFk -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat 8.0.9 native library not found
Christopher: ldd /usr/local/apr/lib/libtcnative-1.so linux-vdso.so.1 = (0x7fff145fe000) libssl.so.10 = /lib64/libssl.so.10 (0x7f5642498000) libcrypto.so.10 = /lib64/libcrypto.so.10 (0x7f56420b3000) libapr-1.so.0 = /lib64/libapr-1.so.0 (0x7f5641e83000) libpthread.so.0 = /lib64/libpthread.so.0 (0x7f5641c67000) libdl.so.2 = /lib64/libdl.so.2 (0x7f5641a63000) libc.so.6 = /lib64/libc.so.6 (0x7f56416a1000) libgssapi_krb5.so.2 = /lib64/libgssapi_krb5.so.2 (0x7f5641457000) libkrb5.so.3 = /lib64/libkrb5.so.3 (0x7f5641177000) libcom_err.so.2 = /lib64/libcom_err.so.2 (0x7f5640f72000) libk5crypto.so.3 = /lib64/libk5crypto.so.3 (0x7f5640d3d000) libz.so.1 = /lib64/libz.so.1 (0x7f5640b27000) libuuid.so.1 = /lib64/libuuid.so.1 (0x7f5640921000) libcrypt.so.1 = /lib64/libcrypt.so.1 (0x7f56406ea000) /lib64/ld-linux-x86-64.so.2 (0x7f5642932000) libkrb5support.so.0 = /lib64/libkrb5support.so.0 (0x7f56404dc000) libkeyutils.so.1 = /lib64/libkeyutils.so.1 (0x7f56402d7000) libresolv.so.2 = /lib64/libresolv.so.2 (0x7f56400bd000) libfreebl3.so = /lib64/libfreebl3.so (0x7f563fe3d000) libselinux.so.1 = /lib64/libselinux.so.1 (0x7f563fc18000) libpcre.so.1 = /lib64/libpcre.so.1 (0x7f563f9b7000) liblzma.so.5 = /lib64/liblzma.so.5 (0x7f563f791000) echo $LD_LIBRARY_PATH This gives me nothing back. Thanks, Neil -- Neil Aggarwal, (972) 834-1565 We lend money to investors to buy or refinance single family rent houses. No origination fees, quick approval, no credit check. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 8.0.9 native library not found
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Neil, On 8/19/14, 11:53 AM, Neil Aggarwal wrote: Christopher: ldd /usr/local/apr/lib/libtcnative-1.so linux-vdso.so.1 = (0x7fff145fe000) libssl.so.10 = /lib64/libssl.so.10 (0x7f5642498000) libcrypto.so.10 = /lib64/libcrypto.so.10 (0x7f56420b3000) libapr-1.so.0 = /lib64/libapr-1.so.0 (0x7f5641e83000) libpthread.so.0 = /lib64/libpthread.so.0 (0x7f5641c67000) libdl.so.2 = /lib64/libdl.so.2 (0x7f5641a63000) libc.so.6 = /lib64/libc.so.6 (0x7f56416a1000) libgssapi_krb5.so.2 = /lib64/libgssapi_krb5.so.2 (0x7f5641457000) libkrb5.so.3 = /lib64/libkrb5.so.3 (0x7f5641177000) libcom_err.so.2 = /lib64/libcom_err.so.2 (0x7f5640f72000) libk5crypto.so.3 = /lib64/libk5crypto.so.3 (0x7f5640d3d000) libz.so.1 = /lib64/libz.so.1 (0x7f5640b27000) libuuid.so.1 = /lib64/libuuid.so.1 (0x7f5640921000) libcrypt.so.1 = /lib64/libcrypt.so.1 (0x7f56406ea000) /lib64/ld-linux-x86-64.so.2 (0x7f5642932000) libkrb5support.so.0 = /lib64/libkrb5support.so.0 (0x7f56404dc000) libkeyutils.so.1 = /lib64/libkeyutils.so.1 (0x7f56402d7000) libresolv.so.2 = /lib64/libresolv.so.2 (0x7f56400bd000) libfreebl3.so = /lib64/libfreebl3.so (0x7f563fe3d000) libselinux.so.1 = /lib64/libselinux.so.1 (0x7f563fc18000) libpcre.so.1 = /lib64/libpcre.so.1 (0x7f563f9b7000) liblzma.so.5 = /lib64/liblzma.so.5 (0x7f563f791000) echo $LD_LIBRARY_PATH This gives me nothing back. Okay. That all looks good to me. Typically, ld looks in LD_LIBRARY_PATH if it is set (which it shouldn't be under normal circumstances) otherwise it looks in a set of default locations that you can find in /etc/ld.so.conf and friends. java.library.path just specifies the place where libraries that aren't already in the ld path can be loaded. Everything above looks like it would be in the default ld path, so all you need is the path to tcnative, which you've already provided to the JVM. Do the tcnative*.so files have the execute bit set? Also, to check the architecture of the binary, use file: $ file /usr/local/apr/lib/libtcnative-1.so On my system, I get this from my just-built 1.1.31: $ file libtcnative-1.so libtcnative-1.so: symbolic link to `libtcnative-1.so.0.1.31' $ file libtcnative-1.so.0.1.31 libtcnative-1.so.0.1.31: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=0x2c5c19e96e4f39a4433a0dabdb82175bf1305f70, not stripped All users should have read and execute privileges on the file itself, plus the Tomcat user requires execute privileges on every directory between / and /usr/local/apr/lib. You might also need Tomcat to have read privileges on those directories as well, depending upon how the JVM does its library-searching. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1 Comment: GPGTools - http://gpgtools.org iQIcBAEBCAAGBQJT84p+AAoJEBzwKT+lPKRYXNYQALlo20BREOsP9wUWy5b247sw cVmpzb3p9cjiyO8BzUCPQWUSlix5QDo61tfyuBl1z27ouBnu2gv8TItkN8sY2vB0 2NmQVW9+Al4HIKTiZA+TccB+maygyWzXkDDrwLTMgHYtYX0rqE+qZ3sgMdkf7vyg BG8YCbIPh5tc+TrxFdZ/lLd+yxMaLiGUBLskuecHiM+T+96YspKjfm637e6itlCN m95ejWQryiu13jZ3fMaFj1fWOljqhvdqTBtHb4gCMrqIMrpjh9GKMEqsTvVWj4ms dm4mxXMPASgpgRRVubBLmlq2Wt7UbqusxZV7fYU9tv6IrRL6NwD1M3ONda7lhhAH Vy2ZD5n/sVMoq+QEfpw6Lt/WWmJeTmUYfqUvUlX+PCX3UhaGpjh++fKxnOKm/GRe o4SqYHvasPqSmZ6L3eeixIsSbvVjIvZUDUCk68GTP7qFT0j4j6UcD6XwtWZeQhGO 0y7b5j2zvVhb+nBPgTNwYctOYgpgwzF05FfBFLASvpJYX8vbZHHtgB+4HlixDvEl 0IklrUeJwCRe7wgtGkz4DmPtGZh3iChJw2VD+BvMnHbcOpcxMjwB8xsFoWCb4QH9 p3RKvEvGL+BJ+1EBL5N+6nJZYPD/IuZIm9Ba28feluN0+fimcDfPZhZFXObjnztl fnHur/IC7/2JMz1My0rC =Ye8e -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat 8.0.9 native library not found
Christopher: Do the tcnative*.so files have the execute bit set? Doing a ls -lah gives me this: -rw-r--r-- 1 root root 1.7M Aug 17 08:57 libtcnative-1.a -rwxr-xr-x 1 root root 1.1K Aug 17 08:57 libtcnative-1.la lrwxrwxrwx 1 root root 23 Aug 17 08:57 libtcnative-1.so - libtcnative-1.so.0.1.31 lrwxrwxrwx 1 root root 23 Aug 17 08:57 libtcnative-1.so.0 - libtcnative-1.so.0.1.31 -rwxr-xr-x 1 root root 713K Aug 16 23:02 libtcnative-1.so.0.1.30 -rwxr-xr-x 1 root root 980K Aug 17 08:57 libtcnative-1.so.0.1.31 drwxr-xr-x 2 root root 26 Aug 17 14:56 pkgconfig It seems like the execute bits are set. file /usr/local/apr/lib/libtcnative-1.so That gives me: /usr/local/apr/lib/libtcnative-1.so: symbolic link to `libtcnative-1.so.0.1.31' file /usr/local/apr/lib/libtcnative-1.so.0.1.31 gives me: /usr/local/apr/lib/libtcnative-1.so.0.1.31: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=0x56885899f70761 f7a250dbc6560a69131dc9e950, not stripped All users should have read and execute privileges on the file itself The file is world read and execute, so that should be OK. Tomcat user requires execute privileges on every directory between / and /usr/local/apr/lib. You might also need Tomcat to have read privileges on those directories I just checked /, /usr, /usr/local, /usr/local/apr, and /usr/local/apr/lib and they are all world read and execute bits set. Any other ideas? Thanks, Neil -- Neil Aggarwal, (972) 834-1565 We lend money to investors to buy or refinance single family rent houses. No origination fees, quick approval, no credit check. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 8.0.9 native library not found
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 8/19/2014 3:19 PM, Neil Aggarwal wrote: Christopher: Do the tcnative*.so files have the execute bit set? Doing a ls -lah gives me this: -rw-r--r-- 1 root root 1.7M Aug 17 08:57 libtcnative-1.a -rwxr-xr-x 1 root root 1.1K Aug 17 08:57 libtcnative-1.la lrwxrwxrwx 1 root root 23 Aug 17 08:57 libtcnative-1.so - libtcnative-1.so.0.1.31 lrwxrwxrwx 1 root root 23 Aug 17 08:57 libtcnative-1.so.0 - libtcnative-1.so.0.1.31 -rwxr-xr-x 1 root root 713K Aug 16 23:02 libtcnative-1.so.0.1.30 -rwxr-xr-x 1 root root 980K Aug 17 08:57 libtcnative-1.so.0.1.31 drwxr-xr-x 2 root root 26 Aug 17 14:56 pkgconfig It seems like the execute bits are set. file /usr/local/apr/lib/libtcnative-1.so That gives me: /usr/local/apr/lib/libtcnative-1.so: symbolic link to `libtcnative-1.so.0.1.31' file /usr/local/apr/lib/libtcnative-1.so.0.1.31 gives me: /usr/local/apr/lib/libtcnative-1.so.0.1.31: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=0x56885899f70761 f7a250dbc6560a69131dc9e950, not stripped All users should have read and execute privileges on the file itself The file is world read and execute, so that should be OK. Tomcat user requires execute privileges on every directory between / and /usr/local/apr/lib. You might also need Tomcat to have read privileges on those directories I just checked /, /usr, /usr/local, /usr/local/apr, and /usr/local/apr/lib and they are all world read and execute bits set. Any other ideas? Thanks, Neil -- Neil Aggarwal, (972) 834-1565 We lend money to investors to buy or refinance single family rent houses. No origination fees, quick approval, no credit check. Neil, I don't have CentOS 7 installed yet (on my list of things to do), but in CentOS 6.5, there are places where ld.so.cache gets built from. It's configured by the files in /etc/ld.so.conf.d/. Each directory gets its own configuration file ending in a .conf. The file contains the directory to cache. For example, to include /usr/local/apr/lib in ld.so.cache, you would make a file called: apr.conf Inside that file, add the following directory (if I've read where you've installed the libraries correctly): /usr/local/apr/lib That should place the libraries on the system search path. You can do that, or create a setenv.sh file in $CATALINA_BASE/bin that contains the following line. CATALINA_OPTS=-Djava.library.path=/usr/local/apr/lib Obviously add any other CATALINA_OPTS you need to have there as well. I just checked on my Fedora 20 system, and the configuration is the same. So there's a good chance that this will be correct for CentOS 7. . . . just my two cents /mde/ -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.13 (MingW32) iQEcBAEBAgAGBQJT8+ZGAAoJEEFGbsYNeTwtaDcIAKpcH7oK7cBb+p/mdx40MI6k EfPpHEA+487gtEyRxFvYQrbxXvUA9gutEJlkAbrochZIp2hiPZ+YgremDUd6Illb RvnMCR3XBmMmrxZaGSWnGFW9hkb8dGVN1PgrfP6JZmS1SNIwpqECR+czFMIoRFW8 O7WlqNCEFhsGS9EQlF1HklT6B7VaKssw+lAI2xqQqUyP/HJZXlBHFdGBPJ1IK/2V 6XysQ6bFuLmLJ1j+mMxm+c9WJn/RsXT1Z9r8bwsW1Zg+oc567EkPDKe0rt1Lw97y 3CMo6d91xemPMv7VIe2cJjNUR3q5ZOws/BffBLADc+Pi8neBavOy9n8TE7uqnYE= =I3iS -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 8.0.9 native library not found
On Sat, Aug 16, 2014 at 9:26 PM, Neil Aggarwal n...@jammconsulting.com wrote: [truncated] cd tomcat-native-1.1.30-src/jni/native ./configure --with-apr=/usr/bin/apr-1-config When I look in /usr/local/apr/lib, I see these files: libtcnative-1.a libtcnative-1.la libtcnative-1.so libtcnative-1.so.0 --- first, don't use tomcat-native-1.1.30, use tomcat-native-1.1.31 from http://tomcat.apache.org/download-native.cgi Including thee old version is just Apache Foundation sense of humor. then you say ./configure --with-apr=/usr/bin/apr-1-config Is APR really installed, and really there? Install APR first , maybe in /usr/local/apr/ Then intall the tomcat-native --with-apr=/usr/local/apr and maybe it will work
RE: Tomcat 8.0.9 native library not found
Carl: don't use tomcat-native-1.1.30, use tomcat-native-1.1.31 I downloaded it and built it. /usr/local/apr/lib now contains these items: libtcnative-1.a libtcnative-1.la libtcnative-1.so libtcnative-1.so.0 libtcnative-1.so.0.1.30 libtcnative-1.so.0.1.31 pkgconfig I still get the warning about the native library not found. Is APR really installed, and really there? I can do /usr/bin/apr-1-config and I get the usage page for APR. I assume that means it is there. Thanks, Neil -- Neil Aggarwal, (972) 834-1565 We lend money to investors to buy or refinance single family rent houses. No origination fees, quick approval, no credit check. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat 8.0.9 native library not found
From: Neil Aggarwal [mailto:n...@jammconsulting.com] Subject: RE: Tomcat 8.0.9 native library not found I downloaded it and built it. /usr/local/apr/lib now contains these items: libtcnative-1.a libtcnative-1.la libtcnative-1.so libtcnative-1.so.0 libtcnative-1.so.0.1.30 libtcnative-1.so.0.1.31 pkgconfig I still get the warning about the native library not found. I can do /usr/bin/apr-1-config and I get the usage page for APR. I assume that means it is there. The mode (32- or 64-bit) of the APR and tcnative libraries must match that of the JVM you are using. Is that the case? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat 8.0.9 native library not found
Chuck: The mode (32- or 64-bit) of the APR and tcnative libraries must match that of the JVM you are using. Is that the case? I am not sure how to check. If I run: java -version, I get back this: java version 1.7.0_65 OpenJDK Runtime Environment (rhel-2.5.1.2.el7_0-x86_64 u65-b17) OpenJDK 64-Bit Server VM (build 24.65-b04, mixed mode) So, the JVM is 64 bit. If I run: /usr/bin/apr-1-config --srcdir, I get back this: /usr/lib64/build So, it seems apr is 64 bit. Is there anything else I should check? Thanks, Neil -- Neil Aggarwal, (972) 834-1565 We lend money to investors to buy or refinance single family rent houses. No origination fees, quick approval, no credit check. -Original Message- From: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] Sent: Sunday, August 17, 2014 9:18 AM To: Tomcat Users List Subject: RE: Tomcat 8.0.9 native library not found From: Neil Aggarwal [mailto:n...@jammconsulting.com] Subject: RE: Tomcat 8.0.9 native library not found I downloaded it and built it. /usr/local/apr/lib now contains these items: libtcnative-1.a libtcnative-1.la libtcnative-1.so libtcnative-1.so.0 libtcnative-1.so.0.1.30 libtcnative-1.so.0.1.31 pkgconfig I still get the warning about the native library not found. I can do /usr/bin/apr-1-config and I get the usage page for APR. I assume that means it is there. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat 8.0.9 native library not found
I can do /usr/bin/apr-1-config and I get the usage page for APR. I assume that means it is there. Don't assume. Your command lines said is was in /usr/lib/apr Is it in /usr/lib/apr? from what you said above, it isn't. I suggest you get APR from http://apr.apache.org/ and reinstall it. When I did, it went in /usr/lib/apr/ which is convenient
Tomcat 8.0.9 native library not found
Hello: I am trying to set up Tomcat 8.0.9 on my system running CentOS 7. I downloaded the tomcat source tarball and compiled it. I then built the native library using these commands: cd /usr/local/tomcat/bin tar zxf tomcat-native.tar.gz cd tomcat-native-1.1.30-src/jni/native ./configure --with-apr=/usr/bin/apr-1-config --with-java-home=/usr/lib/jvm/java-1.7.0-openjdk make make install When I run tomcat, I see this line in the output file: INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/local/apr/lib When I look in /usr/local/apr/lib, I see these files: libtcnative-1.a libtcnative-1.la libtcnative-1.so libtcnative-1.so.0 libtcnative-1.so.0.1.30 pkgconfig So, it looks like something was built and put in the library path. Any ideas how I can debug this problem? Thanks, Neil -- Neil Aggarwal, (972) 834-1565 We lend money to investors to buy or refinance single family rent houses. No origination fees, quick approval, no credit check. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org