Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
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.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
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.
|
 |
10-25-2003, 10:27 PM
|
#1
|
Member
Registered: Oct 2003
Location: Florida
Distribution: Slackware
Posts: 273
Rep:
|
Cant connect on port 80
Hello
I can connect to my local machine from my local machine, but when others try to connect from their computers, they get a timeout error on http. I am running apache, and I checked the logs but they dont report any attemped access. Why does this happen and how do I fix it?
|
|
|
10-26-2003, 12:05 AM
|
#2
|
Member
Registered: Mar 2003
Distribution: Slackware
Posts: 234
Rep:
|
You shouldn't have any firewall rules, but let's check anyway.
`iptables -L -n` ... Paste your output unless it's empty. It should just say INPUT, OUTPUT, and FORWARD with nothing listed under it.
Secondly, how do you connect to the internet? Dialup? Cable? If you have a cable modem, it's likely that your cable modem things people are trying to connect to it from the outside, so you have to forward port 80 from your cable modem to your linux box.
Next, `netstat -an | grep 80`. What interfaces are listening on port 80 on your machine? It should be listening on either 0.0.0.0:80 or 127.0.0.1:80 AND <ethx ip>:80 . If that isn't the case, go to your httpd.conf and make sure your "Listen" directive just says "Listen 80" instead of "Listen 127.0.0.1:80".
Hope this helps, post your results.
|
|
|
10-26-2003, 12:07 AM
|
#3
|
Member
Registered: Jul 2003
Location: Santiago, Chile
Distribution: Gentoo
Posts: 282
Rep:
|
Doy you have a modem or a router connected to your computer?, if so, make sure that you have forwarded the port to your computer.
|
|
|
10-26-2003, 12:53 AM
|
#4
|
Member
Registered: Oct 2003
Location: Florida
Distribution: Slackware
Posts: 273
Original Poster
Rep:
|
port 80
output of iptables:
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Also, if I am using a cable modem. how do I foreward port 80 to my linux box, and why does it already do this with other ports? It is an RCA modem.
Here is the output of netstat
netstat -an | grep 80
unix 2 [ ACC ] STREAM LISTENING 1040 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1726 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1723 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1716 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1712 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1700 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1678 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1675 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1662 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1657 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1645 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1639 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1613 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1563 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1483 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1470 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1449 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1444 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1438 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1428 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1418 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1410 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1387 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1384 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1366 /tmp/.ICE-unix/dcop980-
1067143319
unix 3 [ ] STREAM CONNECTED 1345 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1339 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1294 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1290 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1274 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1230 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1207 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1199 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1185 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1154 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1075 /tmp/.ICE-unix/dcop980- 1067143319
unix 3 [ ] STREAM CONNECTED 1060 /tmp/.ICE-unix/dcop980- 1067143319
|
|
|
10-26-2003, 01:49 AM
|
#5
|
Senior Member
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660
Rep:
|
Well it could be several problems. As mentioned above, there might be a firewall in the way (nope), or your http server might not be bound to (listening on) the Internet interface. The output above shows only UNIX sockets, so that's possible. To clean up the output a little use netstat -anA inet. Just paste all the output of that command (no grep).
Now if you connect to the Internet via a cable modem, it's quite possible that your ISP is actually blocking inbound HTTP requests. You mentioned that your friends are getting time-out errors, which means somewhere a firewall is silently dropping packets. If it was your computer not listening on the right port they would get a connection refused instead of time-out.
You are probably going to end up needing to use a non-standard port for your HTTP server, which will make the normal method of connecting to it not work (well, it doesn't work now any way, so no big loss). You could use a "web-hop" service to redirect all HTTP requests at your site to your custom port. I know that dyndns.org offers such a service.
|
|
|
10-26-2003, 04:31 AM
|
#6
|
Member
Registered: Mar 2003
Distribution: Slackware
Posts: 234
Rep:
|
Excellent post by chort.
I'm not a GUI guy, so netstat -an doesn't give me a buttload of UNIX sockets, so I suggest it to people as habit cause I do it myself. chort had a better method. Try that first, to clean up your output and see if you have a http service running.
To forward ports from your cable modem, most modems have an admin console or http access. Read the man on your modem to find out how to access it and how to forward ports from it. If you don't have the printed documentation, in most cases Google can provide it for you.
To find out for sure if your ISP is filtering out inbound port 80 requests to their clients, it's best to call them and ask. Some ISPs find this an efficient way of blocking www servers running off their pipe (why?). chort offers an effective way of getting around that.
|
|
|
All times are GMT -5. The time now is 03:43 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|