You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Michael Peters <mi...@lazarusalliance.com> on 2014/04/18 20:16:46 UTC

[users@httpd] NameVirtualHost address is not supported

I have a few sites I'd like to run on a single server with one IP on port
80 and 443. I've tried several configuration examples without success. I
get error messages like this:



Starting httpd: [Fri Apr 18 09:23:32 2014] [error] VirtualHost
_default_:443 -- mixing * ports and non-* ports with a NameVirtualHost
address is not supported, proceeding with undefined results

[Fri Apr 18 09:23:32 2014] [warn] NameVirtualHost 184.168.190.45:0 has no
VirtualHosts



When I put multiple entries into httpd.conf similar to this:



#

<VirtualHost 208.109.171.169:80>

ServerName sitename-1.com

DocumentRoot "/www/html/ sitename-1"

ServerAdmin webmaster@ sitename-1.com

<Directory "/www/html/ sitename-1">

allow from all

Options +Indexes

</Directory>

</VirtualHost>

#

<VirtualHost 208.109.171.169:80>

ServerName sitename-2.com

DocumentRoot "/www/html/ sitename-2"

ServerAdmin webmaster@ sitename-2.com

<Directory "/www/html/ sitename-2">

allow from all

Options +Indexes

</Directory>

</VirtualHost>

#



There is nothing but defaults in the ssl.conf file.



I have a site running fine located in the root directory, but when I try to
add other sites in subdirectories, that's when the errors start and all
sites go down. Would anyone please offer me a suggestion for enabling
multiple sites for Apache 2.2?



Best regards,



*Michael*

Re: [users@httpd] NameVirtualHost address is not supported

Posted by Joseph Darman <jo...@yahoo.com>.
This worked for me. I have the domain names registered in godaddy. I had to go into godaddy "DNS Zone File" and "point" the domain names to my external IP address.   Don't use "settings" "forwarding"





NameVirtualHost *:80


# ********************Begin First Web Page ***********************************

<VirtualHost *:80>
    DocumentRoot "C:/Server/Apache2.2/www/Site1/htdocs"
    Servername Site1.com
    ServerAlias www.site1.com
    ErrorLog "logs/site1.localhost-error.log"
    CustomLog "logs/site1.localhost-access.log" common

   <Directory />
       Options FollowSymLinks
       AllowOverride None
       Order deny,allow
       Deny from all
   </Directory>
#
   <Directory "C:/Server/Apache2.2/www/site1/htdocs">
       Options Indexes FollowSymLinks
       AllowOverride None
       Order allow,deny
       Allow from all
   </Directory>

</VirtualHost>

# ******************End First Web Page ***********************************
#
#
#
#
#****************Begin Second Web Page ****************************

<VirtualHost *:80>
    DocumentRoot "C:/Server/Apache2.2/www/Site2/htdocs"
    ServerName site2.us
    ServerAlias www.site2.us
    ErrorLog "logs/site2.localhost-error.log"
    CustomLog "logs/site2.localhost-access.log" common
#
   <Directory />
       Options FollowSymLinks
       AllowOverride None
       Order deny,allow
       Deny from all
   </Directory>
#
   <Directory "C:/Server/Apache2.2/www/site2/htdocs">
       Options Indexes FollowSymLinks
       AllowOverride None
       Order allow,deny
       Allow from all
   </Directory>
</VirtualHost>

# ********************End Second Web Page **********************************
#


On Saturday, April 19, 2014 6:51 AM, Eric Covener <co...@gmail.com> wrote:
 
On Sat, Apr 19, 2014 at 9:32 AM, Michael Peters
<mi...@lazarusalliance.com> wrote:
> IS it ok to have directory statements like this and virtualhost together?
>
> <Directory "/www/html/site_1">
>    Options Indexes FollowSymLinks
>    AllowOverride None
>    Order allow,deny
>    Allow from all
> </Directory>

Yes. They're independent.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

Re: [users@httpd] NameVirtualHost address is not supported

Posted by Eric Covener <co...@gmail.com>.
On Sat, Apr 19, 2014 at 9:32 AM, Michael Peters
<mi...@lazarusalliance.com> wrote:
> IS it ok to have directory statements like this and virtualhost together?
>
> <Directory "/www/html/site_1">
>    Options Indexes FollowSymLinks
>    AllowOverride None
>    Order allow,deny
>    Allow from all
> </Directory>

Yes. They're independent.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


RE: [users@httpd] NameVirtualHost address is not supported

Posted by Michael Peters <mi...@lazarusalliance.com>.
IS it ok to have directory statements like this and virtualhost together?

<Directory "/www/html/site_1">
   Options Indexes FollowSymLinks
   AllowOverride None
   Order allow,deny
   Allow from all
</Directory>



-----Original Message-----
From: Eric Covener [mailto:covener@gmail.com]
Sent: Saturday, April 19, 2014 6:07 AM
To: users@httpd.apache.org
Subject: Re: [users@httpd] NameVirtualHost address is not supported

On Sat, Apr 19, 2014 at 9:00 AM, Michael Peters
<mi...@lazarusalliance.com> wrote:
> I've tried:
>
> NameVirtualHost *:80
> NameVirtualHost *
> NameVirtualHost 184.168.190.45:80

It should match verbatim the arguments to VirtualHost.  None of those are
matches for the VirtualHost you pasted before.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


RE: [users@httpd] NameVirtualHost address is not supported

