1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How to Access Server from Outside World?

Discussion in 'Apache' started by riqrat, Aug 16, 2014.

  1. #1
    Wow, I've spent HOURS scouring the net for answers. I finally have to break down and ASK. I'll try to be detailed.

    I have a local network with modem, router, and several computers either Cat5 to router or via wireless. Router is Cisco Linksys E4200. The internal IP for this router would be 192.168.1.1.

    One of the computers has Ubuntu Server 14.04 (32-bit) and Apache2 installed, and this is hardwired (Cat5) to the router. This computer also has a STATIC IP address that we will call 192.168.1.100.

    On another machine, my Windows 7 Ultimate computer, I can open a browser and type "192.168.1.100" and the Apache2 Ubuntu Default Page will pop up telling me that "It works!".

    This tells me that I have the Apache server working since I can access from within my LAN.

    My problem is to get it to show me the same "It Works!" when I try to access from the Internet.

    I got my 'external IP' address by simply going to whatismyip.com, and I can also see it from within my router settings.

    The next thing I did was to setup Port Forwarding inside the router, to point say 50505 to 192.168.1.100. I've tried lots of port numbers. No matter what I do, I cannot see my Apache2 Default page by typing in my browser "98.180.213.110:50505", for example. This assumes 98.180.213.110 is my external IP and 50505 is the port I am forwarding. (This external IP is not actually mine, but I am still quite the newbie and don't really know whether it is safe or not to broadcast it. If it isn't a problem, please feel free to educate me on this.)

    I've tried disabling the IP4 firewall within the router, and even the "anonymous" filter request setting. Still no go.

    So I'm stuck. I can find my webserver via browser in-house, but I cannot access from my external IP as if I were at a different location.

    Any suggestions? TIA
     
    riqrat, Aug 16, 2014 IP
  2. Riots

    Riots Active Member

    Messages:
    374
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    83
    #2
    when you go to 192.168.1.100 locally you are accessing the server using the default port 80
    So you need to change or add a new listening port from the 80 or a new one to the 50505 so it will listen on that port.
    lots of isp block port 80. also check that your router does not have remote login turned on that uses port 80 sometimes.

    Also are you trying to connect to your external ip from the same network?
    Most of the times your isp will not let you loop back.
    I would try to test the connection from another device using another ip address. maybe your mobile phone or another device out side of your network

    You are doing the port forwarding correctly. you just need to make sure it is listening on the port you are forwarding. and try from another device outside your network.
     
    Riots, Aug 16, 2014 IP
  3. riqrat

    riqrat Greenhorn

    Messages:
    3
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    11
    #3
     
    riqrat, Aug 16, 2014 IP
  4. riqrat

    riqrat Greenhorn

    Messages:
    3
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    11
    #4
    Success! I got to thinking about the Port Forwarding and something hit me. There is a box for 'external' port and 'internal' port. Since my server is listening on port 80, I started to think that perhaps the 'internal port' might possibly be asking for port the 'server' itself is listening on. Since was able to test it out successfully within my LAN, there was no question that it was listening and ready to respond.

    In my router, (after I went ahead and did a firmware update, reset, manually putting back my settings that got erased *&^errr!) I decided to set the 'internal' port to 80 and the 'external port' to one of the available unregistered ports. It worked like a charm!
     
    riqrat, Aug 16, 2014 IP
  5. Riots

    Riots Active Member

    Messages:
    374
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    83
    #5
    Nice. Im glad you got it working
     
    Riots, Aug 16, 2014 IP