Before connecting the VPN, `systemd-resolve --status` shows :
DNS Servers: 192.168.1.254 # my home box resolver
After connecting :
DNS Servers: 10.0.0.254 # DNS resolver provided by the VPN server 192.168.1.254 # my home box resolver
This seems OK, but the resolution fails as it is still using the local DNS :
systemd-resolved[270]: Server returned error NXDOMAIN, mitigating potential DNS violation DVE-2018-0001, retrying transaction with reduced feature level UDP.
After issuing `systemctl reload-or-restart systemd-resolved.service`, everything seems fine.
systemd-resolved[5651]: Got DNS stub UDP query packet for id 24298
systemd-resolved[5651]: Looking up RR for my.host.inside.vpn IN A.
systemd-resolved[5651]: Switching to DNS server 10.0.0.254 for interface enp0s3.
systemd-resolved[5651]: Cache miss for my.host.inside.vpn IN A
systemd-resolved[5651]: Transaction 9273 for <my.host.inside.vpn IN A> scope dns on enp0s3/*.
systemd-resolved[5651]: Using feature level UDP+EDNS0 for transaction 9273.
systemd-resolved[5651]: Using DNS server 10.0.0.254 for transaction 9273.
I was hoping that `systemd-resolved` could find the new DNS without restarting its service after connecting to the VPN.
Ubuntu 18.04.1 / bionic
Fresh install on a VM, was facing a bug when connecting to strongswan ikev2 vpn (https:/ /bugs.launchpad .net/ubuntu/ +source/ strongswan/ +bug/1772705)
-> Updated from cosmic the required packages for the VPN that has the bug fixed (5.6.2-2):
network- manager- strongswan: archive. ubuntu. com/ubuntu cosmic/universe amd64 Packages dpkg/status fr.archive. ubuntu. com/ubuntu bionic/universe amd64 Packages extra-plugins: archive. ubuntu. com/ubuntu cosmic/main amd64 Packages dpkg/status fr.archive. ubuntu. com/ubuntu bionic/main amd64 Packages standard- plugins: archive. ubuntu. com/ubuntu cosmic/main amd64 Packages dpkg/status fr.archive. ubuntu. com/ubuntu bionic/main amd64 Packages extra-plugins: archive. ubuntu. com/ubuntu cosmic/main amd64 Packages dpkg/status fr.archive. ubuntu. com/ubuntu bionic/main amd64 Packages standard- plugins: archive. ubuntu. com/ubuntu cosmic/main amd64 Packages dpkg/status fr.archive. ubuntu. com/ubuntu bionic/main amd64 Packages
Installé : 1.4.4-1
Candidat : 1.4.4-1
Table de version :
*** 1.4.4-1 300
300 http://
100 /var/lib/
1.4.2-2 500
500 http://
libcharon-
Installé : 5.6.2-2ubuntu1
Candidat : 5.6.2-2ubuntu1
Table de version :
*** 5.6.2-2ubuntu1 300
300 http://
100 /var/lib/
5.6.2-1ubuntu2 500
500 http://
libcharon-
Installé : 5.6.2-2ubuntu1
Candidat : 5.6.2-2ubuntu1
Table de version :
*** 5.6.2-2ubuntu1 300
300 http://
100 /var/lib/
5.6.2-1ubuntu2 500
500 http://
libstrongswan-
Installé : 5.6.2-2ubuntu1
Candidat : 5.6.2-2ubuntu1
Table de version :
*** 5.6.2-2ubuntu1 300
300 http://
100 /var/lib/
5.6.2-1ubuntu2 500
500 http://
libstrongswan-
Installé : 5.6.2-2ubuntu1
Candidat : 5.6.2-2ubuntu1
Table de version :
*** 5.6.2-2ubuntu1 300
300 http://
100 /var/lib/
5.6.2-1ubuntu2 500
500 http://
Before connecting the VPN, `systemd-resolve --status` shows :
DNS Servers: 192.168.1.254 # my home box resolver
After connecting :
192.168. 1.254 # my home box resolver
DNS Servers: 10.0.0.254 # DNS resolver provided by the VPN server
This seems OK, but the resolution fails as it is still using the local DNS : resolved[ 270]: Server returned error NXDOMAIN, mitigating potential DNS violation DVE-2018-0001, retrying transaction with reduced feature level UDP.
systemd-
After issuing `systemctl reload-or-restart systemd- resolved. service` , everything seems fine.
systemd- resolved[ 5651]: Got DNS stub UDP query packet for id 24298 resolved[ 5651]: Looking up RR for my.host.inside.vpn IN A. resolved[ 5651]: Switching to DNS server 10.0.0.254 for interface enp0s3. resolved[ 5651]: Cache miss for my.host.inside.vpn IN A resolved[ 5651]: Transaction 9273 for <my.host.inside.vpn IN A> scope dns on enp0s3/*. resolved[ 5651]: Using feature level UDP+EDNS0 for transaction 9273. resolved[ 5651]: Using DNS server 10.0.0.254 for transaction 9273.
systemd-
systemd-
systemd-
systemd-
systemd-
systemd-
I was hoping that `systemd-resolved` could find the new DNS without restarting its service after connecting to the VPN.
Thanks for reading
Best Regards,
Vincet