This document is a WORK IN PROGRESS.
This is just a quick personal cheat sheet: treat its contents with caution!
ConnMan is a CLI network manager designed for use with embedded devices and fast resolve times. It is modular through a plugin architecture, but has native DHCP and NTP support.
Table of contents¶
pure CLI interfaces definition (e.g.
Very useful optional dependencies to install:
The previous installation step allow to control
connmanctl, but you might want a
user interface and not just a
connman-gtk(GTK client for
cmst(Qt GUI for
ConnMan-UI(GTK 3 client applet for
LXQt-Connman-Applet(LXQt desktop panel applet for
gnome-extension-connman(Gnome 3 extension for
connman to your init manager:
Depending on your
runit implementation, either run:
If you want to prefer Ethernet over wireless:
If you don't want to allow to be connected to both Ethernet and wireless at the same time (in order to have only a single unambiguous connection active at a time):
If you don't want to let
connmanchange the transient host name on a per network basis (which can cause problems with X authority):
If something like Docker is creating virtual interfaces,
connmanmay attempt to connect to one of these instead of your physical adapter if the connection drops. A simple way of avoiding this is to blacklist the interfaces you do not want to use.
connmanwill by default blacklist interfaces starting with
ifb, so those need to be included in the new blacklist as well. Blacklisting interface names is also useful to avoid a race condition where
udevcan change it to use a Predictable Network Interface Names like
enp4s0. Blacklisting the conventional (and unpredictable) interface prefixes makes
connmanwait until they are renamed.
- Shows a list of all technology types existing on the system (e.g.
bluetooth...) , their properties and their status:
wifi, note that it powers on to the WiFi, but doesn't connect unless there is a service with auto connect set to True:
Connect to a non password protected WiFi access point:
Connect to a password protected WiFi access point:
After the first connection, a
wifiservice is saved in
/var/lib/connamn/wifi_*. It's settings can be modified, e.g. the auto connection setting:
Note that some WiFi connection points may need additional steps, like for
Ethernet connections are setup automatically. After the first connection, an
ethernetservice is saved in
/var/lib/connamn/ethernet_*. It's settings can be modified, e.g. the auto connection setting:
ethernetinterfaces are needed with a single
ethernetmac address (typically depending on the network you want to connect to). This can be achieved like so:Change the settings of those network interfaces the way you want:Select one of those interfaces with a symbolic link:
dmenufor Ethernet interfaces
dmenufor WiFi selection
- see https://github.com/march-linux/connman_dmenu
If this cheat sheet has been useful to you, then please consider leaving a star here.