Solved

Apache server on a Broadband Connectiion

Posted on 2004-09-21
4
277 Views
Last Modified: 2010-03-04
HI

I have Xp pro and Apache 2 and PHP 4 with Mysql as well.I have  a Maconi DSL router that
does not allow port forwarding , or it does  not work ( thats as per the Router support desk atleast)

I have created a PPoE connection via windows Xp internet setup and I can access the Internet.
On that very same PC I have my web server setup and websites on that server can be viewed internally and externally without a problem.

Now what I have done is created a network on 5 PCs and My Lan accesses the internet via the server,similiar  to Internet Connection Sharing.

i want to change the web server to another PC on the lan so basically the PC that will be connected to the router and eventually to the internet will not be the web server.

I I am stuck here,I know that if I had a router that supported port forwarding I would be able to do that but how do I direct the request that is made from the internet from the PC connected to the internet to another PC on that lan  that is actiually running the web server.

I am also using dynamic dns as well.

Thanks
Praveen


0
Comment
Question by:praveen123456
4 Comments
 
LVL 15

Accepted Solution

by:
samri earned 100 total points
ID: 12134080
hi Praveen,

So basically, how did you access your webserver from internet?  Based on your information, you had the machine that is connected to the Internet to use dynamic dns service.  So user basically could do, for example http://praveen.homeip.net/ (for example if you are using DynDNS), and it would hit your XP machine (which is connected to the router, and is sharing the connection).  Lets called this machine MachineA (internal IP : 192.168.0.1)

If I got it right, this machine is not movable - but you want to delegate the web server function to another machine on the LAN.  LEt say -- we call this machine "MachineB" (Internal IP : 192.168.0.2).

Since you are running Apache2 on MachineA, you could use ReverseProxy capability of Apache to make this to work.  Take a look apache proxy modules (http://httpd.apache.org/docs-2.0/mod/mod_proxy.html)

Specifically, you would jump to forware/reverse proxy section : http://httpd.apache.org/docs-2.0/mod/mod_proxy.html#forwardreverse

--
basic example;

ProxyRequests Off

<Proxy *>

Order deny,allow
Allow from all

</Proxy>

ProxyPass / http://192.168.0.2/
ProxyPassReverse / http://192.168.0.2/
--
should do the work.

To explore further: to make things more interesting, you may add this section in a VirtualHost section (http://httpd.apache.org/docs-2.0/vhosts/) on MachineA, and if your Dynamic DNS provider does support wildcard, you may have www.praveen.homeip.net (dyndns does support wildcard), www2.praveen.homeip.net, blah blah

And in your Apache on machineA, you could have multiple VirtualHost that is doing ReverseProxy of different machine on your LAN.
Cool huh!


0
 

Author Comment

by:praveen123456
ID: 12139430
Hi Samri

This is brilliant

I never thought that  this was possible, hence I must add I never thought of looking for it in the apache doc.

So just to confirm my Machine B will listen to the IP of mahine A and that will be on Port 80.

I think thats it from me if that is  the case.

Thanks Again
Praveen
0

Featured Post

Building an interactive eFuture classroom

Watch and learn how ATEN provided a total control system solution including seamless switching matrix switch, HDBaseT extenders, PDU, lighting control to build an interactive eFuture classroom.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you've heard about htaccess and it sounds like it does what you want, but you're not sure how it works... well, you're in the right place. Read on. Some Basics #1. It's a file and its filename is .htaccess (yes, with a dot in the front). #…
If your site has a few sections that need to be secure when data is transmitted between the server and local computer, such as a /order/ section for ordering or /customer/ which contains customer data, etc it would of course be recommended to secure…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

685 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question