Setting Static IP
|
nmcli con mod connection_name ipv4.addresses 192.168.0.123/24 nmcli con mod connection_name ipv4.gateway 192.168.0.1/24 nmcli con mod connection_name ipv4.dns "8.8.8.8" nmcli con mod connection_name ipv4.method manual nmcli con up connection_name |
Settting to use DHCP
|
nmcli con mod connection_name ipv4.method auto nmcli con up connection_name |
Configuration file location
|
/etc/NetworkManager/system-connections/<em>connection_name</em> |
Wifi
|
# displays a table of available wifi access points. nmcli dev wifi sudo nmcli dev wifi connect my_ssid # with password sudo nmcli dev wifi connect my_ssid password "my_password" # prompt for password sudo nmcli --ask dev wifi connect my_ssid # add wifi connections sudo nmcli con add con-name HOMEOFFICE ifname wlan0 type wifi ssid my_ssid |
References: