2012-02-13 11 views
0

私は2つの仮想ホストを作成しました。 tester.lyとtucnak.meApacheマルチサイト

/サイト利用可能/ラボ:

<VirtualHost tucnak.me:80> 
    ServerAdmin [email protected] 
    ServerName tucnak.me 
    DocumentRoot /home/tucnak/Web/Lab/ 
    <Directory /> 
     Options FollowSymLinks 
     AllowOverride None 
    </Directory> 
    <Directory /home/tucnak/Web/Lab/> 
     Options Indexes FollowSymLinks MultiViews 
     AllowOverride None 
     Order allow,deny 
     allow from all 
    </Directory> 
      #... here smth skipped. 
</VirtualHost> 

および/サイト利用可能/テスター:

<VirtualHost tester.ly:80> 
    ServerAdmin [email protected] 
    ServerName tester.ly 
    DocumentRoot /home/tucnak/Web/Tester/ 
    <Directory /> 
     Options FollowSymLinks 
     AllowOverride None 
    </Directory> 
    <Directory /home/tucnak/Web/Tester/> 
     Options Indexes FollowSymLinks MultiViews 
     AllowOverride None 
     Order allow,deny 
     allow from all 
    </Directory> 
      # skipped too. 
</VirtualHost> 

そして、私のapache2の出力:

[Mon Feb 13 20:17:07 2012] [warn] VirtualHost tucnak.me:80 overlaps with VirtualHost tester.ly:80, the first has precedence, perhaps you need a NameVirtualHost directive 

誤った指示がこの問題を引き起こすと思います。だから、私は助けが必要です。

答えて

0

設定にNameVirtualHost *:80またはNameVirtualHost *ディレクティブがある場合があります。

これはあなたの出発VirtualHostディレクティブがあるべき意味:

<VirtualHost *:80> 
(...) 
<VirtualHost *:80> 
(...) 

とされていない:

<VirtualHost tester.ly:80> 
(...) 
<VirtualHost tucnak.me:80> 
(...) 

のVirtualHostの名前がありません使用する名前で、VirtualHostの内部ServerNameディレクティブで与えられます<VirtualHost xxx>のそしてこのxxxは、メインコンフィギュレーションのNameVirtualHost宣言の1つと一致する必要があります。

関連する問題