davesteele / comitup

Bootstrap Wifi support over Wifi
https://davesteele.github.io/comitup/
GNU General Public License v2.0
320 stars 54 forks source link

Erratic connection after pairing to a second wifi network #172

Closed breboulet closed 3 years ago

breboulet commented 3 years ago

Hi Dave,

Here are the steps to reproduce the weird behavior I ran into:

I couldn't pin down what the issue was, nor find any relevant logs, but something fishy is going on with the network after that second pairing. CPU usage seems normal. That's a tricky one...

Hopefully you'll be able to reproduce the issue and understand what's going on a little better than myself!!

And thanks again for that wonderful project ;)

Best, Bastien

davesteele commented 3 years ago

See CONTRIBUTING for logging and reporting notes.

breboulet commented 3 years ago

Hi Dave,

Here's my test environment:

Steps to reproduce:

Note that individually (not in sequence, from scratch) connecting to WifiNetwork1 or WifiNetwork2 works without any issue.

Here are all the log files I collected while running the above steps: comitup.log comitup-web.log daemon.log syslog.txt

Hope this helps.

Best, Bastien

davesteele commented 3 years ago

The daemon log indicates it is a known problem in recent versions. Upgrade or install 1.22-1.

breboulet commented 3 years ago

I confirm the problem is resolved with 1.22-1 Thank you so much! Best, Bastien

breboulet commented 3 years ago

Hi Dave,

For some weird unknown reason the problem is back there, after reboots it connects to wifi, but shorty after connection becomes unstable until it drops completely. Using comitup-1.22-1.

See the new logs attached: syslog.txt comitup.log comitup-web.log daemon.log

breboulet commented 3 years ago

Here are more logs hat I gathered after letting the Pi run for a while. I thought they might be helpful. If you need anything else, please let me know ;) syslog.txt daemon.log comitup-web.log comitup.log

breboulet commented 3 years ago

Hi Dave,

Unfortunately I think the issue is back with comitup 1.25-1. Note: I have the following comitup.conf set: enable_appliance_mode: false

I also noticed that, even when the connection works, the Pi has always 2 different IP addresses on the wlan0 interface, is that normal? (seen across multiple versions of comitup)

Best, Bastien

See logs attached: comitup.log comitup-web.log daemon.log syslog.txt

breboulet commented 3 years ago

The double IP problem seems to be caused by dhcpcd.service If I mask it, I then see a single IP address after reboot. Unmask it and double IP is back.

davesteele commented 3 years ago

The comitup image has dnsmasq.service, systemd-resolved.service, and dhcpd.service masked.

breboulet commented 3 years ago

It does have dhcpd.service masked, but it doesn’t have dhcpCd.service masked.

davesteele commented 3 years ago

Concerning the double IP, I'm guessing you have a dhcp service connected to the hotspot? That could cause problems regardless of Comitup's behavior.

davesteele commented 3 years ago

V1.27-1 is in the archive, but not the repo (yet).

breboulet commented 3 years ago

Thanks Dave, I’ll give it a try when released in the repo and let you know ;)

breboulet commented 3 years ago

I generated a new image with 1.28-1 and even though comitup-cli states it's in HOTSPOT mode and lists the nearby wifis, the actual hotspot does not show up on my iPhone's wifi network list.

davesteele commented 3 years ago

1.29-1 released.

breboulet commented 3 years ago

It works!!