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

Possible corruption when running update.sh from update_all.sh #66

Closed
starquake opened this issue Aug 31, 2021 · 4 comments
Closed

Possible corruption when running update.sh from update_all.sh #66

starquake opened this issue Aug 31, 2021 · 4 comments

Comments

@starquake
Copy link

I've seen claims on the MiSTer FPGA that this script can cause corruption if this script runs update.sh and the OS is updated. And that you have to check and run update.sh instead of update_all.sh if there is an update.

Example: https://misterfpga.org/viewtopic.php?p=32387#p32387

Is that true?

Does update_all write to paths that are contained in the mounted linux image?

Does update_all work in a way that the reboot is postponed and there could potentially be writes to that linux image?

@theypsilon
Copy link
Owner

theypsilon commented Aug 31, 2021

The short answer is no, it's most probably not true.

That being said, I understand your concern, cause I've heard people saying this in a number of places. To address this concern, I've just changed the script, and it now updates Linux at the very end, right before rebooting.

According to my understanding, the problem that some people rarely experience won't be solved by updating linux right before reboot as update_all does now, nor by running the official update script in isolation. In other words, was not a problem unique to previous versions of update_all, and the reason why previous update_all usage was actually fine, is because no services nor modules were being reloaded during the scripts that were running after a Linux update. They were just doing pretty light tasks such as copying files and such, which should be totally fine. Keep in mind that all the relevant parts of the system are kept alive in the RAM after an update. And the reboot was happening by default at the end of update_all anyways. The problem is more likely to be the result of corrupted files, maybe because corrupted downloads or because something went wrong in the physical layer. Time will tell.

@starquake
Copy link
Author

Amazing! Thanks a lot!

@durkada
Copy link

durkada commented Sep 8, 2021

Just as an FYI, I had this problem happen to me on September 1st. Finally gotten around to fixing it.

Not much of a fix -- simply had a secondary MiSTer I hadn't updated. Copied over the linux dir from the older and it would boot again.

Not much to see in the logs generated by the update script, and, of course, /var/log is in tmpfs... So, its going to be a mystery. If you do care, I can 7z the old (broken) linux dir if you are curious.

@durkada
Copy link

durkada commented Sep 8, 2021

Ran the updater and it broke again. One thing I noticed is that it downloaded and extracted the release_20210906.7z twice.

Once near the beginning and again as the final act.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants