I've recently picked up Rocky Linux 9.1 and am trying to get the basic networking to work correctly using netplan and networkmanager. There must be something simple missing here...
I have a very simple NetPlan yaml:
network:
version: 2
renderer: NetworkManager
eno5:
dhcp4: true
Simple - just want an automatic DHCP IP address on eno5 when it is plugged in. If the network cable is plugged in on boot, or I manually run the following, it works.
sudo netplan generate
sudo nmcli conn reload
However - if I just unplug the ethernet cable and plug it into my second home network, I don't get a new DHCP address on the second network. The NIC link goes down and back up, but no new connection AND the existing connection doesn't get shut down - it still shows the old IP address, etc... while the cable is unplugged.
How do I get the link coming up to trigger a new connection? I've found some info on the NetworkManager Dispatcher, but nothing with a simple answer for a basic connection.
Even with a fresh install of Rocky 9.1 with an ethernet connection configured and working during the install - how can it not do something as fundamental as disconnect and reconnect to a network?