How to change TTL of AWS local DNS resolver?

0

I created nameserver with default TTL of 86400 in AWS instance for experimental purpose. Since I also need host name for my experiment, I decided to use Route 53.

But whenever I 'dig' my DNS record in AWS instance through 169.254.169.253 which is local DNS resolver of AWS I think, it lowers TTL of DNS records to 300 not 86,400.

To be more specific, I add ns record of my domain as my AWS nameserver ip (TTL 3600) and my nameserver contains several values such as TXT record and TLSA record.

asked 2 months ago135 views
1 Answer
1
Accepted Answer

This is an expected behaviour when using AmazonProvidedDNS/Route 53 resolver (VPC CIDR + base 2) as a DNS server in your VPC. When you send a DNS query to AmazonProvidedDNS, if the TTL is greater than 300s, the returned answer will always have a maximum TTL of 300s. Whilst TTL values of less that 300s will be honoured.

Generally, this is due to AWS service limits being in place to ensure optimal performance. Additionally, reducing the TTL can help prevent incorrect records from being cached for long periods, which could prolong outages if the records are updated. Lowering the TTL will reduce the time needed to recover in such a situation.

profile pictureAWS
SUPPORT ENGINEER
Rutba_Z
answered 2 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions