aspose file tools*
The moose likes Linux / UNIX and the fly likes About IP Addresses Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Linux / UNIX
Bookmark "About IP Addresses" Watch "About IP Addresses" New topic
Author

About IP Addresses

Rahul Mahindrakar
Ranch Hand

Joined: Jul 28, 2000
Posts: 1836
Hi

I have a web server running on my machine whose port is open. However my machine has DHCP. I check my "external" IP from a service like whatismyip.com

Now if my friend tries to access the webserver on the "external" IP and somehow it does not get it.

Now my question is how do other programs like yahoo messanger work. When my friend sends me a message does he not send me a message on a specific IP and port?

Thanks
Rahul
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8710
    
    6

You probably have to configure your router (or whatever you connect to the net with) to forward the traffic to your computer: portforward.com


"blabbing like a narcissistic fool with a superiority complex" ~ N.A.
[How To Ask Questions On JavaRanch]
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18135
    
    8

Rahul Mahindrakar wrote:Now my question is how do other programs like yahoo messanger work. When my friend sends me a message does he not send me a message on a specific IP and port?


Actually, no. Those programs do not run a server on your computer. When your friend "sends you a message" here's what happens:

  • The message goes to Yahoo's server
  • Yahoo's server puts it in a list of messages waiting for you
  • The messenger program on your computer sends out a request saying "Any messages for me?"
  • Yahoo's server sends the message back to the messenger program in response
  • The messenger program displays the message on your screen

  • Rahul Mahindrakar
    Ranch Hand

    Joined: Jul 28, 2000
    Posts: 1836
    Hi

    Opps I forgot that its a Client - Server architecture and it looks like Yahoo client is pooling for some messages.

    But this does not answer my moot question.

    If I have a IP and a server on DHCP why is it that an "outside" entity is not able to access the service.

    Thanks
    Peter Johnson
    author
    Bartender

    Joined: May 14, 2008
    Posts: 5778
        
        7

    If I have a IP and a server on DHCP why is it that an "outside" entity is not able to access the service.

    a) What is your local network configuration:
    Do you have a router? If so, then Joe answered your question.
    Or are you directly connected to your ISP? If so, then does your ISP route traffic to your IP address, or does it block it?

    b) Is there a firewall somewhere (either in your network or the IPS's) that is preventing the access.

    c) What network debugging have you done (ping, tracert, etc) and what were the results of each of those?

    d) If you do an ifconfig, what is the first node number? Is it 192?

    JBoss In Action
     
    I agree. Here's the link: http://aspose.com/file-tools
     
    subject: About IP Addresses
     
    Similar Threads
    Set tomcat for static IP.
    Port sharing (Port # 80)
    chat server
    Dynamic IP address and socket programming.
    Sending a message to a remote server