You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Michelle Konzack <li...@tamay-dogan.net> on 2010/06/07 21:47:09 UTC

[users@httpd] After new installation apache2 is ignoring DocumentRoot in VirtualHosts

Hello *,

I have a very huge VServer with 4 domains with  more  then  2000  VHosts
(Sub-Domains).

Normaly my /home_www/APACHE_enabled/00_default links to the VServer name
where I can configure any VHosts and more...

Also ANY VHosts pointing to /home_www/htdocs/ and it is the job  of  the
PHP5 scripts to get the date of the right VHost. Up to here it s working
perfectly.

But now after a new installation I have a  problem  with  the  following
config:

----[ '/etc/apache2/apache2.conf' ]-------------------------------------
<snip>
include /home_www/APACHE_enabled/
------------------------------------------------------------------------

----[ '/etc/apache2/conf.d/NameVirtualHost' ]---------------------------
NameVirtualHost 192.168.0.66:80
NameVirtualHost 192.168.0.69:80
NameVirtualHost 88.168.69.36:80
------------------------------------------------------------------------

----[ '/etc/apache2/conf.d/ports.conf' ]--------------------------------
Listen 80
Listen 443
Listen 8888
------------------------------------------------------------------------

----[ '/home_www/APACHE_enabled/00_default' ]---------------------------
<VirtualHost 88.168.69.36:80>
    ServerAdmin		linux4michelle@tamay-dogan.net
    ServerName		vserver1.tamay-dogan.net

    DocumentRoot	/home_www/htdocs/
    <Directory />
        Options		FollowSymLinks Indexes
        AllowOverride	None
    </Directory>

    # debug, info, notice, warn, error, crit, alert, emerg.
    LogLevel		warn
    ErrorLog		/home_www/CONFIG_vserver1.tamay-dogan.net/log/apache/error.log

    LogFormat		"[%V] %p %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" vhost
    CustomLog		/home_www/CONFIG_vserver1.tamay-dogan.net/log/apache/access.log vhost

    ServerSignature	On

</VirtualHost>
------------------------------------------------------------------------

----[ '/home_www/APACHE_enabled/webmail.tamay-dogan.net' ]--------------
<VirtualHost 88.168.69.36:80>
    ServerAdmin		michelle.konzack@tamay-dogan.net
    ServerName		webmail.tamay-dogan.net

    DocumentRoot /home_www/CONFIG_webmail.tamay-dogan.net/htdocs

    Alias /squirrelmail /home_www/CONFIG_webmail.tamay-dogan.net/htdocs

    <Directory /home_www/CONFIG_webmail.tamay-dogan.net/htdocs>
      Options Indexes FollowSymLinks
      <IfModule mod_php5.c>
        php_flag register_globals off
      </IfModule>
      <IfModule mod_dir.c>
        DirectoryIndex index.php
      </IfModule>

      # access to configtest is limited by default to prevent information leak
      <Files configtest.php>
        order deny,allow
        deny from all
        allow from 127.0.0.1
      </Files>
    </Directory>

    # debug, info, notice, warn, error, crit, alert, emerg.
    LogLevel		warn
    ErrorLog		/home_www/CONFIG_webmail.tamay-dogan.net/log/apache/error.log

    LogFormat		"[%V] %p %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" vhost
    CustomLog		/home_www/CONFIG_webmail.tamay-dogan.net/log/apache/access.log vhost

    ServerSignature	On
</VirtualHost>
------------------------------------------------------------------------

So, WHY is DocumentRoot  IGNORED?

If I change the port from the <webmail> to 18888 then I  get  the  error
message:

[Mon Jun 07 21:44:43 2010] [error] [client 192.168.0.65] File does not exist: /htdocs

but /htdocs is nowhere defined!  I use aways fullpath.

What can this be?

Thanks, Greetings and nice Day/Evening
    Michelle Konzack

-- 
##################### Debian GNU/Linux Consultant ######################
   Development of Intranet and Embedded Systems with Debian GNU/Linux

itsystems@tdnet France EURL       itsystems@tdnet UG (limited liability)
Owner Michelle Konzack            Owner Michelle Konzack

Apt. 917 (homeoffice)
50, rue de Soultz                 Kinzigstraße 17
67100 Strasbourg/France           77694 Kehl/Germany
Tel: +33-6-61925193 mobil         Tel: +49-177-9351947 mobil
Tel: +33-9-52705884 fix

<http://www.itsystems.tamay-dogan.net/>  <http://www.flexray4linux.org/>
<http://www.debian.tamay-dogan.net/>         <http://www.can4linux.org/>

Jabber linux4michelle@jabber.ccc.de
ICQ    #328449886

Linux-User #280138 with the Linux Counter, http://counter.li.org/

[users@httpd] [SOLVED] Re: After new installation apache2 is ignoring DocumentRoot in VirtualHosts

