1

Working with ubuntu 20.04, upgraded from 18.04 some time ago.

I need to be connected to my companys vpn, so I installed nm-connection-manager and configured my "Wired Connection 1" to always connect to vpn when connected and to automatically connect to "Wired Connection 1" if available. I also noticed a wired connection called "netplan-enp0s34f6", with IPv6 disabled. I deleted this connection.

On the next reboot, the wired "netplan" connection was back, with a slightly different name "netplan-enp0s98d3" or similar, and connected by default.

So I thought: "ok, I use that connection then", configured it to connect automatically to vpn and thought nothing bad.

The next day I booted up my laptop and the "old" "netplan-enp0s98d3" connection was away and a new "netplan-XXX" connection in place, rendering all my "auto vpn connection"-configuration useless.

What is going on? How can I use my "Wired Connection 1" with IPv6 and auto vpn connection all the time?

Why is Gnome creating and dropping network connctions on every boot? Why are they called "netplan-*" ?

How can I disable this behaviour?

Any help appreciated.

mondjunge
  • 3,336

1 Answers1

0

So the problem is/was, that network-manager seems to fully control its automatic created Connections Wired 1 and netplan-XY.

The linked answers from pierrely helped me understand this: Ubuntu only permanently saves changes to a network if it was created explicit by yourself.

The solution is to create a new wired network connection, I did it with nm-connection-manager and called it "My Ethernet connection".

I also checked "connect to this network if available" and "automatically connect to vpn"

Now the connection stays even after reboot and connects to vpn instantly.

Another Problem I ran into, was vpn connection got lost after suspend/hibernate and did not reconnect.

Some other question/answer suggested that I should make my vpn Passwort available for all users and that did the trick. You can do that in System Settings > Network > VPN > Identity , right beside the Password field is an icon where you can set the password to be used by all users.

I hope this helps somebody else. Cheers.

mondjunge
  • 3,336