I'm running a Linux server named S1 in a "cloud" server, and when tomcat 6.0.24 starts, I get the exception:

org.apache.catalina.connector.Connector pause
SEVERE: Protocol handler pause failed
java.net.UnknownHostException: S1: S1
    at java.net.InetAddress.getLocalHost(InetAddress.java:1353)
    at org.apache.jk.common.ChannelSocket.unLockSocket(ChannelSocket.java:485)

Which then leads to:

ERROR ehcache.Cache  - Unable to set localhost. This prevents creation of a GUID. Cause      was: Sjira1: S1
java.net.UnknownHostException: S1: S1
    at java.net.InetAddress.getLocalHost(InetAddress.java:1353)
    at net.sf.ehcache.Cache.<clinit>(Cache.java:143)

My hosts file is:

127.0.0.1     localhost localhost.localdomain
(valid-ip-address)     S1 S1.(valid domain name)
  • ping S1 and S1.(valid domain name) return valid ip address
  • nslookup S1.(valid domain name) returns valid ip address
  • nslookup S1 throws ** server can't find S1: NXDOMAIN

Any ideas about how to fix this ?

Thanks

link|improve this question

feedback

3 Answers

up vote 1 down vote accepted

Solved ... added "search (domainname)" to resolv.conf

link|improve this answer
I'm getting the same problem. Did you add search (S1) or search S1 to resolve.conf? – Josh K Jan 13 '11 at 2:46
Actually "search (hostname.domainname)" – xain Jan 18 '11 at 2:06
feedback

Most likely S1 does not resolve to an IP using a name server only.

link|improve this answer
feedback

I had this exact same error and tried your suggestions. Tomcat would start without any errors but my webapp would just hang. The fix I had, which is really strange, was to cd to ${tomcat_home}/bin first and then execute the startup.sh. When I reverted back to the original hosts and resolv.conf files and applied this fix, it worked fine. Weird.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.