Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto update #6166

Closed
symbios24 opened this issue Feb 15, 2023 · 6 comments
Closed

Auto update #6166

symbios24 opened this issue Feb 15, 2023 · 6 comments
Labels
Enhancement 💨 Solution available 🥂 Definite solution has been done
Milestone

Comments

@symbios24
Copy link

symbios24 commented Feb 15, 2023

Hello there.
Not really a bug

Im using latest dietpi bullseye on a Raspberry Pi zero in hotspot mode

Im connected with ssh in my Raspberry Pi zero when i run dietpi-update im disconnected and cannot connect anymore,the thing is,its probably necessary to answer yes to some prompts thats why i never get back to the ssh connection

Is it possible to add a command on a next update to answer yes automatically in all prompts(except the backup)

Example: dietpi-update -y

Or just a setting to activate auto update in dietpi-config with the option to disable/answer no to backup option

Thank you

@MichaIng
Copy link
Owner

MichaIng commented Feb 15, 2023

You can enable automatic APT package upgrades (see dietpi.txt) but you cannot enable automatic DietPi updates intentionally. We sometimes want to inform you about important changes and give you choices whether you want to apply something, reinstall a software title for an update or something like that. Since this can involve breaking changes, we do not want this to happen without interactive recognition and we also do not want to skip it without you being informed about the possible (reasonable) change or update.

Im connected with ssh in my Raspberry Pi zero when i run dietpi-update im disconnected and cannot connect anymore

Let's focus on that part. So you are connected via WiFi hotspot to the RPi. And as hostapd is stopped during updates, installs etc, this breaks the connection. That is bad indeed. It actually makes sense to not start/stop those services, like we do for SSH/VPN/VNC servers which you could be connected through to the DietPi system.

@MichaIng MichaIng added this to the v8.15 milestone Feb 15, 2023
@symbios24
Copy link
Author

The thing is if i leave it, it never finishes the update.probably i have to answer yes to some prompt that i cannot since im disconnected (wifi dropped) i dont mind for the apt packages but for the dietpi updates

@Joulinar
Copy link
Collaborator

Usually the SSH session should not terminate at all. This is the current challenge because we stop the hotspot service during update. Something we need to change from our side. As workaround you could exclude hotspot service from being DietPi controlled. This should keep the hotspot active during update process

@symbios24
Copy link
Author

How can i do that?

@MichaIng
Copy link
Owner

Usually the SSH session should not terminate at all.

I was just thinking the same, and whether it is hence possible to control SSH servers without downside. But SSH connections can also break and leaving the possibility to always reconnect is mandatory.

How can i do that?

In dietpi-services select hostapd and then change from "DietPi controlled" to "systemd controlled" and exclude it. To be failsafe, to the same for isc-dhcp-server so a DHCP lease can be renewed in case it times out during updates/installs.

@MichaIng MichaIng added the Solution available 🥂 Definite solution has been done label Feb 19, 2023
MichaIng added a commit that referenced this issue Feb 19, 2023
- DietPi-Software | WiFi Hotspot: hostapd and the DHCP server are not stopped and restarted on DietPi updates, software installs and backups anymore, since the hotspot might be used by the client which does this task and then cuts its own connection. Many thanks to @symbios24 for making us aware of this: #6166
@MichaIng
Copy link
Owner

Done with: c259660

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement 💨 Solution available 🥂 Definite solution has been done
Projects
None yet
Development

No branches or pull requests

3 participants