I have two identical VH in httpd/conf.d/.
//test.conf
<VirtualHost *:80>
ServerName testadmin.mysite.it
DocumentRoot /var/www/html/testadmin
</VirtualHost>
//release.conf
<VirtualHost *:80>
ServerName deploy.mysite.it
DocumentRoot /var/www/html/release
</VirtualHost>
httpd -S|grep release
port 80 namevhost release.mysite.it (/var/www/mysite/deploy.conf:1)
But a ping on test.mysite.it
works, a ping on deploy.mysite.it
does not.
I know ping is not the best tool to check. Both subdomains are handled by the same webserver, as you can see from the VH. But testadmin.mysite.it is reachable in the browser (it is resolved), the other is not.
Sure, if I put in my /etc/hosts the mapping
<ip of webserver> release.mysite.it
it works.
My question is: if I had not to set up the host for the first site, why I have to do it for the second?
There is something I can use to check for this problem?
Both files are included in http.conf
.