Why is my attempt to add an A record to Route53 using the AWS CLI failing?

I expect I’m missing something dumb here. Can anyone see what I’m missing?

I have a file named /tmp/r53.json that contains the following:

    "Changes": [{
    "Action": "UPSERT",
        "ResourceRecordSet": {
            "Name": "squidproxy.idev.in.",
            "Type": "A",
            "TTL": 300,
            "ResourceRecords": [ {"Value": ""} ]

And I am running the command:

aws route53 change-resource-record-sets --hosted-zone-id Z30M8MWTQXQ2O2 --change-batch file:///tmp/r53.json

which give me the error:

An error occurred (InvalidChangeBatch) when calling the ChangeResourceRecordSets operation: [RRSet with DNS name squidproxy.idev.in. is not permitted in zone iddev.in.]

I know that I have specified the zone correctly because I see the zone name iddev.in in the error message, and I’m not specifying that name anywhere.

Why is this command failing?

>Solution :

Your domain name squidproxy.idev.in is not a subdomain of iddev.in. Your root domain has two d characters in it (iddev) while the record you are trying to create has one d character in it (idev).

Leave a Reply