When connecting the strongswan VPN, I see that the /run/systemd/resolve/resolv.conf file is touched (the timestamp of the file changes), but the content does not change.
Automatic nor manual DNS servers in the VPN settings do work.
I tested manual modifying the /run/systemd/resolve/resolv.conf by changing the nameserver. This works once, but this change is not persisted, as the file is overwritten each time.
However the file /run/NetworkManager/no-stub-resolv.conf does contain the nameservers that are automatically provided by the VPN connection.
This solved the issue for me:
$ sudo rm /etc/resolv.d
$ sudo ln -s /run/NetworkManager/no-stub-resolv.conf /etc/resolv.conf
I am running Ubuntu Desktop, not Ubuntu Server (if that is relevant).
It is fully up to date: Linux myhost 5.4.0-48-generic #52-Ubuntu SMP Thu Sep 10 10:58:49 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
I have this issue as well. However, the instructions given in https:/ /bugs.launchpad .net/ubuntu/ +source/ systemd/ +bug/1624320/ comments/ 57 do not solve the issue for me.
When connecting the strongswan VPN, I see that the /run/systemd/ resolve/ resolv. conf file is touched (the timestamp of the file changes), but the content does not change.
Automatic nor manual DNS servers in the VPN settings do work.
I tested manual modifying the /run/systemd/ resolve/ resolv. conf by changing the nameserver. This works once, but this change is not persisted, as the file is overwritten each time.
However the file /run/NetworkMan ager/no- stub-resolv. conf does contain the nameservers that are automatically provided by the VPN connection.
This solved the issue for me: ager/no- stub-resolv. conf /etc/resolv.conf
$ sudo rm /etc/resolv.d
$ sudo ln -s /run/NetworkMan
I am running Ubuntu Desktop, not Ubuntu Server (if that is relevant).
It is fully up to date: Linux myhost 5.4.0-48-generic #52-Ubuntu SMP Thu Sep 10 10:58:49 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux