PDA

View Full Version : index.html make eror


planet_fox
10th February 2007, 20:05
Hi

I have the problem all site index.html make a error.
Fehler 500 - Interner Server-Fehler! or Fehler 403 - Verboten!

The rights is corect, it makes on any html sites. I have no change make in
apache.conf ot http.conf . I have apache2 . When I create a new sites with ispconfig it is the same problem.

till
10th February 2007, 20:42
Are there any additional errors in the error log?

planet_fox
22nd February 2007, 10:41
Nothing under /var/log/apache2/error.log

In Apache conf

DirectoryIndex index.html index.htm index.shtml index.cgi index.php index.php3 index.php4 index.php5 index.pl index.xhtml

martinfst
22nd February 2007, 10:47
This is the wrong error log to look at in this case. Please go to the log directory of the website and loog for a file error.log. So something like /var/www/web1/log/error.log

planet_fox
22nd February 2007, 16:17
oh I have this found

Directory index forbidden by rule:

ok i have the problem is only the index.html gives a error whenn I type

www.test.de and i can see the site when I type www.test.de/index.html

falko
23rd February 2007, 16:58
Can you post the vhost configuration of that web site?

planet_fox
23rd February 2007, 17:48
<VirtualHost 38.192.9.20:80>
SuexecUserGroup web19_ftp web19
ServerName www.web.de:80
ServerAdmin webmaster@web.de
DocumentRoot /home/www/web19/web
DirectoryIndex index.html index.htm index.php index.php5 index.php4 index.php3 index.shtml index.cgi index.pl index.jsp Default.htm default.htm
ScriptAlias /cgi-bin/ /home/times/web19/cgi-bin/
AddHandler cgi-script .cgi
AddHandler cgi-script .pl
ErrorLog /home/www/web19/log/error.log
AddType application/x-httpd-php .php .php3 .php4 .php5
suPHP_Engine on
suPHP_UserGroup web19_ftp web19
AddHandler x-httpd-php .php .php3 .php4 .php5
suPHP_AddHandler x-httpd-php
Alias /error/ "/home/www/web19/web/error/"
ErrorDocument 400 /error/invalidSyntax.html
ErrorDocument 401 /error/authorizationRequired.html
ErrorDocument 403 /error/forbidden.html
ErrorDocument 404 /error/fileNotFound.html
ErrorDocument 405 /error/methodNotAllowed.html
ErrorDocument 500 /error/internalServerError.html
ErrorDocument 503 /error/overloaded.html
AliasMatch ^/~([^/]+)(/(.*))? /home/www/web19/user/$1/web/$3
AliasMatch ^/users/([^/]+)(/(.*))? /home/www/web19/user/$1/web/$3
RewriteEngine on
</VirtualHost>

heymrdj
23rd February 2007, 21:46
I have this same issue. Unless a directory has an index.html to access, the browser give me a FORBIDDEN! message. So to simply make a folder with some files for download, rather than getting an index page jsut showing the files in there, it says FORBIDDEN! So basically I have to build an index.html file with the directories of the files just to access them.

till
23rd February 2007, 22:07
I have this same issue. Unless a directory has an index.html to access, the browser give me a FORBIDDEN! message. So to simply make a folder with some files for download, rather than getting an index page jsut showing the files in there, it says FORBIDDEN! So basically I have to build an index.html file with the directories of the files just to access them.

I dont think ist the same problem. planet_fox gets a error when he has a index.html file and not when he dont have this file.

But back to your problem, to get a directory listing, you must set the option "+indexes" for this directory in the apache configuration.

heymrdj
23rd February 2007, 22:20
I dont think ist the same problem. planet_fox gets a error when he has a index.html file and not when he dont have this file.

But back to your problem, to get a directory listing, you must set the option "+indexes" for this directory in the apache configuration.

Sorry about that. I misread his problem.

But thanks for the fix, it worked perfectly :D.

*gives a till a cookie*

