Virtual hosting problem
am 05.03.2010 16:53:59 von forums
Hi,
I'm having a problem with virtual hosting. This isn't the first time
I've set up a virtual host, but I've apparently wandered into unfamiliar
territory. Here are the relevant host definitions:
ServerAdmin sean@dezynworks.com
DocumentRoot /var/www/primary
ServerName primary.com
ServerAlias primary.com www.primary.com
ServerAlias primary.com www.secondaryA.net
ServerAlias primary.com secondaryB.tv
ServerAlias primary.com www.secondaryB.tv
ServerAlias primary.com secondaryC.net
ServerAlias primary.com www.secondaryC.net
ServerAlias primary.com secondaryC.com
ServerAlias primary.com www.secondaryC.com
ErrorLog logs/primary-error_log
CustomLog logs/primary-access_log common
Options Indexes FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
ServerAdmin sean@dezynworks.com
DocumentRoot /var/www/primary_dev
ServerName dev.primary.com
ErrorLog logs/primary_dev-error_log
CustomLog logs/primary_dev-access_log common
Options Indexes FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
The primary domain works fine, including all the server aliases. What
doesn't work is dev.primary.com. It isn't accessing the directory
primary_dev. It's access the directory primary. I can't even begin to
guess why. A very similar set up was working just fine when one of the
secondary domains was the primary domain. Then my client acquired what
is now the primary domain and this is what I set up. I wish I had the
old config to look at.
What is even more bizarre is if I go to the old dev site
(dev.secondaryA.net) then I get the site as it exists in the primary_dev
directory. That sub-domain should not even exist. I removed all
references to that domain in Apache's config and the DNS files last
night. I wouldn't expect that machine to be answering to that domain
name now. (I know just enough about setting up DNS to be very
dangerous.) Can someone offer some advice as to why this is not working?
Thanks.
-Sean
------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See 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
Re: Virtual hosting problem
am 05.03.2010 17:03:28 von Philip Wigg
On 5 March 2010 15:53, Sean H. wrote:
> Hi,
>
> I'm having a problem with virtual hosting. This isn't the first time I've
> set up a virtual host, but I've apparently wandered into unfamiliar
> territory. Here are the relevant host definitions:
>
>
> =A0 =A0ServerAdmin sean@dezynworks.com
> =A0 =A0DocumentRoot /var/www/primary
> =A0 =A0ServerName primary.com
> =A0 =A0ServerAlias primary.com www.primary.com
> =A0 =A0ServerAlias primary.com www.secondaryA.net
> =A0 =A0ServerAlias primary.com secondaryB.tv
> =A0 =A0ServerAlias primary.com www.secondaryB.tv
> =A0 =A0ServerAlias primary.com secondaryC.net
> =A0 =A0ServerAlias primary.com www.secondaryC.net
> =A0 =A0ServerAlias primary.com secondaryC.com
> =A0 =A0ServerAlias primary.com www.secondaryC.com
> =A0 =A0ErrorLog logs/primary-error_log
> =A0 =A0CustomLog logs/primary-access_log common
>
> =A0 =A0 =A0 Options Indexes FollowSymLinks
> =A0 =A0 =A0 AllowOverride All
> =A0 =A0 =A0 =A0Order allow,deny
> =A0 =A0 =A0 =A0Allow from all
>
>
>
>
> =A0 =A0ServerAdmin sean@dezynworks.com
> =A0 =A0DocumentRoot /var/www/primary_dev
> =A0 =A0ServerName dev.primary.com
> =A0 =A0ErrorLog logs/primary_dev-error_log
> =A0 =A0CustomLog logs/primary_dev-access_log common
>
> =A0 =A0 =A0 Options Indexes FollowSymLinks
> =A0 =A0 =A0 AllowOverride All
> =A0 =A0 =A0 =A0Order allow,deny
> =A0 =A0 =A0 =A0Allow from all
>
>
>
> The primary domain works fine, including all the server aliases. What
> doesn't work is dev.primary.com. It isn't accessing the directory
> primary_dev. It's access the directory primary. I can't even begin to gue=
ss
> why. A very similar set up was working just fine when one of the secondar=
y
> domains was the primary domain. Then my client acquired what is now the
> primary domain and this is what I set up. I wish I had the old config to
> look at.
>
> What is even more bizarre is if I go to the old dev site
> (dev.secondaryA.net) then I get the site as it exists in the primary_dev
> directory. That sub-domain should not even exist. I removed all reference=
s
> to that domain in Apache's config and the DNS files last night. I wouldn'=
t
> expect that machine to be answering to that domain name now. (I know just
> enough about setting up DNS to be very dangerous.) =A0Can someone offer s=
ome
> advice as to why this is not working?
Do you have a NameVirtualHost directive anywhere? I would expect a:-
NameVirtualHost 63.134.254.113:80
-- Phil
------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See 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
Re: Virtual hosting problem
am 05.03.2010 17:07:18 von Martin Barry
$quoted_author = "Sean H." ;
>
>
Presume you have the correct NameVirturalHost definition
> ServerName primary.com
> ServerAlias primary.com www.primary.com
> ServerAlias primary.com www.secondaryA.net
> ServerAlias primary.com secondaryB.tv
> ServerAlias primary.com www.secondaryB.tv
> ServerAlias primary.com secondaryC.net
> ServerAlias primary.com www.secondaryC.net
> ServerAlias primary.com secondaryC.com
> ServerAlias primary.com www.secondaryC.com
Wait... what?
Why are you repeating primary.com?
Re-read the example at
http://httpd.apache.org/docs/2.2/mod/core.html#serveralias
> The primary domain works fine, including all the server aliases.
> What doesn't work is dev.primary.com. It isn't accessing the
> directory primary_dev. It's access the directory primary. I can't
> even begin to guess why. A very similar set up was working just fine
> when one of the secondary domains was the primary domain. Then my
> client acquired what is now the primary domain and this is what I
> set up. I wish I had the old config to look at.
Where is the log entry ending up?
> What is even more bizarre is if I go to the old dev site
> (dev.secondaryA.net) then I get the site as it exists in the
> primary_dev directory. That sub-domain should not even exist. I
> removed all references to that domain in Apache's config and the DNS
> files last night. I wouldn't expect that machine to be answering to
> that domain name now. (I know just enough about setting up DNS to be
> very dangerous.) Can someone offer some advice as to why this is
> not working?
The sub-domain exists somewhere. Wildcard? Hosts file?
What order are the VirtualHost containers in?
cheers
Marty
------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See 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