I have a DHCP server which offers a DNS (option domain-name-servers 10.0.0.1;) This is written into /tmp/resolv.conf.auto which is fine. But I'd like to have it also available for the WLAN AP itself - so it should be also find it's way into /tmp/resolv.conf during bootup. Right now I have 127.0.0.1 in it which is useless because my AP has no resolver.
I'm using openwrt-18.06.0-rc2-ar71xx-tiny-tl-wa901nd-v2-squashfs
What option do I need to set?
I am not sure I understand the whole picture here... could you please clarify how many devices are in your network, and how is each one configured?
rm /etc/resolv.conf; ln -s /tmp/resolv.conf.auto /etc/resolv.conf
this did the trick - is this how it should be?
My FreeBSD Router (10.0.0.1 / 10.0.1.1 / 10.0.2.1 is offering DHCP and DNS beside other stuff to my whole network).
My WLAN AP (10.0.2.2) is connected to it and should get it's own IP from it and should use the FreeBSD Router as DNS as well as forward all DHCP requests to it.
+ reis |
| FreeBSD 10 |
| DNS, DHCPD, NTPD, OpenVPN |
| iAtom C2750 - 16GB |
igb1| igb0| igb2|
| | |
| | | +---------------------+
| | | | zwiebel |wlan0
| | +--------------+ Linux 4.9.111 +-o
| | | WLAN-AP |
| | | TP-Link TL-WA901ND |
| | +---------------------+
Well, usually you have a local dnsmasq running on 127.0.0.1 which will forward queries to the servers in /tmp/resolv.conf.auto. By default,
/etc/resolv.conf is a static symlink to
/tmp/resolv.conf file in turn is usually managed by the dnsmasq init script. If dnsmasq is enabled, the init script will write
nameserver 127.0.0.1 into it, if dnsmasq is disabled or stopped,
/tmp/resolv.conf will be deleted and replaced by a direct symlink to
So with dnsmasq started, it'll be:
/etc/resolv.conf -> /tmp/resolv.conf (with
with dnsmasq stopped, it'll be:
/etc/resolv.conf -> /tmp/resolv.conf -> /tmp/resolv.conf.auto.
I am not sure about the initial state when dnsmasq is not installed on the system.
OK - it seems that the root cause was a misconfiguration of my dnsmasq where I was additionally not aware of having it on the system.
After consulting it's manpage and changing /etc/config/dhcp it seems to work now how it is intended to be (with /tmp/resolv.conf). Thanks for the right pointer.....