You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Martin S <fs...@forumsyd.net> on 2008/04/18 22:47:19 UTC
[users@httpd] file doesn't exist
Hi,
I have a problem with my server in that it doesn't display my site
unless I am browsing to it from localhost. Then it display just fine.
Whenever i try to reach it from another box, I get a Page can't be found
error and in the apache2 error.log I find File doesn't exists /htdocs.
I checked this, and and it indicates that the DocumentRoot path is not
set or incorrect. But this isn't the case. DocumentRoot is set to
/var/www/apache2-default, still it tries to find /htdocs for the outside
boxen. So in my desperation I set up a /var/www/htdocs link poinging to
apache2-default. Still the same problem.
Any more suggestions what might be wrong?
Martin S
---------------------------------------------------------------------
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@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] file doesn't exist
Posted by Joshua Slive <jo...@slive.ca>.
On Thu, Apr 24, 2008 at 10:23 AM, Martin <fs...@forumsyd.net> wrote:
> OK, I thought /htdocs was starting in the webroot rather than the "real"
> root. But why would it produce that error if the "only" problem was the VH
There is probably another <VirtualHost> section someplace that is
getting matched and has (either explicitly, or inherited from some
compile-time setting) the DocumentRoot set to /htdocs.
Joshua.
---------------------------------------------------------------------
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@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] file doesn't exist
Posted by Martin <fs...@forumsyd.net>.
Joshua Slive skrev:
> On Thu, Apr 24, 2008 at 8:42 AM, Martin <fs...@forumsyd.net> wrote:
>
>
>> This is my httpd.conf file
>>
>> mail:/etc/apache2# cat httpd.conf
>> NameVirtualHost *:80
>> <VirtualHost mail.forumsyd.net:80>
>>
>
> That should be <VirtualHost *:80>. I bet that fixes your problem.
>
Yes! Thanks a lot. Sometimes things are easily solved by more
knowledgeable eyes. :)
> The error log reports that apache is looking in the file-system path
> /htdocs, so that would be /htdocs off the root, and not
> /var/www/htdocs.
OK, I thought /htdocs was starting in the webroot rather than the "real"
root. But why would it produce that error if the "only" problem was the VH
Martin S
---------------------------------------------------------------------
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@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] file doesn't exist
Posted by Joshua Slive <jo...@slive.ca>.
On Thu, Apr 24, 2008 at 8:42 AM, Martin <fs...@forumsyd.net> wrote:
> This is my httpd.conf file
>
> mail:/etc/apache2# cat httpd.conf
> NameVirtualHost *:80
> <VirtualHost mail.forumsyd.net:80>
That should be <VirtualHost *:80>. I bet that fixes your problem.
> [Thu Apr 24 15:28:43 2008] [error] [client 192.168.0.81] File does not
> exist: /htdocs
>
> and the file system
>
> mail:/var/www# pwd
> /var/www
> mail:/var/www# ls -l
> total 12
> drwxr-xr-x 3 root root 4096 2008-04-18 13:26 apache2-default
> drwxr-xr-x 3 root root 4096 2008-04-14 18:19 cgi-bin
> lrwxrwxrwx 1 root root 25 2008-04-18 16:42 htdocs ->
> /var/www/apache2-default/
> drwxr-xr-x 3 root root 4096 2008-04-14 18:44 images
> mail:/var/www#
>
The error log reports that apache is looking in the file-system path
/htdocs, so that would be /htdocs off the root, and not
/var/www/htdocs.
Joshua.
---------------------------------------------------------------------
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@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] file doesn't exist
Posted by Martin <fs...@forumsyd.net>.
Joshua Slive skrev:
> On Sat, Apr 19, 2008 at 2:53 AM, Martin S <fs...@forumsyd.net> wrote:
>
>> Davide Bianchi skrev:
>>
>>
>>
>>> Martin S wrote:
>>>
>>>
>>>> /var/www/apache2-default, still it tries to find /htdocs for the outside
>>>>
>> boxen.
>>
>>> Your configuration is certainly broken. How do you get it from the
>>>
>> localhost and how do you get it from 'outside' boxen?
>>
>>> Maybe you have vhost without knowing.
>>>
>>>
>> It's most certainly broken as it "doesn't work" properly. Not sure what you
>> mean "how do you get it....". If I browse (with Firefox) localhost I get the
>> proper site, if I browse the IP-address from another box on the network I
>> get the error. Same thing happens if I browse for the public URL.
>> Yes, *might* be some "unknown" vhost. Need to check that as well, it should
>> be set up in httpd.conf right?
>>
>
> Davide is almost-certainly correct that this is a problem with
> <VirtualHost>s in httpd.conf or in an Include'd config file. Check all
> your config files for <VirtualHost> definitions. Also, if you need
> more help, post exact error and access log messages.
I've been trying to fix this until green, also ill at the start of the
week so might have mixed things up a bit with my befuddled head....
This is my httpd.conf file
mail:/etc/apache2# cat httpd.conf
NameVirtualHost *:80
<VirtualHost mail.forumsyd.net:80>
ServerAdmin support@forumsyd.org
ServerName mail.forumsyd.net
DocumentRoot /var/www/apache2-default
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
# This directive allows us to have apache2's default
start page
# in /apache2-default/, but still have / go to the right
place
# RedirectMatch ^/$ /apache2-default/
</Directory>
ScriptAlias /cgi-bin/ /var/www/cgi-bin/
<Directory "/var/www/cgi-bin/">
AllowOverride All
Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
<Directory "/var/www/cgi-bin/vqadmin">
deny from all
Options ExecCGI
AllowOverride AuthConfig
Order deny,allow
</Directory>
Alias /webmail /usr/local/squirrelmail/webmail
<Directory /usr/local/squirrelmail/webmail>
Options Indexes
AllowOverride None
DirectoryIndex index.php
Order Allow,Deny
Allow from All
</Directory>
ErrorLog /var/log/apache2/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog /var/log/apache2/access.log combined
ServerSignature On
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
</VirtualHost>
on a Debian 4.0 stable server.
Error log excerpt
[Thu Apr 24 15:28:35 2008] [error] [client 192.168.0.81] File does not
exist: /htdocs
[Thu Apr 24 15:28:36 2008] [error] [client 192.168.0.81] File does not
exist: /htdocs
[Thu Apr 24 15:28:36 2008] [error] [client 192.168.0.81] File does not
exist: /htdocs
[Thu Apr 24 15:28:37 2008] [error] [client 192.168.0.81] File does not
exist: /htdocs
[Thu Apr 24 15:28:37 2008] [error] [client 192.168.0.81] File does not
exist: /htdocs
[Thu Apr 24 15:28:43 2008] [error] [client 192.168.0.81] File does not
exist: /htdocs
and the file system
mail:/var/www# pwd
/var/www
mail:/var/www# ls -l
total 12
drwxr-xr-x 3 root root 4096 2008-04-18 13:26 apache2-default
drwxr-xr-x 3 root root 4096 2008-04-14 18:19 cgi-bin
lrwxrwxrwx 1 root root 25 2008-04-18 16:42 htdocs ->
/var/www/apache2-default/
drwxr-xr-x 3 root root 4096 2008-04-14 18:44 images
mail:/var/www#
Any pointers as to what to do about this is greatly appreciated....
Martin S
---------------------------------------------------------------------
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@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] file doesn't exist
Posted by Joshua Slive <jo...@slive.ca>.
On Sat, Apr 19, 2008 at 2:53 AM, Martin S <fs...@forumsyd.net> wrote:
> Davide Bianchi skrev:
>
>
> > Martin S wrote:
> >
> > > /var/www/apache2-default, still it tries to find /htdocs for the outside
> boxen.
> > >
> >
> > Your configuration is certainly broken. How do you get it from the
> localhost and how do you get it from 'outside' boxen?
> > Maybe you have vhost without knowing.
> >
> It's most certainly broken as it "doesn't work" properly. Not sure what you
> mean "how do you get it....". If I browse (with Firefox) localhost I get the
> proper site, if I browse the IP-address from another box on the network I
> get the error. Same thing happens if I browse for the public URL.
> Yes, *might* be some "unknown" vhost. Need to check that as well, it should
> be set up in httpd.conf right?
Davide is almost-certainly correct that this is a problem with
<VirtualHost>s in httpd.conf or in an Include'd config file. Check all
your config files for <VirtualHost> definitions. Also, if you need
more help, post exact error and access log messages.
Joshua.
---------------------------------------------------------------------
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@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] file doesn't exist
Posted by Martin S <fs...@forumsyd.net>.
Davide Bianchi skrev:
> Martin S wrote:
>> /var/www/apache2-default, still it tries to find /htdocs for the
>> outside boxen.
>
> Your configuration is certainly broken. How do you get it from the
> localhost and how do you get it from 'outside' boxen?
> Maybe you have vhost without knowing.
It's most certainly broken as it "doesn't work" properly. Not sure what
you mean "how do you get it....". If I browse (with Firefox) localhost I
get the proper site, if I browse the IP-address from another box on the
network I get the error. Same thing happens if I browse for the public URL.
Yes, *might* be some "unknown" vhost. Need to check that as well, it
should be set up in httpd.conf right?
Martin S
---------------------------------------------------------------------
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@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] file doesn't exist
Posted by Davide Bianchi <da...@onlyforfun.net>.
Martin S wrote:
> /var/www/apache2-default, still it tries to find /htdocs for the outside
> boxen.
Your configuration is certainly broken. How do you get it from the
localhost and how do you get it from 'outside' boxen?
Maybe you have vhost without knowing.
Davide
--
This is an air conditioned room -- do not open Windows!
---------------------------------------------------------------------
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@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org