Hi,
I want to have an additional subdomain like this:
The problem is that sub.mydomain.com can’t be resolved (gives an “address not found” error when opening in FF).
The “normal” domain mydomain.com is working. I can also ping the subdomain.
In vhosts I have sub.mydomain.com.conf:
<VirtualHost *:80>
ServerAdmin webmaster@mydomain.com
ServerName mydomain.com
DocumentRoot /srv/www/htdocs
HostnameLookups Off
UseCanonicalName Off
ServerSignature On
<Directory "/srv/www/htdocs">
Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
<VirtualHost *:80>
ServerAdmin webmaster@sub.mydomain.com
ServerName sub.mydomain.com
DocumentRoot /srv/www/vhosts/sub.mydomain.com
HostnameLookups Off
UseCanonicalName Off
ServerSignature On
<Directory "/srv/www/vhosts/sub.mydomain.com">
Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
There is an index.html file in both directories /srv/www/htdocs/index.html and /srv/www/vhosts/sub.mydomain.com/index.html
listen.conf:
NameVirtualHost *:80
/etc/hosts:
127.0.0.1 localhost
1.2.3.4 mydomain.com
1.2.3.4 sub.mydomain.com
Is there anything I’m missing ?
Thanks a lot !