ah. yes. that's done it.
Thanks.
Grégory Joseph wrote:
help.html happens to be the default virtual uri mapping for / on public
instances, maybe that's an hint that their configuration isn't really
complete ?
-g
On Jan 31, 2008, at 13:30 , Paul Worrall wrote:
hi
info
magnolia 3.5.2 EE
Apache 2 with ajp
Objective
I am trying to get it so that the customer many other domainames
result in a redirect to the parent domain name. Anything for
www.customer.com is past to a magnolia instance on tomcat over AJP.
[see first virtual host below]
Problem
All the redirects virtual hosts entried work. Rewriting the url's and
redirecting the browser to the main virtual host that forwards it on
to tomcat/magnolia.
However, the simple www.company.com results in a blank page with the
url http://www.company.com/public/help.html .
I can't see anything untoward in the apache conf and this
configuration is working in another environment.
Any ideas why the /help.html is happening ?
I have a feeling it is something to fo with the new module/magnola
registration after seeing the following lines in the apache log..
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(484):
ajp_unmarshal_response: status = 302
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(495):
ajp_unmarshal_response: Number of headers is = 4
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(557):
ajp_unmarshal_response: Header[0] [Magnolia-Registration] = [Registered]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(557):
ajp_unmarshal_response: Header[1] [Location] =
[http://www.simonsgroup.com/public/help.html]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(557):
ajp_unmarshal_response: Header[2] [Content-Type] =
[text/html;charset=UTF-8]
Full Apache log file for the request is below.
>>httpd.conf<<
NameVirtualHost *:80
<VirtualHost *:80>
ProxyRequests Off
ProxyPreserveHost On
ServerName www.customer.com
<Location / >
Allow from all
ProxyPass ajp://127.0.0.1:8009/
ProxyPassReverse ajp://127.0.0.1:8009/
RewriteEngine on
RewriteRule ^proxy:ajp://127.0.0.1:8009/$ \
ajp://127.0.0.1:8009/public/ [P]
</Location>
</VirtualHost>
<VirtualHost *:80>
ProxyRequests Off
ProxyPreserveHost On
ServerName www.customerothername.com
RewriteEngine on
RewriteCond %{HTTP_HOST} ^www\.customerothername\.com$ [NC]
RewriteRule ^/(.*)
http://www.customer.com/public/section/page.html [L,R]
</VirtualHost>
>>> Apache Log file <<<
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(44): proxy: AJP:
canonicalising URL //127.0.0.1:8009/
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1378): [client
82.71.106.126] proxy: ajp: found worker ajp://127.0.0.1:8009/ for
ajp://127.0.0.1:8009/public/
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy.c(756): Running scheme
ajp handler (attempt 0)
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_http.c(1652): proxy:
HTTP: declining URL ajp://127.0.0.1:8009/public/
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(496): proxy: AJP:
serving URL ajp://127.0.0.1:8009/public/
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1798): proxy: AJP: has
acquired connection for (127.0.0.1)
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1858): proxy:
connecting ajp://127.0.0.1:8009/public/ to 127.0.0.1:8009
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1951): proxy:
connected /public/ to 127.0.0.1:8009
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(218): Into
ajp_marshal_into_msgb
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[0] [Accept-Encoding] = [gzip, deflate]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[1] [Host] = [www.simonsgroup.com]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[2] [User-Agent] = [Mozilla/5.0 (Windows;
U; Windows NT 5.1; en-US; rv:1.8.1.11) Gecko/20071127 Firefox/2.0.0.11]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[3] [Accept] =
[text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[4] [Accept-Language] = [en-gb]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[5] [---------------] = [------------]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[6] [Accept-Charset] =
[ISO-8859-1,utf-8;q=0.7,*;q=0.7]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[7] [Keep-Alive] = [300]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[8] [Connection] = [keep-alive]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[9] [Cookie] =
[__utmz=2502066.1199714371.1.1.utmccn=(direct)|utmcsr=(direct)|utmcmd=(none);
__utma=2502066.2111342333.1199714371.1201774549.1201778122.4;
__utmc=2502066; __utmb=2502066]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[10] [Max-Forwards] = [10]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(424):
ajp_marshal_into_msgb: Done
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(186): proxy:
APR_BUCKET_IS_EOS
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(191): proxy: data
to read (max 8186 at 4)
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(206): proxy: got 0
bytes of data
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(643): ajp_read_header:
ajp_ilink_received 04
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(653): ajp_parse_type:
got 04
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(484):
ajp_unmarshal_response: status = 302
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(495):
ajp_unmarshal_response: Number of headers is = 4
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(557):
ajp_unmarshal_response: Header[0] [Magnolia-Registration] = [Registered]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(557):
ajp_unmarshal_response: Header[1] [Location] =
[http://www.simonsgroup.com/public/help.html]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(557):
ajp_unmarshal_response: Header[2] [Content-Type] =
[text/html;charset=UTF-8]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(567):
ajp_unmarshal_response: ap_set_content_type done
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(557):
ajp_unmarshal_response: Header[3] [Content-Length] = [0]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(643): ajp_read_header:
ajp_ilink_received 05
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(653): ajp_parse_type:
got 05
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(439): proxy: got
response from 127.0.0.1:8009 (127.0.0.1)
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1816): proxy: AJP: has
released connection for (127.0.0.1)
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(44): proxy: AJP:
canonicalising URL //127.0.0.1:8009/public/help.html
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1378): [client
82.71.106.126] proxy: ajp: found worker ajp://127.0.0.1:8009/ for
ajp://127.0.0.1:8009/public/help.html
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy.c(756): Running scheme
ajp handler (attempt 0)
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_http.c(1652): proxy:
HTTP: declining URL ajp://127.0.0.1:8009/public/help.html
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(496): proxy: AJP:
serving URL ajp://127.0.0.1:8009/public/help.html
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1798): proxy: AJP: has
acquired connection for (127.0.0.1)
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1858): proxy:
connecting ajp://127.0.0.1:8009/public/help.html to 127.0.0.1:8009
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1951): proxy:
connected /public/help.html to 127.0.0.1:8009
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(218): Into
ajp_marshal_into_msgb
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[0] [Accept-Encoding] = [gzip, deflate]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[1] [Host] = [www.simonsgroup.com]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[2] [User-Agent] = [Mozilla/5.0 (Windows;
U; Windows NT 5.1; en-US; rv:1.8.1.11) Gecko/20071127 Firefox/2.0.0.11]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[3] [Accept] =
[text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[4] [Accept-Language] = [en-gb]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[5] [---------------] = [------------]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[6] [Accept-Charset] =
[ISO-8859-1,utf-8;q=0.7,*;q=0.7]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[7] [Keep-Alive] = [300]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[8] [Connection] = [keep-alive]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[9] [Cookie] =
[JSESSIONID=35A8E059E40911A61619C46A8768A1BC;
__utmz=2502066.1199714371.1.1.utmccn=(direct)|utmcsr=(direct)|utmcmd=(none);
__utma=2502066.2111342333.1199714371.1201774549.1201778122.4;
__utmc=2502066; __utmb=2502066]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(284):
ajp_marshal_into_msgb: Header[10] [Max-Forwards] = [10]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(424):
ajp_marshal_into_msgb: Done
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(186): proxy:
APR_BUCKET_IS_EOS
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(191): proxy: data
to read (max 8186 at 4)
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(206): proxy: got 0
bytes of data
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(643): ajp_read_header:
ajp_ilink_received 04
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(653): ajp_parse_type:
got 04
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(484):
ajp_unmarshal_response: status = 404
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(495):
ajp_unmarshal_response: Number of headers is = 2
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(557):
ajp_unmarshal_response: Header[0] [Magnolia-Registration] = [Registered]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(557):
ajp_unmarshal_response: Header[1] [Content-Type] =
[text/html;charset=UTF-8]
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(567):
ajp_unmarshal_response: ap_set_content_type done
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(643): ajp_read_header:
ajp_ilink_received 05
[Thu Jan 31 12:18:33 2008] [debug] ajp_header.c(653): ajp_parse_type:
got 05
[Thu Jan 31 12:18:33 2008] [debug] mod_proxy_ajp.c(439): proxy: got
response from 127.0.0.1:8009 (127.0.0.1)
[Thu Jan 31 12:18:33 2008] [debug] proxy_util.c(1816): proxy: AJP: has
released connection for (127.0.0.1)
--
Paul Worrall
INTERITION - Java Open Source Software Services
Keep informed with the JOSS4BIZ Podcast at
http://joss4biz.interition.net
w: www.interition.net
m: +44 (0)7711330213
t: +44 (0)8707661627
----------------------------------------------------------------
for list details see
http://documentation.magnolia.info/docs/en/editor/stayupdated.html
----------------------------------------------------------------
----------------------------------------------------------------
for list details see
http://documentation.magnolia.info/docs/en/editor/stayupdated.html
----------------------------------------------------------------
--
Paul Worrall
INTERITION - Java Open Source Software Services
Keep informed with the JOSS4BIZ Podcast at
http://joss4biz.interition.net
w: www.interition.net
m: +44 (0)7711330213
t: +44 (0)8707661627
----------------------------------------------------------------
for list details see
http://documentation.magnolia.info/docs/en/editor/stayupdated.html
----------------------------------------------------------------