[H-GEN] Apache and redirects

Martin Pool martinp at mincom.com
Tue Dec 14 01:05:56 EST 1999


[ Humbug *General* list - semi-serious discussions about Humbug and ]
[ Unix-related topics.  Please observe the list's charter.          ]

Michael Anthon wrote:

> I am trying to figure out why Apache is doing a certain thing that does not
> make sense to me.  I have NetSaint on a Linux server and if I access it with
> the address http://10.10.10.2/netsaint , then all is fine and dandy.  I also
> have another page on the same server that I set up with a bunch of links to
> local management pages, one of which is <A
> href="http://10.10.10.2/netsaint">NetSaint Network Monitor</A>.
> 
> This does work, however, when I click this link, Apache sends a "301
> Permanently Moved" response with a redirect "Location :
> http://www.tams.com.au/netsaint".  While this is not a major drama, I would
> prefer it did not do it since this means the request must go via the proxy
> and I would rather it go direct (I can't go direct to www.tams.com.au since
> it is on the other side of a firewall and uses a portfw to access the
> internal server at 10.10.10.2)
> 
> The Apache server does have the "ServerName www.tams.com.au" directive, but
> I don't understand why it does a redirect with the second situation.  The
> only difference between the 2 requests is that one contains a "Referer:
> http://10.10.10.2/my_menu_page.html" header.

Is /netsaint a directory?  It doesn't look very likely, but that will
sometimes cause problems with redirects.  In that case, try making your
link point to http://10.10.10.2/netsaint/ instead.

-- 
 /\\\  Mincom | Martin Pool          | martinp at mincom.com
// \\\        | Software Engineer    | Phone: +61 7 3303-3333
\\ ///        | Mincom Limited       | Teneriffe, Brisbane
 \///         | And now a word from our sponsor...

This transmission is for the intended addressee only and is
confidential information. If you have received this
transmission in error, please delete it and notify the
sender. The contents of this E-mail are the opinion of the
writer only and are not endorsed by Mincom Limited unless
expressly stated otherwise.

--
* This is list (humbug) general handled by majordomo at lists.humbug.org.au .
* Postings to this list are only accepted from subscribed addresses of
* lists 'general' or 'general-post'.



More information about the General mailing list