Issues with Network Configuration After Upgrading to Rocky Linux

Hey guys… :smiling_face_with_three_hearts:

I recently upgraded my server from CentOS 7 to Rocky Linux 9, and I’m encountering some issues with network configuration that I can’t seem to resolve. The system uses NetworkManager, and the migration itself went smoothly, except for this one major hiccup.

Here’s the problem: after the upgrade, the server intermittently loses connectivity. Sometimes it works fine for a few hours, but then it drops, and I need to manually restart the network service (nmcli connection down/up or systemctl restart NetworkManager) to get it working again.

Here’s what I’ve checked so far:

  1. The /etc/sysconfig/network-scripts/ directory doesn’t seem to be used anymore. I’ve migrated my settings to /etc/NetworkManager/system-connections/.
  2. nmcli shows that the connection is active when the issue occurs, even though I can’t ping or SSH into the server.
  3. The logs (journalctl -u NetworkManager) don’t reveal much, aside from some generic connection timeouts.
  4. I’ve ruled out hardware issues since a temporary boot into a live CentOS image works fine.

My setup uses a static IP with a simple configuration (no bridging or advanced routing). I’m wondering if there’s a compatibility issue with the new version of NetworkManager or if I missed something during the migration.

I also check this: https://forums.rockylinux.org/t/unable-to-install-mariadb-devel-on-rocky-linux-9-repository-issues-and-modular-filteringgoogle-cloud-platform But I have not found any solution. Has anyone encountered a similar issue or can suggest troubleshooting steps? I had really appreciate any guidance or tips!

Thanks in advance…

Respected community member! :innocent:

Please show the contents of /etc/NetworkManager/system-connections/<name>.nmconnection.
Make sure ipv4.method is set to manual. If not, change it and reload the connection.

sudo nmcli connection show <name> | grep ipv4.method

In addition, where it says “the logs”, try without constraining to NetworkManager.

There should be some other network related messages at the exact time it went down.