Must use www for DNS entry using Amazon Route53

时光毁灭记忆、已成空白 提交于 2020-01-30 19:56:21

问题


I administered my domain e.g www.abcd.com in Amazon Route53. Everything works perfectly, except that when user type abcd.com without www, it won't get resolved. Any idea? Thanks


回答1:


I think this might work:

Select an IPv4address and select the "Alias" radio button.

Leave the name field blank to indicate domain.com

Then the target is www.domain.com

I'll give it a try and let you know.




回答2:


To have your domain.com (without www) on Amazon Route53 you need:

  • Go to your record sets;
  • Create a Record Set, type A - IPv4 Address;
  • Put your domain.com or www.domain.com on value and save.

On my case I create a new record set for www.domain too, but with type CNAME and put my ec2 domain.

[edit] Print of my current configuration:

[update] If not work for you then you need to check your apache configuration. Check the ServerName and ServerAlias to allow *.yoursite.com or just www.yoursite.com. Don't forget restart your apache after changes.




回答3:


Here is the solution that worked for me.

  1. Name: www.domain.com
  2. Type: A - IPv4 Address
  3. Alias: Yes
  4. Alias Target: Select the value from the drop-down list that you have for domain.com
  5. Leave other settings and press Save Record Set

By the way Amazon does not charge for Alias queries. More information here.

Amazon Route 53 doesn't charge for alias queries to CloudFront distributions, ELB load balancers, or Amazon S3 buckets.




回答4:


For Goddady domain migrated to AWS, I took the basic configuration for domain.com and modified it a bit.

Search for somethin like this in your record set:

Name: domain.com (or www.domain.com)
Type: A - IPv4 address
Alias: No
Value: a_random_ip_address

I just added a new record set with:

Name: www.domain.com (or domain.com)
Type: A - IPv4 address
Alias: No
Value: a_random_ip_address

Remember afterwards to add www to your server (nginx, apache, etc)




回答5:


The name abcd.com has to have its own resource records to be resolved other than those of www.abcd.com.




回答6:


Yes, this record is called your "zone apex" -- the bigcompany.com address, not www.bigcompany.com. You can use an IP value there, or you can specify an "alias" and point it to an ELB.

(Note: Route53 does NOT like @ values for either the record name or value.)




回答7:


Route 53 doesn't allow naked domain redirection. There are some tricky ways around it though.

More:

https://forums.aws.amazon.com/thread.jspa?threadID=55995#




回答8:


The following works for me:

For www.XYZ.com

  • Create Record Set
  • Name: *.XYZ.com
  • Set Type A Type
  • Alias: No
  • Value: 127.0.0.123 (you website IP)

For XZY.com

  • Create Record Set
  • Name: XYZ.com (nothing to write here - leave it blank)
  • Set Type A Type
  • Alias: Yes
  • Value: (wait a second for the Drop Down menu) - choose \052.XYZ.com

You can test with https://dnschecker.org if it works or not



来源:https://stackoverflow.com/questions/9559698/must-use-www-for-dns-entry-using-amazon-route53

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!