You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Michael Tang <nt...@hotmail.com> on 2004/07/09 20:49:51 UTC

getRemoteHost return IP address

I am using Tomcat 4.0.6 and our customer ran into a weird and 
hard-to-reproduce problem. From the log, we see within one servlet, 
HttpServletRequest.getRemoteHost return host name (enableLookups="true" in 
server.xml). However, during the running, one HttpProcessor thread suddenly 
switch to returning IP address instead of the hostname. Does anyone see 
similar problem before or have any suggestion?

thanks,

-Michael

_________________________________________________________________
MSN Life Events gives you the tips and tools to handle the turning points in 
your life. http://lifeevents.msn.com


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: getRemoteHost return IP address

Posted by QM <qm...@brandxdev.net>.
On Fri, Jul 09, 2004 at 06:49:51PM +0000, Michael Tang wrote:
: I am using Tomcat 4.0.6 and our customer ran into a weird and 
: hard-to-reproduce problem. From the log, we see within one servlet, 
: HttpServletRequest.getRemoteHost return host name (enableLookups="true" in 
: server.xml). However, during the running, one HttpProcessor thread suddenly 
: switch to returning IP address instead of the hostname. Does anyone see 
: similar problem before or have any suggestion?

Is the macine otherwise (that is, outside of Tomcat) able to perform a
reverse lookup of the IP?  Because if the reverse lookup fails, Tomcat
will just log the IP.

Otherwise, if it's a true Tomcat bug, it's unlikely it will be fixed in
an official release: v4.0.x is now two revisions behind the current
version (5.0.x).

-QM

-- 

software  -- http://www.brandxdev.net
tech news -- http://www.RoarNetworX.com


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org