[lug] Strange Apache VirtualHost behavior
Michael D. Hirsch
mhirsch at nubridges.com
Tue Nov 23 09:01:18 MST 2004
On Tue, 2004-11-23 at 10:48, David Morris wrote:
> On Mon, Nov 22, 2004 at 11:24:15PM -0700, Lee Woodworth wrote:
> > You fixed it? I just looked at
> > http://david.morris-clan.net/foo (no trailing slash)
> > and it redirects to
> > http://david.morris-clan.net/foo/
> > which has cats.html in it.
>
> Now that is odd because it does *not* do that for me.
>
> <sigh>
>
> What web browser are you using? I wonder if perhaps
> Mozilla/Firefox aren't sending the right information.
Happens to me on both Konqueror and Mozilla. I get the same directory
listing.
Michael
> --David
>
> > David Morris wrote:
> > >On Mon, Nov 22, 2004 at 02:54:06PM -0700, David Anselmi wrote:
> > >
> > >>>If I go to this one:
> > >>>
> > >>> http://david.morris-clan.net/foo
> > >>>
> > >>>(Note the lack of a trailing '/') I get redirected here:
> > >>>
> > >>> http://belsambar.morris-clan.net/foo/
> > >>
> > >>No trailing slash gives me a 404 at the moment. Perhaps you want mod_dir?
> > >
> > >
> > >Aye, you get 404 because
> > >http://belsambar.morris-clan.net/foo/ does not exist. If
> > >you add the trailing '/' you stay in http://david.mo... and
> > >don't get 404. I do have mod_dir being used.
> > >
> > >
> > >>[...]
> > >>
> > >>>NameVirtualHost 66.93.122.13
> > >>>
> > >>><VirtualHost 66.93.122.13:80>
> > >>> ServerAlias morris-clan.net
> > >>> ServerAlias *.morris-clan.net
> > >>
> > >>Should the first of those be ServerName rather than Alias by any chance?
> > >
> > >
> > >It should yes....but doesn't change anything apparently
> > >
> > >A few more experiments make it even more interesting:
> > >
> > >No matter what virtual host is placed first, the hostname in
> > >the URL is redirected to 'belsambar.morris-clan.net' (the
> > >name of the computer which, incidentally, doesn't exist
> > >anywhere in the config file) and the DocumentRoot is taken
> > >from the first VirtualHost entry.
> > >
> > >--David
> > >_______________________________________________
> > >Web Page: http://lug.boulder.co.us
> > >Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> > >Join us on IRC: lug.boulder.co.us port=6667 channel=#colug
> >
> > _______________________________________________
> > Web Page: http://lug.boulder.co.us
> > Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> > Join us on IRC: lug.boulder.co.us port=6667 channel=#colug
> _______________________________________________
> Web Page: http://lug.boulder.co.us
> Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> Join us on IRC: lug.boulder.co.us port=6667 channel=#colug
More information about the LUG
mailing list