LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 09-05-2003, 03:56 AM   #1
Shade
Senior Member
 
Registered: Mar 2003
Location: Burke, VA
Distribution: RHEL, Slackware, Ubuntu, Fedora
Posts: 1,418
Blog Entries: 1

Rep: Reputation: 46
Apache behind router?


Hey all, I'm trying to set up a basic webserver here as a project, and mirrored an old site of mine to hard drive, installed Apache 1.3.28 and edited my httpd.conf file to how it should look.

Listening on port 80, pointing to the right Document directory, etc.

httpd starts without a problem, but when I or a friend try to access it, connection always times out.

http://mshade.kicks-ass.net

is the address that should be working.
I have it set up through dyndns and I've verified that the router responds to pings, etc from the domain name.

Help?

I've already set up my FreeSco router to forward ports 80, 8080, and 8000 to port 80 on my linux box, ip 192.168.1.10 NAT'd behind the router.
I did that to determine whether my ISP might have been blocking requests on port 80.

Iptables is not running on my system.

What else should I check?

-Shade
 
Old 09-05-2003, 04:09 AM   #2
AltF4
Member
 
Registered: Sep 2002
Location: .at
Distribution: SuSE, Knoppix
Posts: 532

Rep: Reputation: 31
http://mshade.kicks-ass.net:8080/ works fine for me
probably port 80 is blocked or not forwarded correctly
 
Old 09-05-2003, 04:17 AM   #3
Shade
Senior Member
 
Registered: Mar 2003
Location: Burke, VA
Distribution: RHEL, Slackware, Ubuntu, Fedora
Posts: 1,418

Original Poster
Blog Entries: 1

Rep: Reputation: 46
Hmm....

here's the lines in portfw.cfg (port forwarding config file freesco reads)

tcp,8000,80,192.168.1.10
tcp,80,80,192.168.1.10
tcp,8080,80,192.168.1.10

according to that, all three 8000 8080 and 80 should forward to port 80 on my machine...
Looks like my isp doesn't want me running a webserver and blocked port 80.
Any other things it could be?
-Shade
 
Old 09-05-2003, 04:42 AM   #4
born4linux
Senior Member
 
Registered: Sep 2002
Location: Philippines
Distribution: Slackware, RHEL&variants, AIX, SuSE
Posts: 1,127

Rep: Reputation: 49
contact your isp.
 
Old 09-05-2003, 06:40 AM   #5
WiWa
Member
 
Registered: Aug 2003
Distribution: Redhat 9.0, Fedora Core, Suse 9.1, Mandrake
Posts: 82

Rep: Reputation: 15
I ahve had a similar problem with my ADSL router. Could it be that your Router has an internal webserver (to configure the device) that works on port 80. Whenever you try to connect to your website, it actually goes to port 80, which is the router webserver.

I solved it through forcing my 'router webserver' to work on another port (in my case 82). Another way is to setup your httpd to use port 81 and leave the router on port 80.

Is this of help?

WIWA
 
Old 09-06-2003, 05:28 AM   #6
Shade
Senior Member
 
Registered: Mar 2003
Location: Burke, VA
Distribution: RHEL, Slackware, Ubuntu, Fedora
Posts: 1,418

Original Poster
Blog Entries: 1

Rep: Reputation: 46
Yup. I got a response from my ISP via Email --

"Thank you for your email. I understand you're inquiring if Cox block
incoming port 80 requests. To protect our customers, certain ports
are filtered and port 80 is one of them. And by doing so, we can
protect them from certain common worms and protect them from running
dangerous services on their computers that could allow intruders
access."

Doh.
Any way around this?

-Shade
 
Old 09-06-2003, 02:39 PM   #7
WiWa
Member
 
Registered: Aug 2003
Distribution: Redhat 9.0, Fedora Core, Suse 9.1, Mandrake
Posts: 82

Rep: Reputation: 15
You could try to force your Apache server listening to port 81. That should work...
 
Old 09-06-2003, 10:22 PM   #8
Shade
Senior Member
 
Registered: Mar 2003
Location: Burke, VA
Distribution: RHEL, Slackware, Ubuntu, Fedora
Posts: 1,418

