Linux 101 : Systemctl, nmcli and Network services

Displaying the network "systemctl" units:

To find the networking related targets and services on the system using:


The "-i" option in the grep command is used to ignore the uppercase, so "n" will be the same as "N"

Targets : are the equivalent of the "SysVinit" runlevels.

Networking-related operations:

We can restart the network components using:

We can check if the Networking is enabled (starts at boot time) using:

Network interface-related operations:

To disconnect an interface, we use the below command:

To reconnect an interface, we use the below:

To show all the devices on the system, we use:

To show the state of all the interfaces:

To show all the connections on a system:

Creating a connection:

To create an Ethernet connection named "connection_1" assigned to the network interface "eth0", we use:

To check if it was created, we display all the connections:

We can assign an IP addresses to our connection, using the below:

We replace "ip_addr" with the IP address relevant to our network. 
After assigning the IP address to our connection, we would need to restart the connection to apply the changes to it, by deactivating and reactivating it as below.

Bringing down a network interface:

Bringing up a network interface:


Leave as a comment: