I have installed Apache Tomcat 7.0.32 and I am using Eclipse JUNO. But whenever I am using Eclipse I am not getting result from Server rather than I am getting Server can not start within 45sec.
Try changing connection port in server.xml
Related
Sample Spring boot application is created and build on Jenkins.
For Deployment of war file in tomcat server ,
I am facing a several issues.
Error :
Credentials At Jenkins :
tomcat-users.xml File :
Still I am facing the same issue. I had searched in google and stackoverflow but still i can't found the correct answer.
Can Any one help me in this ?
Your error message is a connection refused: connect exception. You should check the following:
Your Tomcat server is up and running on port 8082 at the same server where your jenkins server is running (localhost). To make sure, run: telnet localhost 8082 from the same server commandLine ( I see you are in windows). If it connects then your Tomcat server is OK.
Check if the manager application of Tomcat is deployed. Try to load the following web page and check if exists: http://localhost(or hostname of server):8082/manager/html
Try to disable the windows firewall and any other firewall you may have (or antivirus firewall) and check if it prevents jenkins to connect to Tomcat (again check with telnet command)
Ok, I think I tried everything before I am posting this question. Please tell me, what I am (Still) missing. I keep getting "unable to connect" exception (unable to connect hostname:6012), I changed from default port 1099 and it still didn't help.
version of IntelliJ 14.0.2
Tomcat 7.0.52
Tomcat is running as a service so, I configured on the UI interface of tomcat.exe (java tab) the following JAVA_OPTs
-Xdebug
-Xrunjdwp:transport=dt_socket,address=57497,server=y,suspend=n
-javaagent:C:\Users\username\.IntelliJIdea14\system\groovyHotSwap\gragent.jar
-Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.port=6012
-Dcom.sun.management.jmxremote.authenticate=false
-Dcom.sun.management.jmxremote.ssl=false
-Dcatalina.home=C:\Tomcat 7.0
-Dcatalina.base=C:\Tomcat 7.0
-XX:MaxPermSize=512m
I made sure the port 57497 is open (open the firewall and telnet).
And on IntelliJ, I made a remote server connection. Please find attached
pictures. Both intellij and tomcat are running on the same system. I have a static dns setup. sometimes i get connection timedout exception.
server tab
connection tab
Here's my config.
Tomcat JAVA_OPTs to enable remote debugging:
-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5007
In IntelliJ, I don't use the Configuration-Type 'Tomcat'. In my case 'Remote' works pretty well (I would post an image but I ain't got 10 reputation...). You only need to configure your host and port on the config sheet.
I use IntelliJ 14.0.3 and I had the same issue, though with Jetty. Switching to using the remote instead of jetty -> remote worked. I'm guessing they're both supposed to work differently. I just haven't figured out why there are two different options to remote debug.
I'm using:
Spring Tool Suite Version: 3.2.0.RELEASE
Tomcat v7.0.42
When I just run my tomcat server everything is fine but I'm unable to debug it even locally. It produces following error:
Startich Apache Tomcat v7.0.42 at localhost has encoutered a problem.
Server Apache Tomcat v7.0.42 bat localhost was unable to start within 45 seconds. If the server requires more time, try increasing the timeout in the server editor.
I've tried the following:
increase the timeout.
remove all the apps before starting the debugging.
install new instance of tomcat (the only configuration that I've did on fresh install is turning on Use Tomcat installation and Never publish automatically).
But it didn't help, I still can only run the tomcat, without the debug option. Does anyone know how to make this debugging work?
When I've used new, clear workspace for Spring Tool Suite, debugging started to work.
Cheers,
I have been using Tomcat integrated with Eclipse for a long time, and now I want to try Jetty with maven without Eclipse (I am not using m2Eclipse for now). I know Jetty is using tomcat as container, and port will still be default 8080. Before doing anything reckless and screw up my setting, I would like to know that if any conflict could arise, and things to watch out for. If I just put jetty-plugin to the pom.xml in a separate project, will that affect my other projects build on tomcat with Eclipse?
Thank you.
If you want to run jetty and you already have tomcat running on port 8080 then that will not work, only one or the other can use a single port. The solution is simple though, either set a different port in the jetty-maven-plugin configuration (8090?) or set no port and in the output of the plugin running it will have a line about the SelectChannelConnector or ServerConnector starting on port ###. Simply use that in your browser for the port.
[edit] I'll also note that should you have tomcat running on 8080 and you startup jetty and it tries to use 8080, the jetty process will fail and the tomcat process will be completely unaffected. The same as if the roles we reversed.
I have installed tomcat7 and postgreSQL9 on AWS- Ec2 Micro ,
I am able to connect to the EC2 postgreSQL instance form a spring application running on my local tomcat 7 server.
When I deploy the same war file on the EC2- tomcat7 server, it is throwing the following error..
Cannot create JDBC driver of class '' for connect URL 'jdbc:postgresql://ec2-user#x-x-x-x-x.us-x-x.compute.amazonaws.com/test'
java.sql.SQLException: No suitable driver
at java.sql.DriverManager.getDriver(DriverManager.java:279)
I have copied postgresql-9.1-901.jdbc3.jar to /usr/share/tomcat7/lib
I have tried using the AWS internal IP ... No luck..
I don't know what I am doing wrong. The same war with same configuration works from local tomcat7. Am I missing any thing with AWS tomcat7 configuration?
Hi it seems you haven't included the postgresql jdbc jar. Try including that it should work.