home hardware prices news articles forums photos user reviews
Go Back   Tech Support Forums - TechIMO.com > PC Hardware and Tech > Networking and Internet
Reply

How to set up an apache server behind a router with dynamic IP addresses

 
Thread Tools Search this Thread
Currently Active Users: 1502
Discussions: 220,964, Posts: 2,603,388, Members: 272,797
Get bargains at  »  Dealighted.com
Old March 24th, 2004, 05:48 AM     #1 (permalink)
Junior Member
 
Join Date: Mar 2004
Posts: 3
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 March 24th, 2004, 06:32 AM     #2 (permalink)
Not Really a Member
 
Join Date: Oct 2001
Posts: 27,778

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.
__________________
Helicopters don't fly; they vibrate so much and make so much noise that the earth rejects them.
vass0922 is offline   Reply With Quote
Old March 24th, 2004, 07:07 AM     #3 (permalink)
Junior Member
 
Join Date: Mar 2004
Posts: 3

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 March 24th, 2004, 07:14 AM     #4 (permalink)
Swine flu stopper
 
Mickwish's Avatar
 
Join Date: Dec 2001
Location: BrisVegas, Australia
Posts: 11,748
Blog Entries: 1

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
__________________
I don't like sigs on forums like this.
Mickwish is offline   Reply With Quote
Old March 24th, 2004, 10:38 AM     #5 (permalink)
Junior Member
 
Join Date: Mar 2004
Posts: 3

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 March 24th, 2004, 10:47 PM     #6 (permalink)
Ultimate Member
 
Join Date: Oct 2003
Location: Aztec, New Mexico
Posts: 1,609
Send a message via AIM to MadMan2k Send a message via MSN to MadMan2k

Heh, maybe asking someone to try and connect to it...
__________________
jonbuder.com
MadMan2k is offline   Reply With Quote
Old March 24th, 2004, 11:22 PM     #7 (permalink)
Swine flu stopper
 
Mickwish's Avatar
 
Join Date: Dec 2001
Location: BrisVegas, Australia
Posts: 11,748
Blog Entries: 1

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
Mickwish is offline   Reply With Quote
Ask a Tech Question (free)!
Most Active Discussions
Look who the cat dragged in... (15)
Is It Just Me? (3752)
This is evidence (19)
Diablo 3 is out! (13)
Need some help determining possible.. (9)
help with pesky laptop screen wire! (8)
F@H **Official** SPAM Thread 2012-0.. (478)
Intel(R) G45"G43 Express Chips.. (6)
How could wrong Amperage affect a l.. (29)
Recent Discussions
XP has gone cyclic missing SXS file o.. (6)
Tech support interview questions (1)
Edit file exe 16bit (3)
Building a gaming computer (0)
Windows 9 Internet Explorer rememberi.. (1)
Diablo 3 is out! (13)
Computer Memory (RAM) and Hard Drive .. (28)
F@H **Official** SPAM Thread 2012-02-.. (478)
Search Babylon (1)
Sound Muffled/Distorted, need help. (9)
1.163v safe for GTS 450? (1)
New GTS 450 freezing PC (29)
Display Problem (1)
Need some help determining possible u.. (9)
Viewing problem: HELP! (2)
Choosing a new graphics card (4)
my graphics card is not working (0)
my graphics card doesn't work (0)
H Martens (1)
Cloning a hard drive to DVD (12)
Want to restore outlook express addre.. (0)
Oh boy... lol (comp wont boot) (1)
remove network.connection (2)
Replace non working graphic card (0)
Reinstalled XP over existing XP but u.. (2)

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search


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

All times are GMT -4. The time now is 12:52 AM.
TechIMO Copyright 2012 All Enthusiast, Inc.



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28