Get network parameters NetworkManager CLI

The “nmcli” CLI program gives access to current network parameters. For example, to get current DNS server:

nmcli dev show | grep DNS

This returns something like:

IP6.DNS[1]:                2606:4700:4700::1111

NMCLI output is made for machine parsing. An example of nmcli Python parsing is our “MozLoc” program that allows locating via nearby WiFi APs alone, using Mozilla Location Service.