This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Tomcat and the fly likes Which IP address is to be given in Listen directive Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Which IP address is to be given in Listen directive" Watch "Which IP address is to be given in Listen directive" New topic
Author

Which IP address is to be given in Listen directive

Prasad Darsi
Greenhorn

Joined: Sep 26, 2004
Posts: 16
I am trying to host website from my machine. I am connected to router and I have configured it to forward the port to my machine.

I can see my web page in my local network.
The problem is my page is not getting displayed to others over internet.

Which IP address should I give in the Listen directive ?

The local IP address or the WAN ip address ?

Thanks in advance,
Prasad.
Scott Dunbar
Ranch Hand

Joined: Sep 23, 2004
Posts: 245
Well, kind of both

Your internal network is probably something like 192.168.x.y. This is a non-routable IP address which means that it will not be available from the internet. So in your internal network you'll want to access the server by it's local IP - again, likely to be something like 192.168.something.something. Your router will provide NAT - network address translation from the outside address to the inside address. From your office or outside of your home you'll access the server via the external IP you've been given. But the Listen address will be your local IP.
[ April 12, 2006: Message edited by: Scott Dunbar ]

<a href="http://forums.hotjoe.com/forums/list.page" target="_blank" rel="nofollow">Java forums using Java software</a> - Come and help get them started.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Which IP address is to be given in Listen directive
 
Similar Threads
Finding the IP Address of Remote Machines if any connected to my Current machine
Problem connecting to Remote Server
How to get IP Address of Client Machine?
Tomcat and ipv6
Apache not working when accessed with IP address