How to configure the network in CentOS 8

 < Configure firewall and SELinux | Enable and disable services >

To begin with, set a hostname. If you didn't set a hostname during installation you can do it like this. If you already did it you can skip this step.

To get a list of devices on your machine you can use.

To set the IPv4 address of i.e., you can do it like this:

To set the gateway:

To set the DNS:

You can set manual for static setting (or "auto" for DHCP)

Next restart the interface to apply the settings.

You can verify the settings like this:

You can also use  to see the state of.

 < Configure firewall and SELinux | Enable and disable services >