OT:Apache question

Chris Hewitt g0pae at manordat.demon.co.uk
Sat Feb 21 16:43:15 UTC 2004


Mark Knecht wrote:

>On Sat, 2004-02-21 at 06:55, Chris Hewitt wrote:
>
>>Mark,
>>
>>Looking at your original post, you have a single site. The virtualhost 
>>directives are not needed for this so if you don't want to get deep into 
>>Apache httpd administration you may like to avoid using them. They are 
>>all commented out by default.
>>
>>I don't have a commonapache2.conf file either. I've never heard of it so 
>>I would think it is a customisation someone has put in.
>>
>>Rick's single "Alias" line should be all you need.
>>
>>HTH
>>Chris
>>
>Chris,
>   Hi. With some of Rick's suggestions I sort of have it working, but
>not totally. I can see things correctly (sort of) when sitting on the
>machine running Apache, but if I go to another machine on the network
>here in my house it only partially works. I am using Rick's suggestion
>about the Alias. Here's the portion of apache2.conf that I modified:
>
><SNIP>
>Alias /files "/mnt/data/webfiles"
>
>
>    <Directory "/mnt/data/webfiles">
>            Options Indexes FollowSymlinks MultiViews
>            AllowOverride None
>            Order allow,deny
>            Allow from all
>    </Directory>
><SNIP>
>
>Here are the results:
>
>>From the server:
>
>1) Test- Access http://marksmusic.myvnc.com
>Result - address bar says http://marksmusic.myvnc.com and the page
>displays correctly.
>
>2) Test- Access http://marksmusic.myvnc.com/files
>Result - address bar changes to http://wizard.knechthome.com/files/ but
>the directory listing displays correctly. I can go so subdirectories and
>I can download files. It only works (I think) because I have
>wizard.knechthome.com in my hosts file.
>
>>From another machine here at home:
>
>3) Test- Access http://marksmusic.myvnc.com
>Result - address bar says http://marksmusic.myvnc.com and the page
>displays correctly.
>
>4) Test- Access http://marksmusic.myvnc.com/files
>Result - Page fails to display and I get a message
>"http://wizard.knechthome.com/files/ not found"
>
>So, the results are consistently incorrect. Why does Apache insist on
>remapping the name I as for ONLY when I append the directory name?
>
>   I think Rick's suggestion about <Virtual *> would probably fix this,
>and I'm looking around for where to best put that, but it seems to me
>something is set up incorrectly elsewhere causing this remapping of the
>name to a local name instead of the myvnc.com address that would work
>for all machines coming to this machine.
>
>   Thanks for your help.
>
>- Mark
>
Mark,

I've done two tests on an Apache 2.0.47 on Fedora Core 1. I patched your 
Files and Directory lines into /etc/httpd/conf/httpd.conf, putting them 
right at the end. For the first test I used the directory 
/var/www/html/webfiles (as it was under the Document Root). For the 
second test I picked something outside Document Root (/home/webfiles). 
In both cases I could get a listing of files correctly from both the 
local computer and another one here at home over the network.

So I think this is a configuration issue, possibly with httpd but 
possibly DNS. If, from the remote computer, you call the page by ip 
address instead of markmusic.myvnc.com does it work? If you do a "dig 
markmusic.myvnc.com" and "dig wizard.knechthome.com" what IP addresses 
does it come up with? Also, if you do a "dig -x ipaddress" on both the 
ip addresses, does it come up with the hostname?

I feel the dns issue is the first thing to address, it may be the 
problem but if not I feel it is masking the problem.

If you have the httpd manual installed. It should be available at 
http://markmusic.myvnc.com/manual. If you can get to it from the 
computer running Apache httpd, then can you get to it from the other 
computer? If yes to the first and no to the second then I think it is a 
dns issue and not an error in your changes to httpd.conf.

Regards

Chris





More information about the Redhat-install-list mailing list