Tomcat java application does not work

Created:

2016-11-16 13:12:31 UTC

Modified:

2017-04-24 11:43:05 UTC

0

Was this article helpful?


Have more questions?

Submit a request

Tomcat java application does not work

Applicable to:

  • Plesk 12.5 for Linux
  • Plesk 11.5 for Linux

Symptoms

Tomcat application is marked with an orange circle with an exclamation mark inside in Plesk GUI. Tomcat server is not responding on requests on tcp port 8080:

wget http://127.0.0.1:8080
--2014-02-04 14:36:37-- http://127.0.0.1:8080/
Connecting to 127.0.0.1:8080... connected.
HTTP request sent, awaiting response...

Cause

OS is configured with IPv6 support and Tomcat is binded to IPv6 only

~# netstat -napl |grep java
tcp6 0 0 :::9080 :::* LISTEN 3723/java
tcp6 0 0 :::8080 :::* LISTEN 3723/java

Resolution

Add th follwoing string in configuration file according to OS:

Debian/Ubuntu

    # vi /etc/default/tomcat6
JAVA_OPTS="${JAVA_OPTS} -Djava.net.preferIPv4Stack=true -Djava.net.preferIPv4Addresses"

For CentOS/RHEL

    # vi /etc/sysconfig/tomcat6
JAVA_OPTS="${JAVA_OPTS} -Djava.net.preferIPv4Stack=true -Djava.net.preferIPv4Addresses"
Have more questions? Submit a request
Please sign in to leave a comment.