Ubuntu Error: Connection activation failed: Connection is not available on device because device is strictly unmanaged

Hey all,

Ubuntu 20.04 LTS desktop user here. Suddenly my networking Ethernet and Wireguard become
unmanaged. When I type nmcli connection up wg0, I get failed to activate error:

Error: Connection activation failed: Connection 'wg0' is not available on device wg0 because device is strictly unmanaged

Same problem with Ethernet. It started after updating system:

Error: Connection activation failed: Connection 'Wired connection 1' is not available on device enp0s3 because device is strictly unmanaged

How to fix it?

Here are steps to check and solve the problem for NetworkManager under Ubuntu Linux when you get the “device is strictly unmanaged” message.

Step 1 - Check for netplan settings

Make sure renderer is NetworkManager in the /etc/netplan/:

ls /etc/netplan/
# if config file is 01-network-manager-all.yaml
cat /etc/netplan/01-network-manager-all.yaml

Check for /etc/NetworkManager/NetworkManager.conf file too:

sudo cat /etc/NetworkManager/NetworkManager.conf

Step 2 - List managed devices

Type:

nmcli device

Note down unmanaged devices and their type, such as wifi, ethernet, wireguard, etc.

Step 3 - Check /etc/NetworkManager/conf.d/ directory

Make sure your device is not marked as unmanaged-devices

sudo grep -ri unmanaged-devices /etc/NetworkManager/conf.d/
sudo grep -ri unmanaged-devices /etc/NetworkManager/

Step 4 - Check for /usr/lib/NetworkManager/conf.d/10-globally-managed-devices.conf file

sudo vim /usr/lib/NetworkManager/conf.d/10-globally-managed-devices.conf

Make sure Ethernet, Wifi, WireGuard all set as exception. Here is how it looks when ethernet and wireguard disabled:

[keyfile]
unmanaged-devices=*,except:type:wifi,except:type:gsm,except:type:cdma

Add ethernet by appending to the unmanaged-devices list. For example:

except:type:ethernet

For wireguard:

except:type:wireguard

Here is how it should look:

[keyfile]
unmanaged-devices=*,except:type:wifi,except:type:gsm,except:type:cdma,except:type:ethernet,except:type:wireguard

Finally reload config:

sudo systemctl reload NetworkManager.service 

Verify it:

nmcli device
nmcli connection show

Turn networking off and on again:

nmcli networking off
nmcli networking on

Test it:

nmcli connection up wg0
nmcli connection up 'Wired connection 1'
5 Likes

awesome! its worked for me

Happy to help and good to know.

Thank you for your help. I struggled until I found the solution here. One part was missing in my system, which is step 4.
That solved the problem immediately.

Thank you,