How to Start/Stop/Restart Network Service on CentOS 8 or RHEL 8

This post will guide you how to start or restart network service on the latest CentOS 8 or RHEL 8 Linux. How do I start, stop or restart network service in Red Hat Enterprise Linux 8.

redhat 8 logo

In CentOS 8 or RHEL 8 Linux, you can not find network service scripts or there is no /etc/init.d/network or systemd network service. So you can not use systemctl start network.service to start network service or using /etc/init.d/network script to start or restart networking service. How to restart network in RHEL 8 Linux. You can use the following two methods to start or restart network service in RHEL 8 or CentOS 8.

Method1: Using NetworkManager


To start network service in RHEL 8 or CentOS 8, type the following command:

$ sudo systemctl start NetworkManager.service

To stop network service in RHEL 8 or CentOS 8, type the following command:

$ sudo systemctl stop NetworkManager.service

To restart network service on your RHEL 8 or CentOS 8, type:

$ sudo systemctl restart NetworkManager.service

Method2: Using nmcli Tool


You can also use nmcli tool to configure network interface in RHEL 8 or CentOS 8. and Nmcli is a NetworkManager command line interface. You can use this tool to configure a static IP address for a network interface or restart network service. type:

$ nmcli networking off
$ nmcli networking on

Note: the off will disable all NetworkManager managerd network connections. and the on will start all connections.

From the RHEL 8 release notes:

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.

 

You might also like:

Sidebar



back to top