Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CentOS 8 and networking state #54791

Open
ghost opened this issue Sep 27, 2019 · 14 comments
Open

CentOS 8 and networking state #54791

ghost opened this issue Sep 27, 2019 · 14 comments
Labels
Bug broken, incorrect, or confusing behavior P1 Priority 1 severity-high 2nd top severity, seen by most users, causes major problems ZD The issue is related to a Zendesk customer support ticket.

Comments

@ghost
Copy link

ghost commented Sep 27, 2019

network.txt

Description of Issue

With latest salstack 2019 i can't find a way to manage networking on CentOS 8 with state.network, maybe because of CentOS8 rely on networkmanager

Setup

sls file attached, but with centos6 and centos7 it work without any issue.

Steps to Reproduce Issue

try to configure networking on CentOS8, no ifcfg-ifname is generated, and network dosen't work after reboot

Versions Report

Salt Version:
Salt: 2019.2.1

Dependency Versions:
cffi: 1.11.5
cherrypy: unknown
dateutil: 2.6.1
docker-py: Not Installed
gitdb: 2.0.3
gitpython: 2.1.11
ioflo: Not Installed
Jinja2: 2.10.1
libgit2: Not Installed
libnacl: Not Installed
M2Crypto: 0.33.0
Mako: Not Installed
msgpack-pure: Not Installed
msgpack-python: 0.6.1
mysql-python: Not Installed
pycparser: 2.14
pycrypto: Not Installed
pycryptodome: Not Installed
pygit2: Not Installed
Python: 3.6.8 (default, Jul 1 2019, 16:43:04)
python-gnupg: Not Installed
PyYAML: 3.12
PyZMQ: 17.0.0
RAET: Not Installed
smmap: 2.0.3
timelib: Not Installed
Tornado: 4.5.2
ZMQ: 4.3.1

System Versions:
dist: centos 8.0.1905 Core
locale: UTF-8
machine: x86_64
release: 4.18.0-80.7.1.el8_0.x86_64
system: Linux
version: CentOS Linux 8.0.1905 Core

@cmcmarrow cmcmarrow added Bug broken, incorrect, or confusing behavior v2019.2.1 unsupported version labels Sep 27, 2019
@cmcmarrow
Copy link
Contributor

Debian 10 probably faces this issue as well.

@cmcmarrow cmcmarrow added this to the Approved milestone Sep 27, 2019
@rossengeorgiev
Copy link
Contributor

Network scripts are deprecated in Red Hat Enterprise Linux 8 and they are no longer provided by default. The basic installation provides a new version of the ifup and ifdown scripts which call the NetworkManager service through the nmcli tool. In Red Hat Enterprise Linux 8, to run the ifup and the ifdown scripts, NetworkManager must be running.

@q-b
Copy link

q-b commented Oct 4, 2019

@stale
Copy link

stale bot commented Jan 7, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue.

@stale stale bot added the stale label Jan 7, 2020
@rossengeorgiev
Copy link
Contributor

🤔

@stale
Copy link

stale bot commented Jan 8, 2020

Thank you for updating this issue. It is no longer marked as stale.

@stale stale bot removed the stale label Jan 8, 2020
@sagetherage sagetherage removed the v2019.2.1 unsupported version label May 22, 2020
@bryceml
Copy link
Contributor

bryceml commented Jun 9, 2020

See related: #55359

@rossengeorgiev
Copy link
Contributor

@oeuftete oeuftete added CS-R1 ZD The issue is related to a Zendesk customer support ticket. labels Aug 6, 2020
@oeuftete
Copy link
Contributor

oeuftete commented Aug 6, 2020

ZD-5548.

@sagetherage sagetherage added the Magnesium Mg release after Na prior to Al label Aug 6, 2020
@sagetherage sagetherage modified the milestones: Approved, Magnesium Aug 6, 2020
@sagetherage sagetherage assigned s0undt3ch and unassigned jshatch Aug 14, 2020
@sagetherage sagetherage added the P1 Priority 1 label May 18, 2021
@sagetherage sagetherage assigned s0undt3ch and unassigned dwoz May 18, 2021
@sagetherage sagetherage modified the milestones: Silicon, Approved Aug 9, 2021
@anilsil anilsil modified the milestones: Approved, Phosphorus v3005.0 Oct 20, 2021
@garethgreenaway garethgreenaway added Phosphorus v3005.0 Release code name and version and removed Silicon v3004.0 Release code name labels Oct 20, 2021
@garethgreenaway garethgreenaway added Sulfur v3006.0 release code name and version and removed Phosphorus v3005.0 Release code name and version labels Feb 2, 2022
@ocfmatt
Copy link

ocfmatt commented Feb 10, 2022

Hi, this issue is becoming a bit of an ongoing joke now. Network manager has been around for years and is the recommended way to manage networking on EL base Linux distributions. I can see a fully working network manager integration has been requested for years and this issue has even been given a P1 label in May 2021 and since then all the public activity on it has been pushing it further into the future with no rationale as to why such a fundamental server component has still not been implemented.

I have most of a network state working with network manager after finding a number of undocumented parameters in the Python code however, the final piece to this puzzle is how to trigger the reload. The obvious workaround to the state/module not doing the reload is to do the reload using cmd.run and have a onchanges requisite trigger this however, I try to use cmd.run as a last resort.

Can anyone give an update on what is happening with this and whether a working network manager integration is likely to be released any time soon?

Regards,
Matt.

@mastrong
Copy link
Collaborator

I made a PR to check for EL8 and call for a NetworkManager restart instead of network. It has been merged, but unknown when this will be released, of course. I currently have it in salt://_modules/rh_ip.py and sync it as a custom to override the default. #61658

@kees-closed
Copy link

I made a PR to check for EL8 and call for a NetworkManager restart instead of network. It has been merged, but unknown when this will be released, of course. I currently have it in salt://_modules/rh_ip.py and sync it as a custom to override the default. #61658

I've installed version 3005, the error is indeed gone. But Salt still uses network-scripts, which is deprecated since RHEL8: https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/8.5_release_notes/deprecated_functionality#deprecated-functionality_networking

So it's still not really a fix, adding routes on RHEL8 is still a challenge. For now I'll look for an ad-hoc command with nmcli to add routes. Not great, not terrible.

@rossengeorgiev
Copy link
Contributor

This issue also affects RHEL9, and RHEL derivatives such as AlmaLinux and Rocky Linux.

You could work around the unmaintained network.managed state module by using file.managed to generate the config files (network-scripts or nm profiles), which will work on 7/8/9. Then cmd.run to invoke nmcli to reload and activate networks.

@garethgreenaway garethgreenaway added Chlorine v3007.0 and removed Sulfur v3006.0 release code name and version labels Dec 8, 2022
@anilsil anilsil removed this from the Chlorine v3007.0 milestone May 11, 2023
@s0undt3ch s0undt3ch removed their assignment Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug broken, incorrect, or confusing behavior P1 Priority 1 severity-high 2nd top severity, seen by most users, causes major problems ZD The issue is related to a Zendesk customer support ticket.
Projects
None yet
Development

No branches or pull requests