> From: Ping Yu [mailto:[EMAIL PROTECTED] > I would like to transfer a file from Machine A to Machine > B. In Machine A, there are several IP addresses. However, the > IP address launched by Tomcat might be different from the IP > address I choose to transfer the file. Are there any ways > that I can get to know which IP address that Tomcat starts > with in a single machine? Are there any APIs or classes for > this? Then I can use the IP address started by Tomcat to > transfer my file.
As Chuck pointed out, by default Tomcat will listen on all addresses - unless you have a very odd IP stack. Why are you expecting Tomcat only to bind to one of the addresses? If you know what port Tomcat's on, and that port is unique on your machine, you could run "netstat -an" on Windows or most UNIXes to obtain the list of IP address and port mappings, then match on the port number and extract the local IP address for the LISTENING socket. But it's a horrible hack. - Peter --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]