The general subcommand of nmcli (NetworkManager Command Line Interface) is used for managing the general settings of NetworkManager. This subcommand provides various options for configuring NetworkManager, including changing the status of NetworkManager, enabling/disabling automatic connections, and managing NetworkManager’s global DNS configuration.
The nmcli g shorthand can be used instead of nmcli general for convenience.
nmcli general Command Examples
1. Show the general status of NetworkManager:
# nmcli general
2. Show the hostname of the current device:
# nmcli general hostname
3. Change the hostname of the current device:
# sudo nmcli general hostname {{new_hostname}}
4. Show the permissions of NetworkManager:
# nmcli general permissions
5. Show the current logging level and domains:
# nmcli general logging
6. Set the logging level and/or domains (see man NetworkManager.conf for all available domains):
# nmcli general logging level {{INFO|OFF|ERR|WARN|DEBUG|TRACE}}domain {{domain_1,domain_2,...}}