From b3805bcdd09486d20989863a0ff36627fc252639 Mon Sep 17 00:00:00 2001 From: hyang Date: Fri, 8 Sep 2023 19:21:28 -0700 Subject: Add DNS config section --- content/post/split-tunnelling-for-wireguard-in-linux.md | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'content') diff --git a/content/post/split-tunnelling-for-wireguard-in-linux.md b/content/post/split-tunnelling-for-wireguard-in-linux.md index 42a9418..83d0eff 100644 --- a/content/post/split-tunnelling-for-wireguard-in-linux.md +++ b/content/post/split-tunnelling-for-wireguard-in-linux.md @@ -60,6 +60,12 @@ iptables -t nat -A POSTROUTING -s 10.1.1.1/24" -o $IF -j MASQUERADE iptables -A FORWARD -i $IF -o veth0 -j ACCEPT iptables -A FORWARD -o $IF -i veth0 -j ACCEPT ``` +## DNS +You may need to manually configure the DNS server. We will use Cloudflare's 1.1.1.1 to resolve DNS queries inside the network namespace. +``` +mkdir -p /etc/netns/split +echo "nameserver 1.1.1.1" > /etc/netns/split/resolv.conf +``` ## Conclusion That's it! Now to test it -- cgit v1.2.3