Group,
I am back. When I tested it last time a couple weeks ago, it worked.
When I tested it again yesterday, it failed. I do not know what
happened, so I 'started over' to see if I can pinpoint what needs to
happen to get connman to reconnect when a wifi SSID is restarted. I
am running a Raspberry Pi3b+ with Arch Linux with its onboard brcmfmac
adapter. I have a connman git compiled version 1.38.r79.g69e9e250 and
iwd r5193.a8768e3 which is later than 1.11 and has specific fixes for
the brcmfmac. I have tried later brcmfmac firmware and a later driver
with the same result so I have reverted and am using the driver and
firmware that ships with arch linux.
I wiped all configs from /var/lib/connman and iwd and restarted as a test.
My main.conf for connman has only 3 edits from the blank one provided
in the package:
PreferredTechnologies = ethernet,wifi
AllowHostnameUpdates = false
AlwaysConnectedTechnologies = ethernet,wifi
My iwd main.conf is:
[General]
UseDefaultInterface=true
We create a *.config file and restart the device to configure the
wireless. The config file we create has these lines:
[global]
Description=DHCP PSK Wi-Fi network configuration for network (SSID)
"spg3", with SSID hex value "73706733"
[service_73706733]
Type=wifi
SSID=73706733
Security=psk
Passphrase=password
Hidden=false
When it reboots, if we check the connman service, it looks like this:
# connmanctl services wifi_b827eb52ccd0_73706733_managed_psk
/net/connman/service/wifi_b827eb52ccd0_73706733_managed_psk
Type = wifi
Security = [ psk ]
State = online
Strength = 48
Favorite = True
Immutable = True
AutoConnect = True
Name = spg3
Ethernet = [ Method=auto, Interface=wlan0,
Address=B8:27:EB:52:CC:D0, MTU=1500 ]
IPv4 = [ Method=dhcp, Address=192.168.2.41, Netmask=255.255.255.0,
Gateway=192.168.2.1 ]
IPv4.Configuration = [ Method=dhcp ]
IPv6 = [ Method=auto, Address=fd21:98c8:1d28:0:ba27:ebff:fe52:ccd0,
PrefixLength=64, Privacy=disabled ]
IPv6.Configuration = [ Method=auto, Address=fd21:98c8:1d28::41,
PrefixLength=64, Privacy=disabled ]
Nameservers = [ 2600:1700:4320:6caf:ba27:ebff:fe0b:9be6,
192.168.2.3, 2600:1700:4320:6caf:ba27:ebff:fe0b:9be6 ]
Nameservers.Configuration = [ ]
Timeservers = [ ]
Timeservers.Configuration = [ ]
Domains = [ lan ]
Domains.Configuration = [ ]
Proxy = [ Method=direct ]
Proxy.Configuration = [ ]
mDNS = False
mDNS.Configuration = False
Provider = [ ]
but the iwctl shows this:
# iwctl known-networks spg3 show
Known Network: spg3
--------------------------------------------------------------------------------
Settable Property Value
--------------------------------------------------------------------------------
Name spg3
Hidden
* AutoConnect no
I cannot change this through the iwctl interface:
# iwctl known-networks spg3 set-property AutoConnect true
# iwctl known-networks spg3 show
Known Network: spg3
--------------------------------------------------------------------------------
Settable Property Value
--------------------------------------------------------------------------------
Name spg3
Hidden
* AutoConnect no
If I force a disconnect by rebooting, restarting the radio or
disconnecting from the router UI, the same thing happens as before.
The disconnection happens and no scanning occurs and it will never
reconnect.
The journal shows the deletion of the interface addresses and
iwd-monitor or connman-monitor shows no activity. I restart iwd, and
it immediately reconnects. If I check the iwctl now, it shows
"AutoConnect yes", so it appears it gets fixed when iwd was restarted:
# iwctl known-networks spg3 show
Known Network: spg3
--------------------------------------------------------------------------------
Settable Property Value
--------------------------------------------------------------------------------
Name spg3
Hidden
* AutoConnect yes
If I try this again, by restarting the radio on the router, I get the
same response in the journal. no scanning ever occurs. if I look at
monitor-iwd, monitor-connman or the journalctl no scanning happens.
I have verified that iwd works fine in standalone mode (internal dhcp)
or with dhcpcd. If I perform the same test, it reconnects in < 2
minutes every time. Also in the log it shows that iwd starts scanning
very soon after it is disconnected and finds the SSID and reconnects
(like all my other wifi devices). I really want connman to work for
this project and especially now that tethering works with the brcmfmac
driver. What can I do to log or help to figure out what is going on?
Keith
Show replies by date
On Mon, Feb 08, 2021 at 07:15:30PM -0600, KeithG wrote:
I have verified that iwd works fine in standalone mode (internal
dhcp)
or with dhcpcd. If I perform the same test, it reconnects in < 2
minutes every time. Also in the log it shows that iwd starts scanning
very soon after it is disconnected and finds the SSID and reconnects
(like all my other wifi devices). I really want connman to work for
this project and especially now that tethering works with the brcmfmac
driver. What can I do to log or help to figure out what is going on?
See my 'Teach autoconnect algorithm native mode' patches. Currently,
ConnMan doesn't disable it's own connect algorithm when iwd's
autoconnect is enabled. They need some more testing/debugging as they
don't work correctly yet.