设置从一个域到另一个域的 CNAME 别名
我正在尝试满足以下无 Cookie 域名建议 Google 的 Page Speed 插件和我的主机遇到了麻烦,他不关心它为什么不起作用的细节。访问 st1.dgcstatic.com 应该与访问 st1.defunctgames.com;然而,事实并非如此。
我是否错过了配置步骤?我需要等待 DNS 传播吗?您可以在下面看到我的实验步骤。
DNS 设置:
- 创建 st1.dgcstatic.com 的 CNAME,指向 dgcstatic.com 上的 st1.defunctgames.com
- 在 defunctgames.com 上创建 st1.defunctgames.com 的记录
- 创建 st1 的子域。 defunctgames.com 上的 defunctgames.com
当我运行 tracert st1.dgcstatic.com
时,它会生成以下内容结果:
C:\Users\Patrick>tracert st1.dgcstatic.com
Tracing route to st1.defunctgames.com [50.22.11.10]
当我运行 host st1.dgcstatic.com
时,它会产生以下结果:
patrick:~ patrick$ host st1.dgcstatic.com
st1.dgcstatic.com is an alias for st1.defunctgames.com.
st1.defunctgames.com has address 50.22.11.10
最后,使用此站点似乎会产生与显示正确配置的内容相同的结果。
http://www.mxtoolbox.com/SuperTool.aspx?action =mx%3ast1.dgcstatic.com
根据所有这些结果,全世界都可以看到我的 DNS 更改,另一方面,当被问及原因时,我的主机给了我“等待传播”的胡言乱语这不起作用。
I'm attempting to satisfy the Cookieless domain suggestion of Google's Page Speed plugin and am running into a wall with my host who can't be bothered with the details of why it's not working. Accessing st1.dgcstatic.com should be the same as accessing st1.defunctgames.com; however, this is not the case.
Have I missed a step of configuration? Do I need to wait for DNS propagation? You can see below my steps of experimentation.
DNS Setup:
- Created CNAME of st1.dgcstatic.com to point to st1.defunctgames.com on dgcstatic.com
- Created A record of st1.defunctgames.com on defunctgames.com
- Created sub-domain of st1.defunctgames.com on defunctgames.com
When I run a tracert st1.dgcstatic.com
it produces the following result:
C:\Users\Patrick>tracert st1.dgcstatic.com
Tracing route to st1.defunctgames.com [50.22.11.10]
When I run a host st1.dgcstatic.com
it produces the following result:
patrick:~ patrick$ host st1.dgcstatic.com
st1.dgcstatic.com is an alias for st1.defunctgames.com.
st1.defunctgames.com has address 50.22.11.10
And finally, using this site it seems to produce the same results of showing things configured correctly.
http://www.mxtoolbox.com/SuperTool.aspx?action=mx%3ast1.dgcstatic.com
According to all these results, the world can see my DNS changes, my host on the other hand gave me the "Wait for propagation" rigmarole When asked why this isn't working.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在我看来,您的域名设置正确(st1.dgcstatic.com 是 st1.defunctgames.com 的别名),但网络主机需要有映射或配置才能知道如何提供 st1.dgcstatic.com内容。
两个域都解析为 50.22.11.10,但这很可能是共享 IP 地址主机。 (访问 http://50.22.11.10 表明它是共享的 - 它无法仅通过 IP 地址解析到您的网站.)
您需要通过您的网络主机提供商配置第二个域。托管公司的做法有所不同;就我而言,只需向我的帐户添加一个新域(每月额外 1 美元),并配置 HTML 源文件的路径即可。
It looks to me that your domain names are set up correctly (st1.dgcstatic.com is an alias of st1.defunctgames.com), but the web host needs to have a mapping or configuration to know how to serve st1.dgcstatic.com content.
Both domains are resolving to 50.22.11.10, but that is most likely a shared IP address host. (Visiting http://50.22.11.10 demonstrates that it's shared - it can't resolve to your site just by the IP address.)
You'll need to configure through your webhost provider the second domain. Hosting companies do this differently; in my case it's just a matter of adding a new domain to my account (extra $1/mo), and configuring the path for HTML source files.