ip a; ip r
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether dc:a6:32:00:42:67 brd ff:ff:ff:ff:ff:ff
inet 192.168.31.150/24 brd 192.168.31.255 scope global eth0
valid_lft forever preferred_lft forever
3: wg0: <POINTOPOINT,NOARP,UP,LOWER_UP> mtu 1420 qdisc noqueue state UNKNOWN group default qlen 1000
link/none
inet 10.6.0.1/24 scope global wg0
valid_lft forever preferred_lft forever
5: br-6fcc2b3163b3: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
link/ether 02:42:f7:10:26:a1 brd ff:ff:ff:ff:ff:ff
inet 172.18.0.1/16 brd 172.18.255.255 scope global br-6fcc2b3163b3
valid_lft forever preferred_lft forever
6: br-9e700094cf5e: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
link/ether 02:42:ea:81:9c:7e brd ff:ff:ff:ff:ff:ff
inet 172.19.0.1/16 brd 172.19.255.255 scope global br-9e700094cf5e
valid_lft forever preferred_lft forever
7: docker0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default
link/ether 02:42:27:50:d0:39 brd ff:ff:ff:ff:ff:ff
inet 172.17.0.1/16 brd 172.17.255.255 scope global docker0
valid_lft forever preferred_lft forever
11: veth9994eb2@if10: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master docker0 state UP group default
link/ether fe:85:22:a0:f7:60 brd ff:ff:ff:ff:ff:ff link-netnsid 0
14: tun0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN group default qlen 500
link/none
inet 10.14.0.6/16 scope global tun0
valid_lft forever preferred_lft forever
0.0.0.0/1 via 10.14.0.1 dev tun0
default via 192.168.31.1 dev eth0 onlink
10.6.0.0/24 dev wg0 proto kernel scope link src 10.6.0.1
10.14.0.0/16 dev tun0 proto kernel scope link src 10.14.0.6
Xxxxxx via 192.168.31.1 dev eth0
128.0.0.0/1 via 10.14.0.1 dev tun0
172.17.0.0/16 dev docker0 proto kernel scope link src 172.17.0.1
172.18.0.0/16 dev br-6fcc2b3163b3 proto kernel scope link src 172.18.0.1 linkdown
172.19.0.0/16 dev br-9e700094cf5e proto kernel scope link src 172.19.0.1 linkdown
192.168.31.0/24 dev eth0 proto kernel scope link src 192.168.31.150
It seems, still the local network gateway address is used and not the VPN tunnel gateway. And activating the killswitch is blocking local network access completely, leading to a failed internet connection, because VPN is not used.
If the killswitch of OFF, are you sure the VPN connection is working? Which IP does following return? You privat external IP address or the global VPN IP address?
I don’t see anything wrong. What is the output of iptables-save -c with the killswitch on?
Also @Joulinarasked you to run the dig dietpi.com with both killswitch off and on but there is only one result.
Right, it was a different post and I missed that.
iptables also look fine. It looks like mullvad is blocking the public dns.
What is the output of cat /etc/resolv.conf with vpn on and off?
cat /etc/resolv.conf # Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
# 127.0.0.53 is the systemd-resolved stub resolver.
# run "resolvectl status" to see details about the actual nameservers.
nameserver 1.1.1.1
nameserver 1.0.0.1
With Kill switch
cat /etc/resolv.conf # Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
# 127.0.0.53 is the systemd-resolved stub resolver.
# run "resolvectl status" to see details about the actual nameservers.
nameserver 1.1.1.1
nameserver 1.0.0.1