Posted by Michelle Konzack <li...@tamay-dogan.net>.
OK, it was apache2 which has screwed up the systems but IP-Tables  which
forwarded incoming connections to a wrong IP...  Now it works again!

Thanks, Greetings and nice Day/Evening
    Michelle Konzack

-- 
##################### Debian GNU/Linux Consultant ######################
   Development of Intranet and Embedded Systems with Debian GNU/Linux

itsystems@tdnet France EURL       itsystems@tdnet UG (limited liability)
Owner Michelle Konzack            Owner Michelle Konzack

Apt. 917 (homeoffice)
50, rue de Soultz                 Kinzigstraße 17
67100 Strasbourg/France           77694 Kehl/Germany
Tel: +33-6-61925193 mobil         Tel: +49-177-9351947 mobil
Tel: +33-9-52705884 fix

<http://www.itsystems.tamay-dogan.net/>  <http://www.flexray4linux.org/>
<http://www.debian.tamay-dogan.net/>         <http://www.can4linux.org/>

Jabber linux4michelle@jabber.ccc.de
ICQ    #328449886

Linux-User #280138 with the Linux Counter, http://counter.li.org/

[users@httpd] Re: After new installation apache2 is ignoring DocumentRoot in VirtualHosts

Posted by Michelle Konzack <li...@tamay-dogan.net>.
Hello Eric Covener,

Am 2010-06-07 16:28:27, hacktest Du folgendes herunter:
> On Mon, Jun 7, 2010 at 3:47 PM, Michelle Konzack
> <li...@tamay-dogan.net> wrote:
> > NameVirtualHost 88.168.69.36:80
> > Listen 80
> > <VirtualHost 88.168.69.36:80>
> >    DocumentRoot        /home_www/htdocs/
> > <VirtualHost 88.168.69.36:80>
> >    DocumentRoot /home_www/CONFIG_webmail.tamay-dogan.net/htdocs
> 
> are you sure the connections you're testing are received on the local
> interface 88.168.69.36?

Yes, otherwise the website <http://vserver1.tamay-dogen.net/> would not
work.   ;-)

my index.php is only:

----[ '/home_www/htdocs/index.php' ]------------------------------------
<?php

define(DIR_BASE, "/home_www");
define(DIR_TOOL, "/usr/share/tdphp-vserver");

include DIR_TOOL . "/includes/00_main.inc";

?>
------------------------------------------------------------------------

which mean, the php script /usr/share/tdphp-vserver/includes/00_main.inc
is looking for a config file in

    /home_www/CONFIG_webmail.tamay-dogan.net/.config

if I request the URL <http://webmail.tamay-dogen.net/> and then  execute
it but since Squirrelmail  does  not  work  this  way  I  have  set  the

   DocumentRoot /home_www/CONFIG_webmail.tamay-dogan.net/htdocs/

and put the squirrelmail files there.

> If not, they'll be handled by your base
> configuration [outside of all vhosts].

Hmm have to check this.  Maybe the Debian Maintainer  has  changed  some
things which now screw up my server.

Thanks, Greetings and nice Day/Evening
    Michelle Konzack

-- 
##################### Debian GNU/Linux Consultant ######################
   Development of Intranet and Embedded Systems with Debian GNU/Linux

itsystems@tdnet France EURL       itsystems@tdnet UG (limited liability)
Owner Michelle Konzack            Owner Michelle Konzack

Apt. 917 (homeoffice)
50, rue de Soultz                 Kinzigstraße 17
67100 Strasbourg/France           77694 Kehl/Germany
Tel: +33-6-61925193 mobil         Tel: +49-177-9351947 mobil
Tel: +33-9-52705884 fix

<http://www.itsystems.tamay-dogan.net/>  <http://www.flexray4linux.org/>
<http://www.debian.tamay-dogan.net/>         <http://www.can4linux.org/>

Jabber linux4michelle@jabber.ccc.de
ICQ    #328449886

Linux-User #280138 with the Linux Counter, http://counter.li.org/

Re: [users@httpd] After new installation apache2 is ignoring DocumentRoot in VirtualHosts

Posted by Eric Covener <co...@gmail.com>.
On Mon, Jun 7, 2010 at 3:47 PM, Michelle Konzack
<li...@tamay-dogan.net> wrote:
> NameVirtualHost 88.168.69.36:80
> Listen 80
> <VirtualHost 88.168.69.36:80>
>    DocumentRoot        /home_www/htdocs/
> <VirtualHost 88.168.69.36:80>
>    DocumentRoot /home_www/CONFIG_webmail.tamay-dogan.net/htdocs

are you sure the connections you're testing are received on the local
interface 88.168.69.36? If not, they'll be handled by your base
configuration [outside of all vhosts].

-- 
Eric Covener
covener@gmail.com

---------------------------------------------------------------------
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