[users@httpd] Apache 2 on Suse 9.1 Reverse Proxy not working

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

 



Hi all,

I have tried to use the Apache Week article to set up reverse proxy. It is being installed on a SuSE 9 Linux x86 box running Apache 2. I have configured it as per the notes, but am getting errors which I'm thinking is to do with the rewriting of the URL. Below is the error messages, as well as the configuration.

The only thing which I've done different, is to use a copy of the mod_proxy_html.so from a mandrake rpm (for x586).



******
Steps
******
Precursor:
Set up Reverse Proxy as per Apache Week page (http://www.apacheweek.com/features/reverseproxies)
NOTE: Difference is that I removed trailing / from ProxyPass commands

1. issue the following URL: http://lucas.delexian.com/ocs
2. Server responds with rewrite of URL: http://lucas.delexian.com/welcome/index.jsp
3. However, server message is:
Object not found!
The requested URL was not found on this server. If you entered the URL manually please check your spelling and try again. 

If you think this is a server error, please contact the webmaster. 

Error 404
lucas.delexian.com
Wed Feb 15 00:09:03 2006
Apache/2.0.49 (Linux/SuSE) 

****************
Apache Error Log
****************

[Wed Feb 15 00:08:58 2006] [notice] SIGUSR1 received. Doing graceful restart
[Wed Feb 15 00:08:58 2006] [info] Init: Initializing OpenSSL library
[Wed Feb 15 00:08:58 2006] [info] Init: Seeding PRNG with 0 bytes of entropy
[Wed Feb 15 00:08:58 2006] [info] Init: Generating temporary RSA private keys (512/1024 bits)
[Wed Feb 15 00:08:59 2006] [info] Init: Generating temporary DH parameters (512/1024 bits)
[Wed Feb 15 00:08:59 2006] [info] Init: Initializing (virtual) servers for SSL
[Wed Feb 15 00:08:59 2006] [info] Server: Apache/2.0.49, Interface: mod_ssl/2.0.49, Library: OpenSSL/0.9.7d
[Wed Feb 15 00:08:59 2006] [notice] Apache/2.0.49 (Linux/SuSE) configured -- resuming normal operations
[Wed Feb 15 00:08:59 2006] [info] Server built: Jun 30 2004 22:22:01
[Wed Feb 15 00:08:59 2006] [debug] worker.c(1631): AcceptMutex: sysvsem (default: sysvsem)
[Wed Feb 15 00:09:03 2006] [debug] proxy_http.c(66): proxy: HTTP: canonicalising URL //lucas.delexian.com:8009
[Wed Feb 15 00:09:03 2006] [debug] mod_proxy.c(416): Trying to run scheme_handler
[Wed Feb 15 00:09:03 2006] [debug] proxy_http.c(1042): proxy: HTTP: serving URL http://lucas.delexian.com:8009/
[Wed Feb 15 00:09:03 2006] [debug] proxy_http.c(178): proxy: HTTP connecting http://lucas.delexian.com:8009/ to lucas.delexian.com:8009
[Wed Feb 15 00:09:03 2006] [debug] proxy_util.c(1160): proxy: HTTP: fam 2 socket created to connect to lucas.delexian.com
[Wed Feb 15 00:09:03 2006] [debug] proxy_http.c(327): proxy: socket is connected
[Wed Feb 15 00:09:03 2006] [debug] proxy_http.c(361): proxy: connection complete to 192.168.0.100:8009 (lucas.delexian.com)
[Wed Feb 15 00:09:03 2006] [debug] proxy_http.c(939): proxy: header only
[Wed Feb 15 00:09:03 2006] [error] [client 192.168.0.1] File does not exist: /srv/www/htdocs/welcome

*****************
Apache Access Log
*****************

192.168.0.1 - - [15/Feb/2006:00:06:44 -0800] "GET /ocs/ HTTP/1.1" 304 - "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)"
192.168.0.1 - - [15/Feb/2006:00:06:45 -0800] "GET /welcome/index.jsp HTTP/1.1" 404 1050 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)"
192.168.0.1 - - [15/Feb/2006:00:07:29 -0800] "GET /ocs/ HTTP/1.1" 304 - "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)"
192.168.0.1 - - [15/Feb/2006:00:07:29 -0800] "GET /welcome/index.jsp HTTP/1.1" 404 1050 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)"
192.168.0.1 - - [15/Feb/2006:00:08:07 -0800] "GET /ocs/ HTTP/1.1" 304 - "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)"
192.168.0.1 - - [15/Feb/2006:00:08:07 -0800] "GET /welcome/index.jsp HTTP/1.1" 404 1050 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)"
192.168.0.1 - - [15/Feb/2006:00:08:32 -0800] "GET /ocs HTTP/1.1" 404 1050 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)"
192.168.0.1 - - [15/Feb/2006:00:09:03 -0800] "GET /ocs HTTP/1.1" 304 - "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)"
192.168.0.1 - - [15/Feb/2006:00:09:03 -0800] "GET /welcome/index.jsp HTTP/1.1" 404 1050 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)"


*****************
httpd.conf.local
*****************

# Delexian Reverse proxy setup
LoadModule proxy_module /usr/lib/apache2-worker/mod_proxy.so
LoadModule proxy_http_module /usr/lib/apache2-worker/mod_proxy_http.so
#LoadModule proxy_ftp_module /usr/lib/apache2-worker/mod_proxy_ftp.so
#LoadModule proxy_connect_module /usr/lib/apache2-worker/mod_proxy_connect.so
LoadModule headers_module /usr/lib/apache2-worker/mod_headers.so
LoadModule deflate_module /usr/lib/apache2-worker/mod_deflate.so
LoadFile /usr/lib/libxml2.so.2
LoadModule proxy_html_module /usr/lib/apache2-worker/mod_proxy_html.so

ProxyRequests off
ProxyPass /ocs http://lucas.delexian.com:8009
ProxyPass /fin http://moya.delexian.com:8003
ProxyHTMLURLMap http://lucas.delexian.com:8009 /ocs
ProxyHTMLURLMap http://moya.delexian.com:8003 /fin

<Location /ocs/>
ProxyPassReverse /
SetOutputFilter proxy-html
ProxyHTMLURLMap / /ocs/
ProxyHTMLURLMap /ocs /ocs
RequestHeader unset Accept-Encoding
</Location>

<Location /fin/>
ProxyPassReverse /
SetOutputFilter proxy-html
ProxyHTMLURLMap / /fin/
ProxyHTMLURLMap /fin /fin
RequestHeader unset Accept-Encoding
</Location>


ProxyHTMLLogVerbose On
LogLevel Debug


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-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