falko
24th February 2007, 15:45
<VirtualHost 38.192.9.20:80>
SuexecUserGroup web19_ftp web19
ServerName www.web.de:80
ServerAdmin webmaster@web.de
DocumentRoot /home/www/web19/web
DirectoryIndex index.html index.htm index.php index.php5 index.php4 index.php3 index.shtml index.cgi index.pl index.jsp Default.htm default.htm
ScriptAlias /cgi-bin/ /home/times/web19/cgi-bin/
AddHandler cgi-script .cgi
AddHandler cgi-script .pl
ErrorLog /home/www/web19/log/error.log
AddType application/x-httpd-php .php .php3 .php4 .php5
suPHP_Engine on
suPHP_UserGroup web19_ftp web19
AddHandler x-httpd-php .php .php3 .php4 .php5
suPHP_AddHandler x-httpd-php
Alias /error/ "/home/www/web19/web/error/"
ErrorDocument 400 /error/invalidSyntax.html
ErrorDocument 401 /error/authorizationRequired.html
ErrorDocument 403 /error/forbidden.html
ErrorDocument 404 /error/fileNotFound.html
ErrorDocument 405 /error/methodNotAllowed.html
ErrorDocument 500 /error/internalServerError.html
ErrorDocument 503 /error/overloaded.html
AliasMatch ^/~([^/]+)(/(.*))? /home/www/web19/user/$1/web/$3
AliasMatch ^/users/([^/]+)(/(.*))? /home/www/web19/user/$1/web/$3
RewriteEngine on
</VirtualHost>
Looks ok. Is there an .htaccess file in /home/www/web19/web?

planet_fox
24th February 2007, 16:37
No, the problem is off all sites is a index.html site in . with index.php is no problems

falko
25th February 2007, 18:44
What's the output of ls -la /home/www/web19/web?

planet_fox
25th February 2007, 20:12
drwxrwxrwx 7 web19_ftp web19 4096 Feb 25 12:36 .
drwxr-xr-x 14 web19_ftp web19 4096 Feb 4 17:24 ..
drwxr-xr-x 9 web19_ftp web19 4096 Feb 25 12:45 content
drwxrwxrwx 2 web19_ftp web19 4096 Oct 7 12:14 error
drwxrwxrwx 2 web19_ftp web19 4096 Oct 7 23:18 files
-rwxrwxrwx 1 web19_ftp web19 4 Feb 22 15:02 index.html
-rwxrwxrwx 1 web19_ftp web19 10 Feb 23 14:25 info.php
drwxrwxr-x 8 web19_ftp web19 4096 Dec 26 02:50 shop
drwxr-xr-x 2 web19_ftp web19 4096 Feb 2 04:01 stats

till
26th February 2007, 10:07
Please check that mod_autoindex is enabled and lodaed in your apache configuration.

falko
26th February 2007, 14:44
I don't see an index.php in /home/www/web19/web... :confused:

planet_fox
26th February 2007, 21:29
Ok under

/etc/apache2/mods-enable and the mods-avalable is no mod_autoindex and I have see in a other apache configuration at home there is a mod_autoindex
in the apache.conf . I do copy the lines there is not in my apache.conf on server and i hope it works than.

planet_fox
27th February 2007, 12:19
I have yesterday include in apache.conf the autoindex mod and restart the server . No change the probleme is the same. Only the index.html says Error 404 and when it is a index,php is no problem.

falko
27th February 2007, 17:28
Can you post the URL of the /home/www/web19/web web site so that I can test with index.html and index.php? Make sure there is an index.html and index.php in /home/www/web19/web.

falko
28th February 2007, 19:27
I didn't find anything unusual in your PM... :confused:
Are there any errors in Apache's error log?

planet_fox
2nd March 2007, 12:26
Sorry nothing only this error


[Thu Mar 01 18:41:21 2007] [error] [client 84.151.56.40] Directory index forbidden by rule: /home/times/web15/web/

Apache2 reinstall

falko
3rd March 2007, 16:25
This isn't related to web19.
I have no clue what's wrong. :confused:

