logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> How-to's & Documentation & Tips View previous topic :: View next topic
Reply to topic   Topic: Help My Server Works fine LAN but not from the internet!!!
Author
Jorge



Joined: 12 Mar 2006
Posts: 376
Location: Belgium

PostPosted: Wed 23 Aug '06 20:49    Post subject: Help My Server Works fine LAN but not from the internet!!! Reply with quote

Introduction wrote:

On this forum and a few others I visit that deal with Apache or servers in general this is a question that appears every so often (4x per week or so ^^)
In here I'll try to provide a basic troubleshooting plan.


Common Mistakes wrote:

1. You using the internal IP address not the external one.
2. You router doesn't have port forwarding setup
3. You have a dynamic IP


Admin note:
If you still have issues or find something confusing, please post in on of the other forums


Section 1:
23-August-2006: Complete Revision 1
24-August-2006: Removed Spelling errors

Section 2:
26-August-2006: Finished Section 2
25-August-2006: Incomplete Draft

Section 3:
Todo


Last edited by Jorge on Sun 27 Aug '06 14:12; edited 7 times in total
Back to top
Jorge



Joined: 12 Mar 2006
Posts: 376
Location: Belgium

PostPosted: Wed 23 Aug '06 20:54    Post subject: Reply with quote

You using the internal IP adress not the external one
Ok firstly there are different classes of IP adresses.

Loopback - 127.0.0.1
This address always refers to your computer... but it will only work on the machine itself!
So accessing your server from 127.0.0.1 will work fine if you're on the machine itself.
But if you for example use your wife's computer it won't work... for her computer the adress will be refuring to itself and not yours.

Note:
Localhost = 127.0.0.1


Class C & Class A
These are usually used by routers. The difference between A & C aren't important.

The address usually start with:
192.xxx.xxx.xxx
10.xxx.xxx.xxx

if you are using one of those addresses it will work for your LAN only.
e.g. 192.168.2.15 is your server.
If you enter http://192.168.2.15 in the browser on the server it will work.
Same if you enter that in a browser in any computer in your network.

Note:
If you have one of these, it mostly won't be a static one but one provided by your router during startup.
Unless you know that you have a static IP... check your IP before sending it to someone on your network it might have changed compared to alst time.


External IP's
These addresses are usually provided by your ISP and vary a whole lot.
A quick way to check your External IP is by looking at your router's info page. It will be listed as WAN IP.
If you can't find it on your routers info page you can always visit:
http://www.whatsmyip.org/
or
http://www.whatsmyip.us/

Note:
This is the address you need to send to your friends if you want them to visit your site.
Big problem here is that they are almost always dynamic unless you pay extra.
Ways to overcome this will be posted later.
Back to top
Jorge



Joined: 12 Mar 2006
Posts: 376
Location: Belgium

PostPosted: Fri 25 Aug '06 11:59    Post subject: Reply with quote

You router doesn't have port forwarding setup
If you use a router, you need to setup port forwarding.

Eh port what??
Ok so the router sits between the internet and your server.
A friend can't access your server because he's really accessing the router.
But have no fear! Routers can forward request the get on port X to a different server (even on a different port!).

Here is a diagram:
Code:
Internet User <--> router:80 <--> internalserver:80


Of course the router doesn't do this by default, since there can be any number of computer/server that have a particular service running.

You need to tell the router that every request it receives on port 80 (HTTP) needs to be sent to a different computer inside the network.


Requirements for port forwarding

    1. ISP that has the port you want to use open
    2. Static IP for the server
    3. Router with port forwarding


1. ISP that has the port you want to use open

My experience tells me that they usually don't block many ports. A few that worms use and possibly port 25 (to stop spammers).

If you aren't sure just e-mail them or call them.

2. Static IP for the server
There is a big chance you don't have a static IP for your server.
If you don't know what kind you have, it's probably dynamic.

To configure a static IP check:
http://www.portforward.com/networking/static-xp.htm

3. Router with port forwarding
Most router if not all have this.
It's just needs to be configured.

But not all routers are the same so check for your brand and module:
http://www.portforward.com/routers.htm

After you are at the correct page select Apache from the list with applications and follow the instructions.
Back to top


Reply to topic   Topic: Help My Server Works fine LAN but not from the internet!!! View previous topic :: View next topic
Post new topic   Forum Index -> How-to's & Documentation & Tips