WiFi config not saved

Greetings all, I can’t seem to get my WiFi configuration to remain across reboots. First off, I know that I’m a complete heretic for the temerity of using WiFi, but until I can pull cable, it is what it is.

Now, I configure the wifi via the console and it works fine until a reboot, then it’s gone. Suggestions? Thanks, Tim

Is the router you are connecting to configured to allocate you a Static IP Address instead of DHCP? Same for the HomeAssistant server?
The D in DHCP stands for Dynamic, ie changing, hence most likely the cause of your problem. Lock it in, and you should find consistent connection may also improve connection (not connectivity, but device connection) speed as it doesn’t have to hunt around, try searching, and possibly failing.

Thanks, my router is set for DHCP. I’m not talking about that, as a lot of routers will re-assign the same IP address to the same MAC (as I’m sure you know). I’m talking about saving the SSID and PSK. I set them via the HA CLI and everything works but the manual config doesn’t survive a reboot.

Is there a reason you’re not doing it via the UI?

I can definitely confirm it will survive across reboots (as well as store multiple credentials), as that’s how I have my HA in the travel trailer setup for connecting to my house.

Well, after a reboot, I can only access the console directly connected. I setup the WiFi via the CLI and then I can reach HA via the UI. I’ve also tried resetting up the SSID and PSK via the UI once I can talk to it, but it doesn’t survive a reboot either. Hence my post.

What commands do you use to do that?

Exactly what device are you trying to set WiFi up on? There are a lot of different variations of HA.

If your settings are not surviving a reboot, then clearly the data is not being stored correctly. Please list the exact CLI commands are you using to “set up” your WiFi.

It’s a mini-PC (x86). I run from the HA console while connected directly to the box:

network update wlp2s0 --wifi-auth wpa-psk --wifi-ssid SSID --wifi-psk PSK --ipv4-method auto

That brings up the card and it gets assigned an IP address via DHCP. That allows me to access the UI and I re-setup WiFi using the UI. None of it survives a reboot.

Any thoughts, it’s rather annoying.

Are you storing to a RAM drive? Are your parameters correct? Are you actually storing the values? What volume and device? What container? Can you verify that by displaying again before reboot? What are the values after boot but before you issue your cli commands? Can you schedule your cli command as part of the startup process? Do you need to login or use sudo? What file permissions are set? What documentation are you following? Is it relevant for your specific setup?
You havent given us enough information. What OS are you running? What version of network manager? What network adapter? What console?

Good luck with persisting with DHCP. It should work, but you may have extra steps to eliminate in your troubleshooting process, and closely following the documentation from the vendor.

Thanks, @iot7712, appreciate it. I’m happy to change to a static ip, so I’ll try that. As for the rest of the questions, I’m running HA, by itself, on the aforementioned x86 mini-PC, using the generic ISO (here). No containers, no RAM drives. The console I am referring to is the actual HA console that is displayed when you plug a keyboard and monitor into the mini-PC, so it’s running under the GUI.