planet_fox
3rd March 2007, 21:59
[Thu Mar 01 18:41:21 2007] [error] [client 84.151.56.40] Directory index forbidden by rule: /home/times/web19/web/

Its in all webs when is only a index.hml

falko
4th March 2007, 16:17
What's your Apache's configuration directory? /etc/apache2 or /etc/httpd or similar? Please go to that directory and run
grep -Ri DirectoryIndex *
What's the output?

planet_fox
4th March 2007, 18:18
Here is Output

vhosts/Vhosts_ispconfig.conf_03-03-07_17-17-23:DirectoryIndex index.html index.htm index.php index.php5 index.php4 index.php3 index.shtml index.cgi index.pl index.jsp Default.htm default.htm

falko
5th March 2007, 19:30
Do you have many of these Vhosts_ispconfig.conf files with an appended date in the vhosts directory? This indicates a problem...
Please try this: http://www.howtoforge.com/forums/showpost.php?p=45966&postcount=2

planet_fox
10th March 2007, 18:26
I have change and the html error is no solve.

When I remove Apache and do New Install what musst I change in config later for ispconfig when I new install have from apache ?

apt-get --purge remove apache2
Reading Package Lists... Done
Building Dependency Tree... Done
The following packages will be REMOVED:
apache2*
0 upgraded, 0 newly installed, 1 to remove and 2 not upgraded.
Need to get 0B of archives.


Apache remove then modules ?

falko
11th March 2007, 20:29
Don't remove Apache! :eek:

What about my previous post?

planet_fox
12th March 2007, 03:24
http -t


server:/etc/apache2# httpd -t
Syntax OK

falko
12th March 2007, 15:09
What's the output of ls -la /path/to/directory_where_Vhosts_ispconfig.conf_is?

planet_fox
12th March 2007, 18:03
here

server:/home/fox# ls -la /etc/apache2/vhosts/
total 108
drwxr-xr-x 2 root root 8192 Mar 12 17:02 .
drwxr-xr-x 10 root root 4096 Mar 12 02:49 ..
-rw-r--r-- 1 root root 91603 Mar 12 13:51 Vhosts_ispconfig.conf

falko
13th March 2007, 20:04
Why is there no Vhosts_ispconfig.conf~? Did you delete it?

planet_fox
14th March 2007, 01:27
drwxr-xr-x 2 root root 8192 Mar 12 21:20 .
drwxr-xr-x 10 root root 4096 Mar 12 02:49 ..
-rw-r--r-- 1 root root 91726 Mar 13 23:52 Vhosts_ispconfig.conf
-rw-r--r-- 1 root root 91726 Mar 13 23:52 Vhosts_ispconfig.conf~

planet_fox
14th March 2007, 14:30
Questions I have Apache2.054 installed

and I can't find this module in /mods/mods-enable or avalaible

autoindex.load

or is autoindex.load only in the future packages avalaible ?

falko
14th March 2007, 23:24
What's the output of ls -la /etc/apache2/mods-available?

mod_autindex should be there, unless it got deleted somehow.

