Network manager and split DNS for a VPN?
Tom H
tomh0665 at gmail.com
Wed Apr 12 15:27:57 UTC 2017
On Wed, Apr 12, 2017 at 3:13 AM, Xen <list at xenhideout.nl> wrote:
> Karl Auer schreef op 12-04-2017 1:03:
>
>> It *should* work, and dnsmasq it even *looks* as if it is doing it, but
>> it isn't actually working. Here is a sample bit of dnsmasq log file
>> after the VPN comes up:
>
> Question: can you query the dnsmasq contents while it is running?
>
> I never really liked the fact that dnsmasq (as a local nameserver) is used
> by default by NetworkManager,
>
> although I guess it moves the inflexibility (?) of /etc/resolv.conf to
> something more developed.
>
> For a user seeing /etc/resolv.conf output something like:
>
> 127.0.1.1 localhost
>
> and then not being able to verify the contents of that nameserver is a bit
> disheartening.
>
> Particularly as I think the commands are updated over dbus and the user has
> no control over that at all.
root at localhost ~ # cat nm.sh
#!/bin/sh
echo "#### using uuid ####"
nmcli -f IP4 c sh uuid $(nmcli -t -f UUID c sh --active)
echo
echo "#### using id ####"
nmcli -f IP4 c sh id "$(nmcli -t -f NAME c sh --active)"
root at localhost ~ # ./nm.sh
#### using uuid ####
IP4.ADDRESS[1]: 192.168.0.108/24
IP4.GATEWAY: 192.168.0.1
IP4.DNS[1]: 8.8.8.8
IP4.DNS[2]: 8.8.4.4
#### using id ####
IP4.ADDRESS[1]: 192.168.0.108/24
IP4.GATEWAY: 192.168.0.1
IP4.DNS[1]: 8.8.8.8
IP4.DNS[2]: 8.8.4.4
[previous versions of NM had "nm-tool"]
More information about the ubuntu-users
mailing list