Apache2 Proxy, send user to another webserver?

Kernels & Hardware, configuring network, installing services

Apache2 Proxy, send user to another webserver?

Postby Storsnusarn^ » 2017-02-20 15:22

I have been running something similar before and it has been working perfectly for my needs, however due to a crash i had to reinstall my machines and when coming to the webserver i can't seem to get the proxy-settings to work very well anymore.

Here is my setup:

  • Server_1 - This is my main webserver that gets all requests from the internet, this is where i have all virtualhosts to several webpages, most of them stored at diffrient locations on this server. IP-adress: (Debian Stable, Apache 2.4)
  • Server_2 - This is the second webserver not exposed to the internet (port 80 and 443 invisable), on this server i only want to serve one page, the default htdocs-directory. IP-adress: (Windows Server 2008 R2, Apache 2.4)

On Server_1 i have been seiing up one virtualhost like following:
Code: Select all
<VirtualHost *:80>
   ServerName mydomain.no-ip.com
   ProxyPass /
   ProxyPassReverse /
   ProxyPreserveHost On
   ProxyRequests Off

<Location /phpmyadmin>
   Order Deny,Allow
   Deny from all
   Allow from
   Allow from
   Allow from
   Allow from


And i have been a2enmod proxy, proxy_http and proxy_html on the same server.

What i believe this was the only thing i had to do back in the days but appearently it doesn't work at all; if i try to connect to my hostname in a browser (yes i have tried outside my own network too), i'm being sent to my default host (000-default) instead and that indicates that the IP is pointed correctly but something must be wrong with my configuration.

Would really be happy for some help :-) Thanks! // Storsnusarn^

Edit: Problem solved, somehow i was right :mrgreen:
Posts: 15
Joined: 2015-10-29 00:39

Return to System configuration

Who is online

Users browsing this forum: No registered users and 5 guests