Could not activate connection: Connection 'ens33' is not available on device ens33 because device is strictly unmanaged

Latest response

Hi,

I have one RedHat8 virtual machine connected via bridge to my Wifi router, in order to have connection to outside.

The machine has an static IP configuracion settled in the /etc/sysconfig/network-scripts path as follows:

[root@system network-scripts]# cat ifcfg-ens33
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=none
IPV4INIT=yes
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
NAME=ens33
DEVICE=ens33
ONBOOT=yes
IPADDR=192.168.0.40
PREFIX=24
GATEWAY=192.168.0.1
DNS1=192.168.0.1
DOMAIN=example.com
IPV6INIT=no
UUID=c96bc909-188e-ec64-3a96-6a90982b08ad

But when I execute it appears that the the network devices ( indeed all of them) are strictly unmanaged:

[root@system network-scripts]# nmcli
virbr0: unmanaged
        "virbr0"
        bridge, 52:54:00:3C:B9:DD, sw, mtu 1500

ens33: unmanaged
        "Intel 82545EM"
        ethernet (e1000), 00:0C:29:1A:D0:D0, hw, mtu 1500

lo: unmanaged
        "lo"
        loopback (unknown), 00:00:00:00:00:00, sw, mtu 65536

virbr0-nic: unmanaged
        "virbr0-nic"
        tun, 52:54:00:3C:B9:DD, sw, mtu 1500

vnet0: unmanaged
        "vnet0"
        tun, FE:54:00:0A:5C:6D, sw, mtu 1500

I dont understand why because NetworkManager is up and running :

[root@system ~]# systemctl status  NetworkManager
● NetworkManager.service - Network Manager
   Loaded: loaded (/usr/lib/systemd/system/NetworkManager.service; enabled; vendor preset: enabled)
   Active: active (running) since Tue 2021-08-24 23:50:48 CEST; 6min ago
     Docs: man:NetworkManager(8)

Also, I have tried to restart the service, but I have not succeeded

Later on, I have tried to changed this state using the GUI interface , executing nmtui comand, everything was indeed configured, but ,when I have tried to activate the connection, nmtui, warns me that I cannot:

Could not activate connection: Connection 'ens33' is not available on device ens33 because device is strictly unmanaged

What am I doing wrong?

I would appreciate if anyone could provide any help to solve this issue

Thanks in advance

Responses

If you've added the device ens33 to libvirt's network managent, that might affect NetworkManager's ability to manage the device. If so, remove the device from libvirt and hopefully NM will be able to pick it up with a restart of the NM service?

I also found this answer on Stackexchange where someone enabled management for the ifupdown plugin.

The accepted answer on that doesn't make sense to me, because the ifupdown ships with Debian/Ubuntu and not RHEL/CentOS, so I don't see how the accepted answer actually works at all (the poster was using CentOS 7).

But at least it gives a hint to check /etc/NetworkManager/NetworkManager.conf and /etc/NetworkManager/conf.d/ to see if there's a managed=false entry which could be changed.

Failing that, you could enable NetworkManager debugging and see if the additional logging gives a reason why the device is unmanaged.