planet_fox
15th March 2007, 10:00
-rw-r--r-- 1 root root 66 Jul 28 2006 actions.load
-rw-r--r-- 1 root root 60 Jul 28 2006 asis.load
-rw-r--r-- 1 root root 70 Jul 28 2006 auth_anon.load
-rw-r--r-- 1 root root 68 Jul 28 2006 auth_dbm.load
-rw-r--r-- 1 root root 74 Jul 28 2006 auth_digest.load
-rw-r--r-- 1 root root 130 Jul 28 2006 auth_ldap.load
-rw-r--r-- 1 root root 72 Jan 7 2006 auth_pgsql.load
-rw-r--r-- 1 root root 62 Jul 28 2006 cache.load
-rw-r--r-- 1 root root 70 Jul 28 2006 cern_meta.load
-rw-r--r-- 1 root root 58 Oct 7 02:20 cgi.load
-rw-r--r-- 1 root root 58 Oct 7 02:20 cgi.load.07-10-06_02-20-39
-rw-r--r-- 1 root root 61 Jul 28 2006 cgid.conf
-rw-r--r-- 1 root root 60 Jul 28 2006 cgid.load
-rw-r--r-- 1 root root 58 Jul 28 2006 dav.load
-rw-r--r-- 1 root root 37 Jul 28 2006 dav_fs.conf
-rw-r--r-- 1 root root 64 Jul 28 2006 dav_fs.load
-rw-r--r-- 1 root root 66 Jul 28 2006 deflate.load
-rw-r--r-- 1 root root 72 Jul 28 2006 disk_cache.load
-rw-r--r-- 1 root root 66 Jul 28 2006 expires.load
-rw-r--r-- 1 root root 72 Jul 28 2006 ext_filter.load
-rw-r--r-- 1 root root 154 Mar 10 03:32 fastcgi.conf
-rw-r--r-- 1 root root 66 Mar 10 03:20 fastcgi.load
-rw-r--r-- 1 root root 72 Jul 28 2006 file_cache.load
-rw-r--r-- 1 root root 66 Jul 28 2006 headers.load
-rw-r--r-- 1 root root 60 Jul 28 2006 imap.load
-rw-r--r-- 1 root root 66 Oct 7 02:20 include.load
-rw-r--r-- 1 root root 66 Oct 7 02:20 include.load.07-10-06_02-20-39
-rw-r--r-- 1 root root 60 Jul 28 2006 info.load
-rw-r--r-- 1 root root 60 Jul 28 2006 ldap.load
-rw-r--r-- 1 root root 70 Jul 28 2006 mem_cache.load
-rw-r--r-- 1 root root 90 Jul 28 2006 mime_magic.conf
-rw-r--r-- 1 root root 72 Jul 28 2006 mime_magic.load
-rw-r--r-- 1 root root 68 Apr 10 2005 mod-security.load
-rw-r--r-- 1 root root 19 Oct 7 02:20 perl.conf
-rw-r--r-- 1 root root 19 Oct 7 02:20 perl.conf.07-10-06_02-20-39
-rw-r--r-- 1 root root 60 Oct 7 02:20 perl.load
-rw-r--r-- 1 root root 60 Oct 7 02:20 perl.load.07-10-06_02-20-39
-rw-r--r-- 1 root root 221 Oct 7 02:20 php4.conf
-rw-r--r-- 1 root root 133 Oct 7 02:20 php4.conf.07-10-06_02-20-39
-rw-r--r-- 1 root root 59 Oct 7 02:20 php4.load
-rw-r--r-- 1 root root 59 Oct 7 02:20 php4.load.07-10-06_02-20-39
-rw-r--r-- 1 root root 133 Nov 3 16:05 php5.conf
-rw-r--r-- 1 root root 59 Nov 3 16:05 php5.load
-rw-r--r-- 1 root root 840 Jul 28 2006 proxy.conf
-rw-r--r-- 1 root root 316 Jul 28 2006 proxy.load
-rw-r--r-- 1 root root 78 Jul 28 2006 proxy_connect.load
-rw-r--r-- 1 root root 70 Jul 28 2006 proxy_ftp.load
-rw-r--r-- 1 root root 103 Mar 23 2005 proxy_html.load
-rw-r--r-- 1 root root 72 Jul 28 2006 proxy_http.load
-rw-r--r-- 1 root root 66 Oct 7 02:20 rewrite.load
-rw-r--r-- 1 root root 66 Oct 7 02:20 rewrite.load.07-10-06_02-20-39
-rw-r--r-- 1 root root 60 Oct 1 2004 ruby.load
-rw-r--r-- 1 root root 66 Jul 28 2006 speling.load
-rw-r--r-- 1 root root 3545 Oct 7 02:20 ssl.conf
-rw-r--r-- 1 root root 3545 Oct 7 02:20 ssl.conf.07-10-06_02-20-39
-rw-r--r-- 1 root root 58 Oct 7 02:20 ssl.load
-rw-r--r-- 1 root root 58 Oct 7 02:20 ssl.load.07-10-06_02-20-39
-rw-r--r-- 1 root root 64 Oct 7 02:20 suexec.load
-rw-r--r-- 1 root root 64 Oct 7 02:20 suexec.load.07-10-06_02-20-39
-rw-r--r-- 1 root root 70 Jul 28 2006 unique_id.load
-rw-r--r-- 1 root root 244 Oct 7 02:20 userdir.conf
-rw-r--r-- 1 root root 244 Oct 7 02:20 userdir.conf.07-10-06_02-20-39
-rw-r--r-- 1 root root 66 Oct 7 02:20 userdir.load
-rw-r--r-- 1 root root 66 Oct 7 02:20 userdir.load.07-10-06_02-20-39
-rw-r--r-- 1 root root 70 Jul 28 2006 usertrack.load
-rw-r--r-- 1 root root 74 Jul 28 2006 vhost_alias.load


