Domanda

Are there difference in the way how Tomcat8 is bind to windows network socket whe is started from console (by startup.bat) of if is started as a windows service? I am not able to connect to application web if Tomcat is started as a windows service. See netstat if started from console:

C:\Program Files\Apache Software Foundation\apache-tomcat-8.0.0-RC10\bin>netstat -abnop tcp | grep -i -B2 8089 [java.exe]**

TCP 0.0.0.0:8089 0.0.0.0:0 LISTENING 6016

See netstat if started as a service (notice different name of listening process):

C:\Program Files\Apache Software Foundation\apache-tomcat-8.0.0-RC10\bin>netstat -abnop tcp | grep -i -B2 8089 [tomcat8.exe]**

TCP 0.0.0.0:8089 0.0.0.0:0 LISTENING 2856

Windows service was created by documentation: 'service.bat Install'. "Image path" of service is: "c:\Program Files\Apache Software Foundation\apache-tomcat-8.0.0-RC10\bin\tomcat8.exe" //RS//Tomcat8

What am I doing wrong?

È stato utile?

Soluzione

1st thing you should do: Check your Windows Firewall :)

When you say "different name of listening process", are you talking about the PID? Have you tried to use "ProcessExplorer" (http://technet.microsoft.com/en-us/sysinternals/bb896653) to check the discrepancies between the Java processes that are created when you start the Tomcat instance?

When you mouse over the java process you can see the JVM arguments assigned for that JVM instance, also, when you right-click the java.exe process you can check its properties, on the "TCP/IP" tab you can check if your Tomcat is listening on the right port. Try to start Tomcat using both approaches and take a closer look with ProcessExplorer, that should help you identify any misconfiguration.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top