bottlerocket icon indicating copy to clipboard operation
bottlerocket copied to clipboard

Adding local DNS cache

Open danmx opened this issue 4 years ago • 7 comments

What I'd like:

So see a local DNS cache (e.g. dnsmasq) baked into the OS image to improve DNS resolution performance.

Any alternatives you've considered:

Adding it to my fork of bottlerocket but it seems like a such generic issue it could be addressed in the source.

danmx avatar May 01 '20 10:05 danmx

Hi @danmx!

Could you provide more details about your setup? Would you be wanting the DNS cache for the host or for the containers?

zmrow avatar May 04 '20 20:05 zmrow

My team is looking into setting DNS cache for both OS and containers. The setup should look like this: dnsmasq (running locally) -> NodeLocal (running locally) -> CoreDNS (running remotely)

danmx avatar May 05 '20 09:05 danmx

You can run a local DNS cache in a container and configure your containers to use it pretty easily. One example for running this type of setup on Kubernetes is https://kubernetes.io/docs/tasks/administer-cluster/nodelocaldns/.

chancez avatar Sep 02 '20 03:09 chancez

Hello! I wanted to check in and see if having DNS cache in containers was sufficient for you or if having DNS cache on the host ended up being a requirement?

WilboMo avatar Aug 25 '21 18:08 WilboMo

In the end I moved to solutions like Istio's DNS sidecar or Cilium's DNS Proxy

danmx avatar Aug 26 '21 06:08 danmx

Thanks for the update, I'm glad to hear you found a solution that works for you. We'll keep this issue open for consideration in future releases.

WilboMo avatar Aug 27 '21 17:08 WilboMo

Does 1.28 release added something of DNS or resolver running on the same port 53?

i am running local-node-dns on the cluster and 1.27 was fine but with 1.28 i get

Listen: listen tcp 0.0.0.0:53: bind: address already in use

ami-descope avatar Jan 11 '24 14:01 ami-descope