After using eclipse to build the Tomcat service today, start the service and a series of exceptions are prompted.
Information: The APR based Apache Tomcat native library which allows optimal performance in production environments was not found on the java. library. path: D: \ Program Files \ Java \ jre1.6.0 _ 05 \ bin ;.; c: \ windows \ sun \ Java \ bin; c: \ windows \ system32; C: \ WINDOWS; D:/program files/Java/jdk1.6.0 _ 05/bin /.. /JRE/bin/client; D:/program files/Java/jdk1.6.0 _ 05/bin /.. /JRE/bin; D:/program files/Java/jdk1.6.0 _ 05/bin /.. /JRE/lib/i386; D: \ Program Files \ Java \ jdk1.6.0 _ 05 \ bin; c: \ windows \ system32; C: \ WINDOWS; C: \ windows \ system32 \ WBEM; c: \ windows \ system32 \ windowspowershell \ V1.0 \; D: \ Program Files \ mysql \ MySQL Server 5.0 \ bin; D: \ Program Files \ rational \ common; E: \ installation file \ eclipse;
Solution: To release.
Why? The following is to start djava. Library. Path in Tomcat corresponding to the Registry path to find the tcnative-1.dll file.
I think this is related to the combination of Tomcat and JDK downloaded by myself.
Http://tomcat.10.x6.nabble.com/tcnative-1-dll-td2128930.html
How can I tell for sure that tcnative-1.dll is used by tomcat?
System is Windows 2003 sp2, Tomcat 5.5.20, JDK 1.5.0 _ 11, tcnative-1.dll used is 1.1.12
Tomcat is started as a service.
Files tcnative-1.dll is placed in directory mentioned
-Djava. Library. Path =... in registry.
If it's not in this directory there is a warning in stdout. Log (which is the only one used for logging ).
(.... Can't find... tcnative-1.dll ...), but when it's placed in the directory, there is no message about it's loading (as stated in
Http://tomcat.apache.org/native-doc ).
Difference in version behaviour, or ...?
Start the service again using tomcat, and there is no exception.
22:46:57 Org. apache. catalina. core. aprlifecyclelistener init information: loaded APR based Apache Tomcat native library 1.1.10.2013-8-12 22:46:57 org. apache. catalina. core. aprlifecyclelistener init information: Apr capabilities: ipv6 [false], sendfile [True], accept filters [false], random [True]. 22:46:58 Org. apache. coyote. http11.http11aprprotocol init information: initializing coyote HTTP/1.1 on http-80802013-8-12 22:46:58 Org. apache. coyote. AJP. ajpaprprotocol init information: initializing coyote AJP/1.3 on ajp-80092013-8-12 22:46:58 Org. apache. catalina. startup. catalina load information: initialization processed in 1050 ms2013-8-12 22:46:58 Org. apache. catalina. core. standardservice start information: starting service Catalina2013-8-12 22:46:58 Org. apache. catalina. core. standardengine start information: Starting Servlet Engine: Apache Tomcat/6.0.202013-8-12 22:46:58 Org. apache. coyote. http11.http11aprprotocol start information: Starting coyote HTTP/1.1 on http-80802013-8-12 22:46:58 Org. apache. coyote. AJP. ajpaprprotocol start information: Starting coyote AJP/1.3 on ajp-80092013-8-12 22:46:58 Org. apache. catalina. startup. catalina start information: server startup in 347 MS
When the problem occurs, we access http: // localhost: 8080/and the Tom old cat is not displayed.
It took me more than two hours to find the cause.
Solution:
1. Double-click the Tomcat service to display the content in the image.
2. Change the two items in the modification to the second one, and change the path name below to webapps. Don't forget to press Ctrl + S to save it, And then restart the Tomcat service. That's OK.
3. Tom started the old cat successfully. It usually takes more than 20 seconds to start it. Access http: // localhost: 8080/to go to the homepage.
Reference: http://blog.knowsky.com/257398.htm