Centos 7 the journey form NetworkManager to self managed network configuration files

Long time ago that i wrote something. I think it’s time to start with a small one…

While I create a manual installation for Centos 7, i was borrowed by follow message after
disabled the NetworkManager:
(systemctl stop NetworkManager; systemctl disable NetworkManager; systemctl mask NetworkManager)

systemctl restart network … BOOOM (-;

network.service – LSB: Bring up/down networking
Loaded: loaded (/etc/rc.d/init.d/network; bad; vendor preset: disabled)
Active: failed (Result: exit-code) since Di 2017-03-07 19:01:15 CET; 7s ago
Docs: man:systemd-sysv-generator(8)
Process: 3469 ExecStart=/etc/rc.d/init.d/network start (code=exited, status=6)

I wasn’t that stupid, created the file with nmtui. In fact: No mistakes! But the failure
came around from ipv6, what i disabled in the configuration.

Search for a file like “/etc/sysconfig/network”. “touch” it or create empty one.

echo “# Created by anaconda” > /etc/sysconfig/network

your done. Now “systemctl start/stop/restart network “work and the adapter is up on boot.

There is one little thing about loopback device, which is not present NetworkManager:

“ip r”

default via 172.16.200.1 dev enp2s0
169.254.0.0/16 dev enp2s0 scope link metric 1002
172.16.200.0/24 dev enp2s0 proto kernel scope link src 172.16.200

After read up some forums who tell you “Prevent the kernel from load ipv6”. In Centos 7 the ipv6 module is builtin. 🙂
By the way the backloop ip is ipv 4.

After I add to the ifcfg- configuration file:

NOZEROCONF=yes

Everything looks clean.

“ip r”
default via 172.16.200.1 dev enp2s0
172.16.200.0/24 dev enp2s0 proto kernel scope link src 172.16.200.10

We can still mix ipv4 and ipv6 with another card.

Now everything works like it should;- how simple it can be……

PS: You really know what you install when you “click” inside a gui? 🙂 Me not.

Leave a Reply

Your email address will not be published. Required fields are marked *