Original Poster
Blog Entries: 1

Rep: Reputation: 46
Isn't that for an HTTPS server though?

Hmm... I will try that.

-Shade
 
Old 09-06-2003, 11:10 PM   #9
shellcode
Member
 
Registered: May 2003
Location: Beverly Hills
Distribution: Slackware, Gentoo
Posts: 350

Rep: Reputation: 32
https is port 443
 
Old 09-07-2003, 01:27 AM   #10
Shade
Senior Member
 
Registered: Mar 2003
Location: Burke, VA
Distribution: RHEL, Slackware, Ubuntu, Fedora
Posts: 1,418

Original Poster
Blog Entries: 1

Rep: Reputation: 46
But then.. How would setting apache to port 81 help anymore than having my router forward all ports, like 80, 81, 8000, 8080 to 80 on my server?

What would be any different?

-Shade
 
Old 09-07-2003, 04:24 PM   #11
chort
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: Reputation: 76
No, it's no different. Your problem is that you need to setup a port redirect externally. Some dynamic DNS providers will do this (I have no idea how). Normally when people type in http://www.google.com in their browser it goes to port 80 on google's IP address.

In your case with http://mshade.kicks-ass.net it will use port 80 since that's the reserved port for http. Basically when a browser sees the "http" part it interprets that as "port 80". Likewise if someone types in "https" that will be translated to "port 443". Since your ISP is being "helpful" and blocking those ports, you must use a different port for your webserver.

That means any time you post a link on the Internet to your website it must be http://mshade.kicks-ass.net:81 or something like that. You'll always have to specify the port, because otherwise the browser will automatically go to 80 and that's blocked.

The only way around it is to setup an external port redirect so that before they connect to your website, port 80 is changed to port 81. Like I said, I think some dynamic DNS providers can do this. The alternative is to cancle your contract with that crappy ISP and get a DSL connection (or a different ISP) that does allow inbound connections to port 80. Before you switch to a new ISP, make sure to ask them if they block any ports coming in. I have speakeasy.net and they actually advertise as being "server friendly". They don't block any ports, which is fantastic.
 
Old 09-08-2003, 02:32 AM   #12
Shade
Senior Member
 
Registered: Mar 2003
Location: Burke, VA
Distribution: RHEL, Slackware, Ubuntu, Fedora
Posts: 1,418

Original Poster
Blog Entries: 1

Rep: Reputation: 46
That IS fantastic, but unfortunately I'm relatively sure that Cox is the only cable provider at my specifc address.

By the way, Thanks Chort.

I knew that's what I had to do from the beginning, but I was just trying to find out if there was some internal way around it.

DynDNS.com which i'm using, doesn't provide port redirection, unfortunately... At least not that I'm able to find.

They say you can, but then I'd have to change domains again, and I'd not like to do that. Its all a bit confusing, how they've got it all set up.

I'll do more research there, but for now I've been posting http://mshade.kicks-ass.net:8080 as my site address. It's just a pain to have to add that.

Thanks,
-Shade
 
Old 09-08-2003, 02:38 AM   #13
Shade
Senior Member
 
Registered: Mar 2003
Location: Burke, VA
Distribution: RHEL, Slackware, Ubuntu, Fedora
Posts: 1,418

Original Poster
Blog Entries: 1

Rep: Reputation: 46
UPDATE

dyndns.org does indeed offer a service, WebHOP which gives you a different domain, but allows invisible port redirection.

so now the site is:

mshade.endofinternet.net

-Shade

ps- hope this service will help others with ISPs that block port 80.
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Running Apache Through a Router jimsproch Linux - Software 2 10-26-2004 02:40 AM
Apache/router(?) problems Dill Linux - Networking 3 09-23-2004 12:33 AM
Viewing apache via router sy-co Mandriva 6 06-20-2004 04:12 PM
Setting up apache behind a router gauntalus Linux - Networking 12 05-31-2004 07:02 PM
apache server from behind router drigz Linux - Networking 4 05-16-2004 02:31 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 03:30 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration