Thank you for balena-os / wifi-connect. It’s exactly what I’m looking for. I may have made a mistake in initial configuration. I installed balena-os / wifi-connect in the shell via SSH over a WiFi connection following you instructions to do…
I saw no errors until it got to the following:
Fetched 6,316 kB in 6s (984 kB/s)
Download complete and in download only mode
WiFi Connect Raspbian Installer: Deactivating and disabling dhcpcd…
client_loop: send disconnect: Broken pipe
That last line was me being kicked out of the SSH connection, which makes sense because the Pi was being reconfigured by your software. But now I realize that I don’t know what state it leaves the machine in when your install is complete. I cannot SSH to that IP anymore. I’m sure I can connect a keyboard and mouse to it and get a shell (at least I hope so) but your documentation doesn’t really tell me how I “finish” the configuration so that if the device cannot connect on startup (or whatever) it will create that Access Point. Right now, after restarting the Pi and all, there’s no “WiFi Connect” networking showing on my other devices.
Your help in analyzing what to do next, much appreciated!
As you mentioned your Pi should be on Access Point mode unless it’s connected via Ethernet or similar. Did you check there are not new WiFis with the name WiFi Connect Raspbian Installer or similar?
mpous - Thanks for the email. When the installation got to the point I showed in my post, I was disconnected from it for my SSH over WiFi. I tried rebooting it and then looked for anything that looked like “WiFi Connect…” and nothing was there. If I can connect to it directly (keyboard and HDMI display into a shell), is there something I can check to see what’s happening? A status or a log or something?
@alexmaghen Looking at the Raspbian installation script for wifi-connect and the logs that you received, it appears that your session on the device was disconnected with dhcp was turned off and it may not have finished fully disabling dhcp and upon a reboot it would have been re-activated with systemd. If you can directly connect to the device, you should make sure that dhcp is fully disabled with sudo systemctl stop dhcpcd && sudo systemctl disable dhcpcd Also, ensure that the NetworkManager is enabled and running as well (sudo systemctl enable NetworkManager && sudo systemctl start NetworkManager).
Lastly, after you have ensured that those two things have happened, you should verify that wifi-connect was correctly installed. This can be checked with which wifi-connect to guarantee that the binary is present in your PATH and furthermore you should be able to run wifi-connect --help to get some options for running the application.
Let us know if you run into any issues with any of these commands and whether or not wifi-connect was correctly installed, and we can continue helping to debug moving forward. I have not installed wifi-connect directly to Raspbian before, so I’m not sure if the installation script sets up a systemd service or cron job to automatically run wifi-connect when there isn’t a network connection.
Dear @mehalter - Thanks for this. I connected directly to keyboard/monitor and did a clean install of your package from there. It completed the install with no complaints. I then followed your instructions to make sure dhcp is disables and NetworkManager enabled. Those commands gave no complaints either.
Next, I rebooted the pi. When the reboot was complete, I could not access the network (e.g. “ping xyz.com”). And I could not find anything like a “WiFi Connect” SSID on any of my other devices.
I also tried changing /boot/wpa_supplicant.conf file so that it intentionally broke the wifi network the pi usually connects to and rebooted again. And again, same problem.
I’m sorry to be a pain in the ass here but your help diagnosing this would go a long way. Are there wifi-connect logs I can look at or share with you?
This project is for a non-profit and I can only contribute so much of my time to it but this will be incredibly helpful if I can get it to work.
as my colleague suggested - the raspbian-install.sh script will only install wifi-connect on your device, you then need to start it yourself by e.g. simply running wifi-connect from the terminal. At this moment we unfortunately do not provide startup automation for raspbian. You can find a more advanced startup example (running conditionally only if no internet connection is available) in the https://github.com/balena-os/wifi-connect/blob/master/scripts/start.sh script.