I'm facing a problem trying to start/restart tomcat7.
When I do start/restart, the service seems to be starting/restarting ok:
* Stopping Tomcat servlet engine tomcat7 [ OK ]
* Starting Tomcat servlet engine tomcat7 [ OK ]
However, checking the log, I found this:
Oct 22, 2014 11:48:14 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Oct 22, 2014 11:48:14 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 721 ms
Oct 22, 2014 11:48:14 AM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Oct 22, 2014 11:48:14 AM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.52 (Ubuntu)
Oct 22, 2014 11:48:14 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/manager.xml
and nothing else happens. The cpu seems to be OK and the memory too. It just got stuck in that point.
This issue appears suddenly because no change was made, no updates on tomcat or changes in the artifact that I'm trying to deploy.
What could be the problem?
Related
After noticing that my web application is not running on the production server anymore, I looked inside the tomcat log (catalina.out):
Java HotSpot(TM) Client VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
Listening for transport dt_socket at address: 8000
Mar 26, 2018 7:53:26 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Mar 26, 2018 7:53:26 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 4624 ms
Mar 26, 2018 7:53:26 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Mar 26, 2018 7:53:26 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.52 (Ubuntu)
Mar 26, 2018 7:53:26 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /var/lib/tomcat7/webapps/ROOT
Java HotSpot(TM) Client VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
Listening for transport dt_socket at address: 8000
Mar 26, 2018 7:54:26 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Mar 26, 2018 7:54:26 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 2108 ms
Mar 26, 2018 7:54:26 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Mar 26, 2018 7:54:26 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.52 (Ubuntu)
Mar 26, 2018 7:54:27 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /var/lib/tomcat7/webapps/ROOT
Java HotSpot(TM) Client VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
Listening for transport dt_socket at address: 8000
Mar 26, 2018 7:55:31 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Mar 26, 2018 7:55:32 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 2428 ms
Mar 26, 2018 7:55:32 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Mar 26, 2018 7:55:32 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.52 (Ubuntu)
Mar 26, 2018 7:55:32 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /var/lib/tomcat7/webapps/ROOT
Java HotSpot(TM) Client VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
Listening for transport dt_socket at address: 8000
Mar 26, 2018 7:56:36 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Mar 26, 2018 7:56:36 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1873 ms
Mar 26, 2018 7:56:36 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Mar 26, 2018 7:56:36 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.52 (Ubuntu)
Mar 26, 2018 7:56:36 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /var/lib/tomcat7/webapps/ROOT
Java HotSpot(TM) Client VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
Listening for transport dt_socket at address: 8000
Mar 26, 2018 7:57:42 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Mar 26, 2018 7:57:42 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 2534 ms
Mar 26, 2018 7:57:42 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Mar 26, 2018 7:57:42 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.52 (Ubuntu)
Mar 26, 2018 7:57:42 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /var/lib/tomcat7/webapps/ROOT
The deploy "loop" starts with the following message:
Mar 26, 2018 5:00:45 PM org.apache.coyote.AbstractProtocol pause
INFO: Pausing ProtocolHandler ["http-bio-8080"]
Mar 26, 2018 5:00:46 PM org.apache.catalina.core.StandardService stopInternal
INFO: Stopping service Catalina
I tried to restart Tomcat and the entire server multiple times without success.
Can you imagine what's going wrong here?
Similar cases have been reported and the explanation was a Memory Leak.
About this warning which mentions that PermGen is ignored, why don't you use the correct option ? This might explain an insufficient memory leading to your problem.
Java HotSpot(TM) Client VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
If after using the correct option (XX:MaxMetaspaceSize) you still have this problem, try giving it more memory. Try to understand what changed then your application cannot run anymore (data has changed in the DB ? how ?). If you still to convince yourself, remove the application and start Tomcat with no webapps at all.
Strange...
Can you run your app with other server ? Such as glassfish or jetty ?
I know it doesn't answer your question,but if the app work with the servers mentioned above, than your tomcat is with some problem,but if not work if them, than your code have some problems.
I am trying to start Tomcat 7.0.55 from Eclipse Luna on Ubuntu 14.04.
It is working perfectly fine when the Eclipse is run through sudo nautilus.
But when the Eclipse is used via normal user and Tomcat is started, the following
error occurs:
Server Tomcat v7.0 Server at localhost was unable to start within 45
seconds. If the server requires more time, try increasing the timeout
in the server editor.
I have tried to increase the timeouts to 200 seconds, but still the same error.
Till the time Eclipse tries to start the Tomcat, the server tab shows following status
Tomcat 7.0 Server at localhost [ Starting, Synchronized]
and the console tab shows:
Sep 17, 2014 3:02:07 PM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/lib/jvm/java-7-openjdk-i386/jre/lib/i386/server:/usr/lib/jvm/java-7-openjdk-i386/jre/lib/i386:/usr/lib/jvm/java-7-openjdk-i386/jre/../lib/i386:/usr/lib/jvm/java-7-openjdk-i386/jre/lib/i386/client:/usr/lib/jvm/java-7-openjdk-i386/jre/lib/i386::/usr/java/packages/lib/i386:/usr/lib/i386-linux-gnu/jni:/lib/i386-linux-gnu:/usr/lib/i386-linux-gnu:/usr/lib/jni:/lib:/usr/lib
Sep 17, 2014 3:02:07 PM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:testprj' did not find a matching property.
Sep 17, 2014 3:02:08 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Sep 17, 2014 3:02:08 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Sep 17, 2014 3:02:08 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1168 ms
Sep 17, 2014 3:02:08 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Sep 17, 2014 3:02:08 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.55
Sep 17, 2014 3:02:09 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
Sep 17, 2014 3:02:09 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
Sep 17, 2014 3:02:09 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 1131 ms
and once the error pops, the Eclipse server tab shows:
Tomcat v7.0 Server at localhost [ Stopped, Synchronized]
Any help ?
I'm using Eclipse Kepler and Tomcat 7 and Ubuntu 12.04. When Tomcat starts it after 45 seconds it says
Server Tomcat v7.0 Server at localhost was unable to start within 45 seconds. If the server requires more time, try increasing the timeout in the server editor.
I increased the timeout, reinstalled Eclipse and Tomcat but still the problem is not solved.
In debug mode I get this error.
<terminated, exit value: 143>/usr/lib/jvm/java-7-openjdk-amd64/bin/java (May 26, 2014, 12:26:09 PM)
My console says:
May 26, 2014 12:26:10 PM org.apache.catalina.core.AprLifecycleListener init
INFO: 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/lib/x86_64-linux-gnu/jni:/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu:/usr/lib/jni:/lib:/usr/lib
May 26, 2014 12:26:10 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
May 26, 2014 12:26:10 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
May 26, 2014 12:26:10 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 995 ms
May 26, 2014 12:26:10 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
May 26, 2014 12:26:10 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.54
May 26, 2014 12:26:11 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
May 26, 2014 12:26:11 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
May 26, 2014 12:26:11 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 804 ms
Add server runtime at starting of creation of anything in your eclipse environment
add specified installed tomcat library and jdk location and it will works
Yesterday I deployed my war in openshift using the usual command git push. But when I checked the url http://nrollin-nrollin.rhcloud.com, I am seeing the error HTTP Status 404 - The requested resource is not available. I have deployed the war many times but this is the first time I am seeing this error. I have even restarted the server but no luck. I searched down the cause in openshift forum also (https://www.openshift.com/forums/openshift/jbossas-application-the-requested-resource-is-not-available), but no solution to me as such yet. The app is running good in my local PC and is developed in Spring MVC and Hibernate.
Can anyone suggest me the cause of this issue? Or do I have to create app again..?
Below are the logs :
Jul 27, 2013 3:43:44 PM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-127.4.82.1-8080
Jul 27, 2013 3:43:44 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 5182 ms
Jul 27, 2013 3:43:44 PM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Jul 27, 2013 3:43:44 PM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.37
Jul 27, 2013 3:43:45 PM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive ROOT.war
Jul 27, 2013 3:44:06 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
Jul 27, 2013 3:44:06 PM org.apache.catalina.core.StandardContext start
SEVERE: Context [] startup failed due to previous errors
Jul 27, 2013 3:44:09 PM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-127.4.82.1-8080
Jul 27, 2013 3:44:10 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 25540 ms
I faced the same problem in my local system yesterday but I resolved it by cleaning it along with its directory. I think the same would be needed for Openshift tomcat server.
I have configured Tomcat 7 with Eclipse Helios 1.3.2 on port number 8080. Tomcat Service and everything is installed.
When I am starting the server from Eclipse, it does some process and shows the status as STARTED. But when I try to hit http://localhost:8080, it says The requested resource (/) is not available. i.e. in fact server is not started in reality.
However, when I am starting the server from Windows Explorer by running Tomcat7.exe or Tomcat7w.exe, it starts well and I am able to see Apache Home page by referring to http://localhost:8080.
Below is the server start up log.
Jul 02, 2012 1:20:12 PM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jre7\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:/Program Files/Java/jre7/bin/client;C:/Program Files/Java/jre7/bin;C:/Program Files/Java/jre7/lib/i386;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Perforce;O:\ora1106w\bin;C:\Program Files\Java\jdk1.6.0_12\bin;;C:\Program Files\WinMerge;C:\Users\KNIRAV\Downloads\eclipse-jee-helios-SR2-win32\eclipse;;.
Jul 02, 2012 1:20:17 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Jul 02, 2012 1:20:17 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Jul 02, 2012 1:20:17 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 5674 ms
Jul 02, 2012 1:20:17 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Jul 02, 2012 1:20:17 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.28
Jul 02, 2012 1:20:18 PM org.apache.catalina.util.SessionIdGenerator createSecureRandom
INFO: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [126] milliseconds.
Jul 02, 2012 1:20:18 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
Jul 02, 2012 1:20:18 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
Jul 02, 2012 1:20:18 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 1788 ms
Can I have some solution to this please?
There is no problem. When you start Tomcat from Eclipse a root application is not deployed. Only the projects that you deploy through the server view are available.
Have you tried to deploy a project on the server?