2

I would like to use option values in /etc/resolv.conf. From reviewing the relevant man page (https://linux.die.net/man/5/resolv.conf) I noticed that I can configure various options. For example one can set the timeout on dns requests using options timeout:10. Another example is to use attempts option to control the number of retries for DNS resolution. So far so good.

The problem is that systemd-resolvd edits the file. From what I can tell one needs to edit resolved.confg file to set the options that resolved will use. Relevant man page - https://jlk.fjfi.cvut.cz/arch/manpages/man/resolved.conf.5. The problem here is that the options that I want to set are not exposed in the resolved.conf file.

Is there a way to configure these parameters via systemd-resolved? Should I just edit /etc/resolve.conf and be done with it?

kfir
  • 111
  • 4

1 Answers1

1

If you want to keep systemd managed resolv.conf there is currently no possibility to add other options, it only writes search domains and nameservers and that's it: https://github.com/systemd/systemd/blob/main/src/resolve/resolved-resolv-conf.c#L324

danman
  • 113
  • 5