»
 

Go Back   ResellerRatings Store Ratings > ResellerRatings Forums > Tech Support

Reply
 
LinkBack Thread Tools Display Modes
Old 03-24-2004, 03:48 AM   #1 (permalink)
Registered User
 
Join Date: Mar 2004
Posts: 3
gbupc is on a distinguished road
How to set up an apache server behind a router with dynamic IP addresses

I want to test my website on my local machine with apache server. I have got a d-link 504 router but don't know much about how to access from outside. Could anyone tell me how to access from outside using external ip? I have heard something like port forwarding but have no idea about what it is and how it works.

Thanks a lot.

gbupc is offline   Reply With Quote
Old 03-24-2004, 04:32 AM   #2 (permalink)
Registered User
 
Join Date: Oct 2001
Location: TOO close to Wash DC
Posts: 7,956
vass0922 is on a distinguished road
It depends on the router you're using....

You can go to www.whatismyip.com to find your Current IP.

Once you get it working you can use dynamic DNS provider like www.dyndns.org to register a domain name with your dynamic IP.

On your router you will have to forward port 80 to your webserver.
Note: Some ISP's do not allow port 80 requests to your machine, so you may have to use an alternative port to listen to.
__________________
<< Insert exceedingly large and overly verbose message of how 1337 you are here including full specs of every vehicle you've ever driven and PC you've owned >>
vass0922 is offline   Reply With Quote
Old 03-24-2004, 05:07 AM   #3 (permalink)
Registered User
 
Join Date: Mar 2004
Posts: 3
gbupc is on a distinguished road
Thank you very much for your reply.

I forwarded port 80 to my internal ip (192.168.0.3). Then I tried to access the server by the external ip, say 12.34.56.78 and it doesn't work. I'm not sure if this problem is due to the isp or the apache config. Do I need to change anything in the file called httpd.conf? Also, Is it possible to check if port 80 has been blocked or is there any way to change the listening port?

when i try to access the server, do i need to type the port number at the end like 12.34.56.78:80 as well?
gbupc is offline   Reply With Quote
Old 03-24-2004, 05:14 AM   #4 (permalink)
Registered User
 
Join Date: Dec 2001
Location: Adelaide, Australia
Posts: 5,267
Mickwish is on a distinguished road
Well, apache has to listen for something somewhere.

So, yes, you have to at least put where apache needs to listen in http.conf, otherwise it won't. You can use IP address, but a fully qualified domain name is preferred, as it easier for others to remember.

And you should be able to access apache once you have configured it by typing http://ipaddress. Just the ipaddress without the http:// may not work. Port number is not required unless it is different from port 80, as 80 is standard for http.

Hope this helps a bit.

What OS are you running Apache with, BTW?

Cheers
Mick
__________________
Testing, testing....
Mickwish is offline   Reply With Quote
Old 03-24-2004, 08:38 AM   #5 (permalink)
Registered User
 
Join Date: Mar 2004
Posts: 3
gbupc is on a distinguished road
Thank you for your reply.

I'm running WinXp pro, just wanna setup a server for testing my website...

Do I just need to add a line like
Listen xxx.xxx.xxx.xx
in the httpd.conf?

Do I need to modify "ServerName" in the file as well?

also, I don't know if I should put the internal ip or the external ip.

one more question, how to test if my server can be accessed from outside?
gbupc is offline   Reply With Quote
Old 03-24-2004, 08:47 PM   #6 (permalink)
Registered User
 
Join Date: Oct 2003
Location: Aztec, New Mexico
Posts: 176
MadMan2k is on a distinguished road
Heh, maybe asking someone to try and connect to it...
MadMan2k is offline   Reply With Quote
Old 03-24-2004, 09:22 PM   #7 (permalink)
Registered User
 
Join Date: Dec 2001
Location: Adelaide, Australia
Posts: 5,267
Mickwish is on a distinguished road
Check the Apache for Windows pages for install / config info.

According to them:
Quote:
After starting Apache running (either in a console window or as a service) it will be listening to port 80 (unless you changed the Port, Listen or BindAddress directives in the configuration files). To connect to the server and access the default page, launch a browser and enter this URL:

http://localhost/

This should respond with a welcome page, and a link to the Apache manual. If nothing happens or you get an error, look in the error.log file in the logs directory. If your host isn't connected to the net, you may have to use this URL:

http://127.0.0.1/

Once your basic installation is working, you should configure it properly by editing the files in the conf directory.
Then goes on to tell you what to config.

Hope this helps.

Cheers
Mick
__________________
Testing, testing....
Mickwish is offline   Reply With Quote
Reply




Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Most Active Discussions

Recent Discussions

All times are GMT -6. The time now is 02:12 PM.