0
votes

I'm a complete noob to IntelliJ and Tomcat 8. I managed to configured Tomcat 7 in IntelliJ in the same manner (as configuring TC8) and it works normally. Also, TC8 works when I start it up using command-line.

Here's what IntelliJ tells me when I try to run TC8:

"Application Server was not connected before run configuration stop, reason: java.io.IOException: Failed to retrieve RMIServer stub: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is: java.net.SocketException: Connection reset]"

Logs:

C:\apache-tomcat-8.0.8\bin\catalina.bat run Using CATALINA_BASE:
"C:\Program Files\Apache Software Foundation\Tomcat 8.0" Using CATALINA_HOME: "C:\apache-tomcat-8.0.8" Using CATALINA_TMPDIR: "C:\apache-tomcat-8.0.8\temp" Using JRE_HOME: "C:\Program Files\Java\jre8" Using CLASSPATH:
"C:\apache-tomcat-8.0.8\bin\bootstrap.jar;C:\apache-tomcat-8.0.8\bin\tomcat-juli.jar" Jun 06, 2014 1:22:08 AM org.apache.catalina.startup.Catalina load WARNING: Unable to load server configuration from [C:\Program Files\Apache Software Foundation\Tomcat 8.0\conf\server.xml] Jun 06, 2014 1:22:08 AM org.apache.catalina.startup.Catalina load WARNING: Unable to load server configuration from [C:\Program Files\Apache Software Foundation\Tomcat 8.0\conf\server.xml] Jun 06, 2014 1:22:08 AM org.apache.catalina.startup.Catalina start SEVERE: Cannot start server. Server instance is not configured. Disconnected from server

1
Is your tomcat server is running ? and from where you have tried to connect or start tomcat server ? Because as per my knowledge it's working fine for me. - user3145373 ツ
That's the problem. I can't get it run. I hit the green play looking icon in the top right corner of intelliJ when the Tomcat 8 configuration is selected. It begins to start, but fails and I get the messages above. - Faahmed
Stop Tomcat Service if running then check your edit configuration once then create it's instance for your web application then try to run it. - user3145373 ツ
You mean create a new configuration? - Faahmed
Wait I am posting answer. - user3145373 ツ

1 Answers

3
votes

Follow these steps :

Configure new Tomcat Server :

enter image description here

After configure click on OK.

Then on that one + symbol is there click on it i.e. in Green color, it shows :

enter image description here

then last step is to configure it for application :

enter image description here

from deployment tab add exploded file of application then configure that in which browser you want to open application then click OK, if you want to change more settings then you can.

Then try click on Green Button that will run your application.