and the enable

lrwxrwxrwx 1 root root 40 Oct 7 04:47 actions.load -> /etc/apache2/mods-available/actions.load
lrwxrwxrwx 1 root root 43 Oct 11 20:15 auth_pgsql.load -> /etc/apache2/mods-available/auth_pgsql.load
lrwxrwxrwx 1 root root 36 Nov 14 23:54 cgi.load -> /etc/apache2/mods-available/cgi.load
lrwxrwxrwx 1 root root 36 Mar 14 15:11 dav.load -> /etc/apache2/mods-available/dav.load
lrwxrwxrwx 1 root root 40 Mar 4 18:16 deflate.load -> /etc/apache2/mods-available/deflate.load
lrwxrwxrwx 1 root root 40 Jan 9 21:27 fastcgi.conf -> /etc/apache2/mods-available/fastcgi.conf
lrwxrwxrwx 1 root root 40 Jan 9 21:27 fastcgi.load -> /etc/apache2/mods-available/fastcgi.load
lrwxrwxrwx 1 root root 40 Mar 4 18:19 headers.load -> /etc/apache2/mods-available/headers.load
lrwxrwxrwx 1 root root 37 Oct 20 01:23 imap.load -> /etc/apache2/mods-available/imap.load
lrwxrwxrwx 1 root root 40 Oct 7 01:59 include.load -> /etc/apache2/mods-available/include.load
lrwxrwxrwx 1 root root 43 Oct 11 20:12 mime_magic.conf -> /etc/apache2/mods-available/mime_magic.conf
lrwxrwxrwx 1 root root 43 Oct 11 20:12 mime_magic.load -> /etc/apache2/mods-available/mime_magic.load
lrwxrwxrwx 1 root root 45 Oct 7 04:44 mod-security.load -> /etc/apache2/mods-available/mod-security.load
lrwxrwxrwx 1 root root 37 Oct 7 01:56 perl.conf -> /etc/apache2/mods-available/perl.conf
lrwxrwxrwx 1 root root 37 Oct 7 01:56 perl.load -> /etc/apache2/mods-available/perl.load
lrwxrwxrwx 1 root root 37 Mar 14 15:23 php5.conf -> /etc/apache2/mods-available/php5.conf
lrwxrwxrwx 1 root root 37 Mar 14 15:23 php5.load -> /etc/apache2/mods-available/php5.load
lrwxrwxrwx 1 root root 40 Oct 7 01:59 rewrite.load -> /etc/apache2/mods-available/rewrite.load
lrwxrwxrwx 1 root root 37 Mar 4 17:38 ruby.load -> /etc/apache2/mods-available/ruby.load
lrwxrwxrwx 1 root root 36 Oct 7 01:59 ssl.conf -> /etc/apache2/mods-available/ssl.conf
lrwxrwxrwx 1 root root 36 Oct 7 01:59 ssl.load -> /etc/apache2/mods-available/ssl.load
lrwxrwxrwx 1 root root 39 Jan 9 15:55 suexec.load -> /etc/apache2/mods-available/suexec.load

