Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Apache server on a Broadband Connectiion

Posted on 2004-09-21
4
Medium Priority
?
281 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 15

Accepted Solution

by:
samri earned 400 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

[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

Question has a verified solution.

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

In my time as an SEO for the last 2 years and in the questions I have assisted with on here I have always seen the need to redirect from non-www urls to their www versions. For instance redirecting http://domain.com (http://domain.com) to http…
In Solr 4.0 it is possible to atomically (or partially) update individual fields in a document. This article will show the operations possible for atomic updating as well as setting up your Solr instance to be able to perform the actions. One major …
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

722 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