sâm., 30 oct. 2021, 03:10 Zé Loff <zel...@zeloff.org> a scris: > On Fri, Oct 29, 2021 at 09:57:26PM +0300, Samarul Meu wrote: > > On Fri, Oct 29, 2021 at 8:30 PM Zé Loff <zel...@zeloff.org> wrote: > > > > > This works for me: > > > > > > > > > /etc/hostname.em0: > > > > > > inet autoconf > > > > > > > > > /etc/resolv.conf: > > > > > > nameserver 127.0.0.1 > > > > > > > > > /etc/dhcpleased.conf: > > > > > > interface em0 { > > > ignore dns > > > } > > > > > > > > My dhcpleased.conf is similar (interface urtwn0 ignore dns), but it does > > not seem to work. resolvd just overwrites the resolv.conf with the ISP > DNS. > > If I disable resolvd and I leave only nameserver 127.0.0.1 the unbound > > works as expected. > > > > Now, my question is when ignore dns from dhcpleased.conf is considered? > The > > man page states "Ignore nameservers from leases on this interface" but > > maybe I am not reading it correctly? > > Is that the exact contents of your dhcpleased.conf? Reading the man > page, it seems that the curly brackets are mandatory, and if I change my > config to "interface em0 ignore dns" dhcpleased warns about the syntax > error (and doesn't start). >
Yes, at first I was ignoring the curly brackets, but I received no warning and still got an IP, but after I have seen your configuration I made the change. Did not help, The thing is that maybe I do not understand corectly the new way. I thought that by specifying in dhcpleased.conf that you what to ignore the DNS then resolvd will leave the resolved.conf untouched. In my case it does not happen, so I have to just disable resolvd. Thank you for your time! I will just leave resolvd disabled and resolv.conf with only 127.0.0.1 in it. >