Reverse Proxy server show "Service Unavailable".

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,
I created two VMs in the VirtualBox. One of them is Reverse Proxy server and another one is Apache Web Server.
The specifications of VM1 (Reverse Proxy) are as follows:
NIC 1 is NAT and Its IP address is "10.0.3.15".
NIC 2 is Internal Network and its IP address is "192.168.1.3".


The specifications of VM2 (Apache Web Server) are as follows:
It has one NIC and its IP address is "192.168.1.4".


Both VMs can see each other. I installed Apache Web Server on the both machines and opened ports 80 and 443 via Firewalld on them:


# firewall-cmd --list-all
FedoraServer (active)
  target: default
  icmp-block-inversion: no
  interfaces: enp0s3
  sources: 
  services: cockpit dhcpv6-client ssh
  ports: 80/tcp 443/tcp
  protocols: 
  masquerade: no
  forward-ports: 
  source-ports: 
  icmp-blocks: 
  rich rules: 


My goal is:


The Internet --> Reverse Proxy (VM1) --> Apache Web Server (VM2)


On the VM1, I did:


# curl http://192.168.1.4
<html>
    <head>
        <title> This my server. </title>
    </head>
    <body>
        <p> Apache Server. </p>
    </body>
</html>


And as you see, it can see VM2 Apache Web Server.
On the VM1, I created a Virtual Host configuration file as below:


# touch /etc/httpd/conf.d/reverse.conf
# nano /etc/httpd/conf.d/reverse.conf


And fill it with below lines:


<VirtualHost *:80>
        ProxyPreserveHost On
        ProxyPass / http://192.168.1.4/
        ProxyPassReverse / http://192.168.1.4/
</VirtualHost>


Then restarted the Apache Web Server.
When I entered VM1 IP address, then I must see the VM2 "index.html" file, but I see below error:


Service Unavailable
The server is temporarily unable to service your request due to maintenance downtime or capacity problems. Please try again later.


Why?


Thanks.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx





[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux