我们建立了一个带有表格和感谢页面的简单网站:http://healthcity.giveitatry.nl/。这在我们的电脑上工作得非常好。使用 CMS,网站管理员可以创建多个这样的表单,例如 sportsclubx.giveitatry.nl 或 sportsunlimited.giveitatry.nl(最后两个是示例。尚未制作)。
为了使子域名正常工作,我们有 2 个 DNS A 记录:
A *.giveitatry.nl 5.157.80.226
A giveitatry.nl 5.157.80.226
在服务器上我们有以下虚拟主机:
<VirtualHost *:80>
DocumentRoot "/var/www/giveitatry"
ServerName giveitatry.nl
ServerAlias *.giveitatry.nl
<Directory "/var/www/giveitatry">
allow from all
Options +Indexes
AllowOverride All
</Directory>
</VirtualHost>
在我们办公室的所有电脑上(除了一台),我们可以使用多个浏览器访问 URL,甚至可以使用ping
etc... 但有一个 MAC 地址会获取SERVER NOT FOUND
。我们刷新了他电脑上所有能想到的 DNS 缓存,但什么也没改变。我们客户的几台电脑都出现了同样的错误 或DNS not found
或ERR_NAME_NOT_RESOLVED
。似乎它们从未获取过我们服务器的 IP。
如果有人需要的话,我会添加我的整个虚拟主机配置:
<VirtualHost *:80>
DocumentRoot /var/www/giveitatry
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "/var/www/xxxxxx"
ServerName xxxxxx.nl
ServerAlias www.xxxxx.nl
<Directory "/var/www/xxxxx">
allow from all
Options +Indexes
AllowOverride All
</Directory>
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "/var/www/"
ServerName xxxxxx.nl
ServerAlias www.xxxxx.nl
<Directory "/var/www/">
allow from all
Options +Indexes
AllowOverride All
</Directory>
</VirtualHost>
<VirtualHost *:80>
DocumentRoot "/var/www/giveitatry"
ServerName giveitatry.nl
ServerAlias *.giveitatry.nl
<Directory "/var/www/giveitatry">
allow from all
Options +Indexes
AllowOverride All
</Directory>
</VirtualHost>
<VirtualHost *:12322>
SSLEngine on
ServerAdmin webmaster@localhost
DocumentRoot /usr/share/adminer/adminer
Alias /adminer/static /usr/share/adminer/adminer/static
Alias /externals /usr/share/adminer/externals
Alias /editor /usr/share/adminer/editor
</VirtualHost>
<Directory /usr/share/adminer/adminer>
Options FollowSymLinks
DirectoryIndex index.php
<IfModule mod_php5.c>
AddType application/x-httpd-php .php
php_flag magic_quotes_gpc Off
php_flag track_vars On
php_flag register_globals Off
php_value include_path .
</IfModule>
</Directory>
<Directory /usr/share/adminer/editor>
Options FollowSymLinks
DirectoryIndex index.php
<IfModule mod_php5.c>
AddType application/x-httpd-php .php
php_flag magic_quotes_gpc Off
php_flag track_vars On
php_flag register_globals Off
php_value include_path .
</IfModule>
</Directory>
答案1
DNS 通配符和 DNSSEC 并不总是能很好地协同工作,而您的域名就属于这种情况。请查看http://0skar.cz/dns/en/测试一些东西,特别是针对无法访问您网站的计算机。另外,一定要检查它们正在使用哪个递归名称服务器。