tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Caldarale, Charles R" <>
Subject RE: Virtual Hosting Questions
Date Wed, 17 Nov 2004 19:56:40 GMT
> From: Shapira, Yoav []
> Subject: RE: Virtual Hosting Questions
> It's more of a Java networking question that Tomcat question.  I'm not
> sure how java's InetAddress class likes hosts files: my guess 
> is they're ignored.

Using the hosts file is the responsibility of the underlying TCP/IP stack, not the JRE. This
is normally automatic, but may have to be configured on some platforms.

> >Question 2: Why is the host named localhost?
> Localhost is just the default name.  You can substitute any string in
> there, and have as many Hosts as you want inside the Engine, but the
> Host name must be unique within the Engine.

I seem to recall seeing code in some component of Tomcat that explicitly treated the string
"localhost" as (rather than the normal value of, just for this one configuration
entry.  This allows listening on all IP addresses configured for the TCP/IP stack.

> Question 3: How would one configure a 'local' virtual host, i.e. a host
> visible only on the box that runs tomcat?

Haven't tried it, but putting in there explicitly should prevent listening for connection
requrests from the network.

 - Chuck

for use only by the intended recipient. If you received this in error, please contact the
sender and delete the e-mail and its attachments from all computers.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message