From 656412d1a3806d94b280a9955df528faad6aa8e9 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Mon, 8 Jan 2007 21:33:53 +0000 Subject: Forward port whiterussian resolv.conf changes /etc/resolv.conf links to /tmp/resolv.conf /tmp/resolv.conf links to /tmp/resolv.conf.auto by default (which is where the ISPs nameserver is in) When dnsmasq starts, it replaces /tmp/resolv.conf with a file pointing to 127.0.0.1 SVN-Revision: 6043 --- package/dnsmasq/files/dnsmasq.conf | 2 +- package/dnsmasq/files/dnsmasq.init | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) (limited to 'package/dnsmasq') diff --git a/package/dnsmasq/files/dnsmasq.conf b/package/dnsmasq/files/dnsmasq.conf index 8a51f84..8a8191b 100644 --- a/package/dnsmasq/files/dnsmasq.conf +++ b/package/dnsmasq/files/dnsmasq.conf @@ -8,7 +8,7 @@ localise-queries local=/lan/ domain=lan expand-hosts -resolv-file=/tmp/resolv.conf +resolv-file=/tmp/resolv.conf.auto @ifdef dhcp_enable dhcp-range=@@start@@,@@end@@,@@netmask@@,@@lease@@ diff --git a/package/dnsmasq/files/dnsmasq.init b/package/dnsmasq/files/dnsmasq.init index 7afcee4..5e72fd0 100644 --- a/package/dnsmasq/files/dnsmasq.init +++ b/package/dnsmasq/files/dnsmasq.init @@ -50,7 +50,13 @@ start() { [ -z "$wan_proto" -o "$wan_proto" = "none" ] || echo "@define wan_ifname $wan_ifname" cat /etc/dnsmasq.conf - ) | awk -f /lib/config/template.awk | dnsmasq -C /proc/self/fd/0 + ) | awk -f /lib/config/template.awk | dnsmasq -C /proc/self/fd/0 && { + rm -f /tmp/resolv.conf + cat > /tmp/resolv.conf <