Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
1. linksys router -- set for DHCP yet retains same ip for long period of time from ISP
2. Apache 2.0 running under Fedora Core 1
3. No DNS setup (may not need it)
Question:
Can I run a website and access it using whatever DHCP ip the router is set for (obviousely cant use names cause I have no DNS) ??? or is it not possible?
Note:
I have 3 computers under that router
1. Windows 2000 ..................... (static illegal ip -- 192.168.1.100)
2. Windows 2000 Advanced server (static illegal ip -- 192.168.1.101)
3. Fedora Core 1 ...................... (static illegal ip -- 192.168.1.102)
and those are not static IPs, unless you have modified your linksys router, and manually set those IP addresses, those are being dynamically assigned by your router. Linksys (by default) starts assigning IPs at 100. therefore you should set your satic IPs below that.
DNS:
I've posted this before. If you want to work around DNS use your system's hosts file. in windows I commonly see it in %windows%\system32\drivers\etc\hosts
If you work around DNS you can access your server by name, otherwise you'll have to use IP
i mean is it possible to access the web page from outside. I dont think you can access it with DNS since its not registered anywhere. So is it possible to access it through ip? I guess port has to be 80? or 8080? or 8888?
you need to pass port 80 (assuming you haven't changed that in your apache conf file) to your linux box from your linksys router... then you can access it externally using your linksys external IP...
assuming that your linksys router is under a cable/dsl modem, you also need to pass your Internet IP from your modem to your linksys router, then your linux box can be gotten from anywhere using your Internet IP
If your ISP blocks port 80, then you have to pass another port through the router and setup Apache for that port. You may also want to check out http://www.dyndns.org
I opened up port 80 on linksys router and forwarded it into my FC1 linux box the ip of linux box is (192.168.1.5). This is setup in linksys router now.
I started Apache2.0 but it gave me this message which means i have no dns. The message is as follows:
"httpd: Could not determine the server's fully qualified domain name, using 192.168.1.5 for ServerName"
I replaced a default webpage with a custom page just for testing purposes.
When I enter my valid internet address into web browser i get when Im inside the network behind the router I see the page fine. And that works with local ip address and internet ip address.
When I enter internet ip address from outside of my network I get page not found. So something is wrong. Any help/advice would be appreciated - Thanks
sorry for mistake in last message the error says "The page cannot be displayed" once again this is not a "page not found" which is usually error 404 instead this is something else. Meaning it cant even reach the server something
Ok i got it working. I opened up port 8000 on linksys router, and binded httpd port to 8000. To bind it from 80 to 8000 I had to edit httpd.conf file and set
#Listen 80
Listen 8000
The configuration file is inside /etc/httpd/conf directory.
You can check if httpd is binded to the port by issuing this command
netstat -lpn | grep httpd
It will give you SSL and httpd binded ports. If you see httpd binded to somthing like 0.0.0.0:80 then you did something wrong. If you see it binded to 0.0.0.0:8000 then you good to go.
Some ISP's block port 80 so thats why you need to bind it to port 8000
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.