falko
15th March 2007, 15:27
I've just read here: http://httpd.apache.org/docs/2.0/mod/mod_autoindex.html
mod_autoindex has the status "Base" which means it's always available in Apache, so it should work for your installation, too.

planet_fox
20th March 2007, 12:57
I have testing other formats and I have see only index.php run
index.xhtml , index.htm, index.shtml have the same error

and I have found this

http://faq.wiprojekt.de/1_7_de.html

and here in this tutorial is this in the vhost config

AddType application/x-httpd-php .php .php3 .php4 .html
AddHandler x-httpd-php .php .php3 .php4 .html


and in my vhosts is this not

falko
21st March 2007, 15:56
and here in this tutorial is this in the vhost config

AddType application/x-httpd-php .php .php3 .php4 .html
AddHandler x-httpd-php .php .php3 .php4 .html


and in my vhosts is this not
This will make Apache treat your HTML pages as PHP pages, not as static pages and will increase server load.

planet_fox
21st March 2007, 18:47
I haves any Idee whats the Problem is . Id o testing at home with the same applications and than when it run. I see only the solution I do new install the apache webserver on Weekend.

Thank you Falco for all

planet_fox
25th March 2007, 05:12
Ok I have on this night Apache2 new install and suphp . All ok and than I have restart the same error :(. I dp stop ispconfig and remove in apache.conf the ispconfig vhosts. I restart the apache . I see the Apache is on my server running . I think apache is korect and only when I do the ispconfig vhost to apache.conf became the error. I search Google and hundred foren and I find problem from a other user with my error

directory index forbidden by rule

and a post says make this in your vhost

DirectoryIndex index.php index.phtml index.php3 index.php4 index.html index.htm default.htm Index.htm

ok I do this in my apache.conf

<Directory /home/times/*/web>
Options +Includes -Indexes
AllowOverride None
AllowOverride Indexes AuthConfig Limit FileInfo
Order allow,deny
Allow from all
DirectoryIndex index.php index.phtml index.php3 index.php4 index.html index.htm default.htm Index.htm
<Files ~ "^\.ht">
Deny from all
</Files>
</Directory>


and I have restart the server amd the html sites runs and the php sites .
I hope you can me give a answhere why i must set this in apche.conf

till
25th March 2007, 20:19
Please post the exact DirectoryIndex from the vhost the problem occurs from the Vhost_ispconfig.conf file.

planet_fox
26th March 2007, 11:00
DirectoryIndex index.html index.htm index.php index.php5 index.php4 index.php3 index.shtml index.cgi index.pl index.jsp Default.htm default.htm

this is in all Vhosts in /etc/apache2/vhosts/Vhostsconfig.conf

mean you that ?

till
26th March 2007, 11:05
DirectoryIndex index.html index.htm index.php index.php5 index.php4 index.php3 index.shtml index.cgi index.pl index.jsp Default.htm default.htm

this is in all Vhosts in /etc/apache2/vhosts/Vhostsconfig.conf

mean you that ?

Yes, and it contains the relevant entries, thats really strange...

What is the exact name of your index page. Plesae post the name in with the eaxt upper and lower letters then it appears on your server.

planet_fox
26th March 2007, 11:52
index.html

till
26th March 2007, 12:06
I really have no idea? What you edited and what solved your problem contains the both the index.html in the DirectoryIndex directive, just added in two different parts of the apache configuration, And declaring this directive in a vhost is definately valid and shoild even override the directive that you defined :confused:

planet_fox
28th March 2007, 10:10
I have this add in apache2.conf

DirectoryIndex index.php index.phtml index.php3 index.php4 index.html index.htm default.htm Index.htm

and the html error Problem was finish

<Directory /home/times/*/web>
Options +Includes -Indexes
AllowOverride None
AllowOverride Indexes AuthConfig Limit FileInfo
Order allow,deny
Allow from all
DirectoryIndex index.php index.phtml index.php3 index.php4 index.html index$
<Files ~ "^\.ht">
Deny from all
</Files>
</Directory>