How do i manage the network in redhat 7?
-
There are a multitude of commands to manage the network in redhat 7. Some commands are not install on minimal installations by default, like some that you have been use to ifconfig and netstat.
ifconfig, nmcli, nmtui, ip, and control-center
NetworkManager - The default networking daemon
nmtui - A simple curses-based text user interface (TUI) for NetworkManager
nmcli - A command-line tool provided to allow users and scripts to interact with NetworkManager
control-center - A graphical user interface tool provided by the GNOME Shell
ip - ip is normally used instead of ifconfignmcli is a front-end for NetworkManager, on enterprise servers NetworkManager daemon has normally been turned off and interfaces managed via ip or ifconfig command. There is however a progression toward using nmcli and ip combo.
nmcli has the following sub-commands
g[eneral] NetworkManager's general status and operations
n[etworking] overall networking control
r[adio] NetworkManager radio switches
c[onnection] NetworkManager's connections
d[evice] devices managed by NetworkManager
a[gent] NetworkManager secret agent or polkit agentYou can use the first letter of each and see the usage of each using the help option.
$ nmcli g -help Usage: nmcli general { COMMAND | help } COMMAND := { status | hostname | permissions | logging } status hostname [<hostname>] permissions logging [level <log level>] [domains <log domains>]
nmtui is a curses menu to manage the network interfaces.
As normal transition to new commands is slow, unless you started with the new commands.
ifconfig is still around but the equivalent in ip is:
$ ip -s link
See articles on how to configure the network
© Lightnetics 2024