Posted by Michael Peters <mi...@lazarusalliance.com>.
The problem is fixed. I had to move the existing <Directory> statements and
nest them into new <VirtualHost> statements. Everything is working fine now.

Thanks to all who helped!



-----Original Message-----
From: Eric Covener [mailto:covener@gmail.com]
Sent: Saturday, April 19, 2014 6:07 AM
To: users@httpd.apache.org
Subject: Re: [users@httpd] NameVirtualHost address is not supported

On Sat, Apr 19, 2014 at 9:00 AM, Michael Peters
<mi...@lazarusalliance.com> wrote:
> I've tried:
>
> NameVirtualHost *:80
> NameVirtualHost *
> NameVirtualHost 184.168.190.45:80

It should match verbatim the arguments to VirtualHost.  None of those are
matches for the VirtualHost you pasted before.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] NameVirtualHost address is not supported

Posted by Eric Covener <co...@gmail.com>.
On Sat, Apr 19, 2014 at 9:00 AM, Michael Peters
<mi...@lazarusalliance.com> wrote:
> I've tried:
>
> NameVirtualHost *:80
> NameVirtualHost *
> NameVirtualHost 184.168.190.45:80

It should match verbatim the arguments to VirtualHost.  None of those
are matches for the VirtualHost you pasted before.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


RE: [users@httpd] NameVirtualHost address is not supported

Posted by Michael Peters <mi...@lazarusalliance.com>.
I've tried:

NameVirtualHost *:80
NameVirtualHost *
NameVirtualHost 184.168.190.45:80

Without success.

-----Original Message-----
From: Christopher Schultz [mailto:chris@christopherschultz.net]
Sent: Friday, April 18, 2014 11:26 AM
To: users@httpd.apache.org
Subject: Re: [users@httpd] NameVirtualHost address is not supported

Michael,

On 4/18/14, 2:16 PM, Michael Peters wrote:
> I have a few sites I'd like to run on a single server with one IP on
> port 80 and 443. I've tried several configuration examples without
> success. I get error messages like this:
>
>
>
> Starting httpd: [Fri Apr 18 09:23:32 2014] [error] VirtualHost
> _default_:443 -- mixing * ports and non-* ports with a NameVirtualHost
> address is not supported, proceeding with undefined results
>
> [Fri Apr 18 09:23:32 2014] [warn] NameVirtualHost 184.168.190.45:0
> <http://184.168.190.45:0> has no VirtualHosts
>
>
>
> When I put multiple entries into httpd.conf similar to this:
>
>
>
> #
>
> <VirtualHost 208.109.171.169:80 <http://208.109.171.169:80>>
>
> ServerName sitename-1.com <http://sitename-1.com>
>
> DocumentRoot "/www/html/ sitename-1"
>
> ServerAdmin webmaster@ sitename-1.com <http://sitename-1.com>
>
> <Directory "/www/html/ sitename-1">
>
> allow from all
>
> Options +Indexes
>
> </Directory>
>
> </VirtualHost>
>
> #
>
> <VirtualHost 208.109.171.169:80 <http://208.109.171.169:80>>
>
> ServerName sitename-2.com <http://sitename-2.com>
>
> DocumentRoot "/www/html/ sitename-2"
>
> ServerAdmin webmaster@ sitename-2.com <http://sitename-2.com>
>
> <Directory "/www/html/ sitename-2">
>
> allow from all
>
> Options +Indexes
>
> </Directory>
>
> </VirtualHost>
>
> #

What does your "NameVirtualHost" directive look like?

-chris

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] NameVirtualHost address is not supported

Posted by Christopher Schultz <ch...@christopherschultz.net>.
Michael,

On 4/18/14, 2:16 PM, Michael Peters wrote:
> I have a few sites I’d like to run on a single server with one IP on
> port 80 and 443. I’ve tried several configuration examples without
> success. I get error messages like this:
> 
>  
> 
> Starting httpd: [Fri Apr 18 09:23:32 2014] [error] VirtualHost
> _default_:443 -- mixing * ports and non-* ports with a NameVirtualHost
> address is not supported, proceeding with undefined results
> 
> [Fri Apr 18 09:23:32 2014] [warn] NameVirtualHost 184.168.190.45:0
> <http://184.168.190.45:0> has no VirtualHosts
> 
>  
> 
> When I put multiple entries into httpd.conf similar to this:
> 
>  
> 
> #
> 
> <VirtualHost 208.109.171.169:80 <http://208.109.171.169:80>>
> 
> ServerName sitename-1.com <http://sitename-1.com>
> 
> DocumentRoot "/www/html/ sitename-1"
> 
> ServerAdmin webmaster@ sitename-1.com <http://sitename-1.com>
> 
> <Directory "/www/html/ sitename-1">
> 
> allow from all
> 
> Options +Indexes
> 
> </Directory>
> 
> </VirtualHost>
> 
> #
> 
> <VirtualHost 208.109.171.169:80 <http://208.109.171.169:80>>
> 
> ServerName sitename-2.com <http://sitename-2.com>
> 
> DocumentRoot "/www/html/ sitename-2"
> 
> ServerAdmin webmaster@ sitename-2.com <http://sitename-2.com>
> 
> <Directory "/www/html/ sitename-2">
> 
> allow from all
> 
> Options +Indexes
> 
> </Directory>
> 
> </VirtualHost>
> 
> #

What does your "NameVirtualHost" directive look like?

-chris