Re: Apache 2.4.12 don't serve me the index.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

I tried the AddType and AddHandler directive but with no success. I
placed them in the mime module block anc loaded the mime module.
Then I added a simple .htaccess and restartet apache2

order allow,deny
deny from 201.68.101.5
allow from all

But if try to load index.html all I get is this:

[Thu Jan 01 07:20:22.664417 1970] [authz_core:debug] [pid 490]
mod_authz_core.c(809): [client 192.168.2.99:6340] AH01626:
authorization result of Require all granted: granted
[Thu Jan 01 07:20:22.664644 1970] [authz_core:debug] [pid 490]
mod_authz_core.c(809): [client 192.168.2.99:6340] AH01626:
authorization result of <RequireAny>: granted
[Thu Jan 01 07:20:22.669855 1970] [authz_core:debug] [pid 491]
mod_authz_core.c(809): [client 192.168.2.99:6341] AH01626:
authorization result of Require all granted: granted
[Thu Jan 01 07:20:22.670085 1970] [authz_core:debug] [pid 491]
mod_authz_core.c(809): [client 192.168.2.99:6341] AH01626:
authorization result of <RequireAny>: granted

if I browse hello.php i got a succesfull page load with "hello world"
but all html files or images won't work...

/etc/apache/httpd.conf

ServerRoot /usr/share/apache2

PidFile /var/run/apache2.pid

Listen 0.0.0.0:80

LoadModule unixd_module /usr/share/apache2/modules/mod_unixd.so
#LoadModule ssl_module /usr/share/apache2/modules/mod_ssl.so
LoadModule authz_core_module /usr/share/apache2/modules/mod_authz_core.so
LoadModule authz_user_module /usr/share/apache2/modules/mod_authz_user.so
LoadModule authz_host_module /usr/share/apache2/modules/mod_authz_host.so
LoadModule authn_core_module /usr/share/apache2/modules/mod_authn_core.so
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule mime_module /usr/share/apache2/modules/mod_mime.so
LoadModule dir_module /usr/share/apache2/modules/mod_dir.so

<IfModule unixd_module>

User www
Group www

</IfModule>

ServerAdmin you@xxxxxxxxxxx

ServerName localhost

DocumentRoot /var/www

<Directory />
    Options Indexes FollowSymLinks
    AllowOverride None
</Directory>

<Directory /var/www>
    Options FollowSymLinks
    AllowOverride None
    Require all granted
</Directory>

<IfModule dir_module>
    DirectoryIndex index.html
</IfModule>

<Files ".ht*">
    Require all denied
</Files>

ErrorLog "/var/log/apache2/error_log"

LogLevel debug

<IfModule log_config_module>

    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\"
\"%{User-Agent}i\"" combined
    LogFormat "%h %l %u %t \"%r\" %>s %b" common

    <IfModule logio_module>
      # You need to enable mod_logio.c to use %I and %O
      LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\"
\"%{User-Agent}i\" %I %O" combinedio
    </IfModule>

    CustomLog "/var/log/apache2/access_log" common
</IfModule>

<IfModule alias_module>
    ScriptAlias /cgi-bin/ "/usr/cgi-bin/"
</IfModule>

<IfModule cgid_module>

</IfModule>

<Directory "/usr/cgi-bin">
    AllowOverride None
    Options None
    Require all granted
</Directory>

<IfModule mime_module>
    TypesConfig /etc/mime.types
    AddType application/x-compress .Z
    AddType application/x-gzip .gz .tgz
    AddType text/html .html
    AddHandler server-parsed .htmlAddType text/html .html
AddHandler server-parsed .html

</IfModule>

<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>

LoadModule php5_module /usr/share/apache2/modules/libphp5.so

<IfModule mod_php5.c>
    <FilesMatch "\.ph(p3?|tml)$">
        SetHandler application/x-httpd-php
    </FilesMatch>
    <FilesMatch "\.phps$">
        SetHandler application/x-httpd-php-source
    </FilesMatch>
</IfModule>

<IfModule mod_ssl.c>
    Include /etc/apache2/mod_ssl.conf
</IfModule>

On Wed, Feb 25, 2015 at 2:17 PM, Kes Wolfe <keswolfe@xxxxxxxxxx> wrote:
> .htaccess file in the site root directory:
>
> AddType text/html .html
> AddHandler server-parsed .html
>
>
>> Date: Wed, 25 Feb 2015 13:49:41 +0100
>> From: oliver.graute@xxxxxxxxx
>> To: users@xxxxxxxxxxxxxxxx
>> Subject: Re:  Apache 2.4.12 don't serve me the index.html
>
>>
>> Hello Eric,
>>
>> sorry here the full log.
>>
>> [Tue Jan 06 19:23:09.446724 1970] [authz_core:debug] [pid 1397]
>> mod_authz_core.c(809): [client 192.168.2.99:51306] AH01626:
>> authorization result of Require all granted: granted
>> [Tue Jan 06 19:23:09.447385 1970] [authz_core:debug] [pid 1397]
>> mod_authz_core.c(809): [client 192.168.2.99:51306] AH01626:
>> authorization result of <RequireAny>: granted
>> [Tue Jan 06 19:23:09.448167 1970] [core:info] [pid 1397] [client
>> 192.168.2.99:51306] AH00129: Attempt to serve directory: /var/www/
>>
>> html and jpg files won't work, only php files...
>>
>> Thx
>>
>> Oliver
>>
>>
>> On Wed, Feb 25, 2015 at 1:11 PM, Eric Covener <covener@xxxxxxxxx> wrote:
>> > On Wed, Feb 25, 2015 at 2:45 AM, Oliver Graute <oliver.graute@xxxxxxxxx>
>> > wrote:
>> >> [Tue Jan 06 19:23:09.448167 1970] [core:info] [pid 1397] [client
>> >> 192.168.2.99:51
>> >
>> >
>> > This line was incomplete in your email.
>> >
>> > --
>> > Eric Covener
>> > covener@xxxxxxxxx
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
>> > For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
>> >
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
>> For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx





[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux