Jump to content
xisto Community
Sign in to follow this  
szupie

Server Behind Router Works fine to others, but not internally

Recommended Posts

I have an Apache server set up on my computer so that I can test my scripts without uploading them. The computer connects to the Internet through a wireless router. I can access my server fine by going to "localhost" (of course), but when I try to access it on any computer in the network by going to my modem's IP, my router's setup page shows up. However, this problem does not exist when I do it from a computer outside the network. I have tried forwarding Inbound port 80 to this computer, but it still doesn't work. I want to see the server's page using other computers behind the same router, so simply using localhost isn't an option for me.So does anyone know why this problem exists?

Share this post


Link to post
Share on other sites

A few questions to start with.

Is there a firewall on the computer that is running Apache?

Can you access the server by using the LOCAL IP address of the computer running Apache. Like 192.168.1.100

Do you have a DMZ option on your router?

What OS are you running Apache on?

It sounds like it is probably a firewall issue to me but if you have a DMZ setting that you can point to the computer running the server, then you'll know for sure. This will basically open ALL inbound and outbound ports to that computer and all requests will go to that computer as a result.

 

If you still cannot access the server, then it is a setting on that machine. WinXP SP2 has an advanced firewall package with it that has to be configured to allow your server to be seen by other computers. Any other software firewall will need to have an exception for port 80 as well.

 

vujsa

Share this post


Link to post
Share on other sites

1. I've disabled the Windows Firewall on the computer because it's really annoying at times.2. Oh, right, I forgot about doing that. OK, now I've solved the problem about accessing the server on the local network.3. DMZ... Isn't that the option that puts the computer outside of the router? The warning on the settings page looked pretty scary to me, so I left the setting at default.4. I'm running miniApache on Windows.Since you're an expert here, vujsa, let's try to solve the problem about why we can't access the server by its public IP. Even though the local IP works, I still want to know what my problem is.P.S. I just tried the DMZ settings and pointed it to this computer. It didn't work. :)

Edited by szupie (see edit history)

Share this post


Link to post
Share on other sites

Well, I'm not sure why you can't see your page from your LAN using your WAN IP address, because I can see it ok.Perhapes your router assumes that if you are trying to access the WAN IP address from the LAN that you want to update the router settings.You should put an index file in your root to prevent the contents being shown!So what is "Hypercubical Animations"! :)Well, I'll have to guess that this is resolved now. :)vujsa

Share this post


Link to post
Share on other sites

Here's a guide that I've had since early 2005 about running your own web server. It's located here: http://lygo.com/ly/sitemissing.html

The guy who wrote it had the same exact problem you appear to be having as well.

[N]F

EDIT: Page 2 has what you're looking for, link above modified to take you to page 2 :)

Edited by nightfox (see edit history)

Share this post


Link to post
Share on other sites

Oh, thanks, nightfox! I could never have gotten to that page with Google... I guess that's what Xisto is for! :)

In case the site goes down in the future, all you have to do is edit the hosts file, which is located at c:\windows\system32\drivers\etc\hosts for Windows (or System Folder for Mac). Add "YourLocalIPAddress YourDomainName" without quotes. I've tried doing "MyLocalIPAddress MyPublicIPAddress", but I guess the second part couldn't be an IP address.

Here's the reason for my problem:

Certain routers do not allow a machine 'behind' the router (i.e. on the local area network) to access itself, or to access any other machine 'behind' the router using a domain name... The router gets confused by this.

Well, I'm not sure why you can't see your page from your LAN using your WAN IP address, because I can see it ok.

Yeah, I can see it fine when I try to see it using a computer outside my network, I just couldn't do that within the network. That was the weird thing.

 

You should put an index file in your root to prevent the contents being shown!

Yeah, I know that, but I'm lazy and I wanted to access the pages using the hyperlinks. It's an equivalent exchange for the danger I've put myself into. :) Check out my new index page now. It's now officially the coolest home page on the whole Internet (on Guinness World Records). Yes, it's a fake link. Edited by szupie (see edit history)

Share this post


Link to post
Share on other sites

Oh, thanks, nightfox! I could never have gotten to that page with Google... I guess that's what Xisto is for! :)

Yeah, I found that site when I was trying to setup my own web server. I remember it took a while to find and it was so information filled that I printed out every part because it is such a great guide. Though I've never really setup a web server on Windows 2000 (I jumped right into a Linux server), I kept the guide for some reason. Best 28 page print job ever! Even if more than half of it is out of date, it's still a trusty guide! I've read it over and over. :)

[N]F

Share this post


Link to post
Share on other sites

access server from internet to exchange files

Server Behind Router

 

I'm trying to access my SBS server from the remote, I have LANCOM 1511 Wireless DSL 3.42.0021, but there is nothing can show me how to access the port forwarding to communicate with my server from the remote?

 

Once I change to NETGEAR Prosfae VPN firewall wall router I have problems to locally communicate with the server, domain can not be contacted, GPO is not applied for the users...Etc., it could be the router itself blocking the local traffic? thanks for your help!

 

Joseph.

 

-question by Joseph

Share this post


Link to post
Share on other sites
access to a server behind a wireless routerServer Behind Router

Hi, I read the problem you have to access your server from a computer in the same network. I have the same problem, but with a computer from outside the network

Does somebody know how I can access from the internet my website that is in a apache server behind a wireless router?

Share this post


Link to post
Share on other sites

access to a server behind a wireless router

 

Server Behind Router

 

 

 

<p>Hi, I read the problem you have to access your server from a computer in the same network. I have the same problem, but with a computer from outside the network</p>

<p>Does somebody know how I can access from the internet my website that is in a apache server behind a wireless router?</p>


With computers inside the network, using your external IP usually results in you getting access to your router, you need to setup what's known as an inside to inside Network Address Translation.

 

With external IP accessing a website behind a router, you need to configure port forwarding (pin-holing) on your router to allow outside connections to the internal IP:Port of your computer hosting the server. e.g. 192.168.0.4:80 for web services existing on network address 192.168.0.4

 

 

Cheers,

 

 

MC

Share this post


Link to post
Share on other sites
HereServer Behind Router

Yea I had the same problem. Frickin 2701 HG-B Router...Ok heres an idea, that worked for me after simple port forwarding didnt. In the firewall settings, enable DMZ or DMZ-Plus (whichever you have) pointing to the server computer (the one running apache) then go to http://obsolete.whatsmyip.org/ and check your ip. Type that into your browser and if you get your page it worked. If it didnt you can email me and ill help.

-reply by Momo

 

Share this post


Link to post
Share on other sites
networksServer Behind Router

I have a laptop running windows7 with apache web server(I have designed a login page on the webserver where one has to login before accessing internet) I want my linksystem wireless router to access internet from this laptop and my two other laptops(clients) to tap internet from this wireless router but they will have to first login  to access the internet..Any assistance I will b grateful.

Am using xammp which has a database & apache

-question by muyanja bonny

Share this post


Link to post
Share on other sites
how to connect and configure server to router to computer Server Behind Router

How to connect server and configure to router to computer ,I face problem that is if I setup the dhcp on server how router will configuer the pc because there is no dhcp on router please help I have test with cisco

-question by jamal

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.