How to restart network service on CentOS8?
-
- Posts: 2
- Joined: 2019/09/25 07:52:56
How to restart network service on CentOS8?
Hello,
How to restart network service on CentOS8?
I ran 'systemctl restart network.serivce' got following result:
Unit network.service could not be found.
Any one please help ?
How to restart network service on CentOS8?
I ran 'systemctl restart network.serivce' got following result:
Unit network.service could not be found.
Any one please help ?
Last edited by ironblood4416 on 2019/09/26 00:25:26, edited 1 time in total.
-
- Posts: 1521
- Joined: 2014/05/21 20:16:00
- Location: Central New York, USA
Re: How to restart network service on CentOS8?
I think I rememberer reading some time ago that NetworkManager was the only option in 8. Don't quote me, but ...
Re: How to restart network service on CentOS8?
It appears that the complete abandonment of the network service in el8 was rethought and it's still there as an optional install (which produces deprecation messages in the logs every time it's used unless you turn it off). Try network-scripts or network-tools packages.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
-
- Posts: 2
- Joined: 2019/09/25 07:52:56
Re: How to restart network service on CentOS8?
This means 'NM_CONTROLLED=no' is no longer needed in ifcfg-ens3?lightman47 wrote: ↑2019/09/25 20:19:49I think I rememberer reading some time ago that NetworkManager was the only option in 8. Don't quote me, but ...
Re: How to restart network service on CentOS8?
There was never a need, but in some special scenarios you had to.
The original purpose of the variable was to tell NetworkManager:
"Thou shall not touch this connection!"
Think what happens IF the NM respects the 'no' even if there is nobody else to handle the connection?
Why are you looking at (or worse yet editing) ifcfg-ens3? NetworkManager does not wan't you to do that.
NM is kind and helpful (like fire).
NM offers nmcli, nmtui, clickety-clack GUI crap and whatnot that will do all the edits for you into files that you are not supposed to ever see.
NM does not support the "hands on files" philosophy. NM believes that humans make a mess.
Old school admins know that NM will mess up, somewhere, somehow.
The original purpose of the variable was to tell NetworkManager:
"Thou shall not touch this connection!"
Think what happens IF the NM respects the 'no' even if there is nobody else to handle the connection?
Why are you looking at (or worse yet editing) ifcfg-ens3? NetworkManager does not wan't you to do that.
NM is kind and helpful (like fire).
NM offers nmcli, nmtui, clickety-clack GUI crap and whatnot that will do all the edits for you into files that you are not supposed to ever see.
NM does not support the "hands on files" philosophy. NM believes that humans make a mess.
Old school admins know that NM will mess up, somewhere, somehow.
-
- Posts: 10
- Joined: 2019/02/27 13:44:30
Re: How to restart network service on CentOS8?
I´m using currently the simple "ifup" and "ifdown", because i only have one if ("/etc/sysconfig/network-scripts/ifcfg-ens192")
so...
As someone said before, you could do
or do it directly with the NetworkManager:
so...
Code: Select all
ifdown ens192 && ifup ens192
Code: Select all
systemctl restart NetworkManager.service
Code: Select all
nmcli networking off && nmcli networking on
Re: How to restart network service on CentOS8?
Code: Select all
nmcli c down ens192 && nmcli c up ens192
Re: How to restart network service on CentOS8?
The following command can reload the new settings.
Code: Select all
nmcli d reapply enp03
Re: How to restart network service on CentOS8?
Out of curiosity do you have to do this because your machine is not connected upon boot up?