LinkedIn Sourceforge Twitter

Vincent's Blog

Pleasure in the job puts perfection in the work (Aristote)

Network manager control for OpenBSD - nmctl-0.6.1

Posted on 2018-10-08 18:36:00 from Vincent in Open Bsd nmctl

This release of nmctl brings few new features and some bug fixes.

I detail the changes in this blog


Changes

This minor release fix following issues:

  • In some cases, the command dmesg does not return enough informations. This occurs if you have lot of messages generated by the kernel. In such case, the informations that nmctl needs to deduce the interfaces available on your system are no more presented by the command dmesg. To avoid such situation, nmctl now read the file /var/run/dmesg.boot. In the different cases I had, doing so always allow nmctl to find interfaces messages. Let's see if this is the case in all situations.

  • Linked to the issue caued by dmesg, now nmctl exit if it's not possible to deduce the available interfaces

  • In the case you use the --restart parameter, now nmctl perform first a ping. If the ping succeed, nmctl exit silently.

In such case, the debug log looks like this:

Mon Oct  8 18:28:20 2018: execute "/usr/bin/doas /bin/cat /var/run/dmesg.boot": stdout lenght= 98247
Mon Oct  8 18:28:20 2018: Interfaces are: 
Mon Oct  8 18:28:20 2018:   em0, type:cable, status:no carrier
Mon Oct  8 18:28:20 2018:   iwm0, type:wifi, status:active
Mon Oct  8 18:28:22 2018: execute "ping -c3 -w5 8.8.8.8" : rc=0
Mon Oct  8 18:28:22 2018: Ping successful. No need to configure interfaces

Clarifications

It was not clearly mentioned, but nmctl mentions which config is currently in use by documenting it in the "ifconfig groups".

This does not affect the groups already documented for this interface.

To identify them easily the naming's convention is to always use the config's name appended with "_NM".

As example, here under, we can see that I'm connected via the config called homewifi.

iwm0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        lladdr 10:02:b5:83:40:41
        index 2 priority 4 llprio 3
        groups: wlan homewifi_NM egress
        media: IEEE802.11 autoselect (HT-MCS1 mode 11n)
        status: active
        ieee80211: nwid Linksys19594 chan 12 bssid c8:d7:19:4c:76:73 77% wpakey wpaprotos

Download

Code is present in Sourceforge: here
And release of nmctl-0.6.1 is here



1, 0
displayed: 394



How much does 1 plus 2 ?