-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Support FS update in two steps #6505
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
Conversation
where or when is |
@d-a-v It's an independent effort. I'm using |
Can you elaborate on how this is supposed to be used when |
The FS is presently updated right in Updater.cpp during the upload, and can end up in an inconsistent state should there be a dropout or other problem during update. It's not like the app where the new copy is only uploaded if the entire upload and MD5 match. What this looks to do is treat the FS the same way as the program, and upload to spare area and only ask the bootloader to overwrite it iff the upload is a success. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This makes sense to me. Need to leave it as optional since in most cases you don't have enough unused space to do this 2-step process.
I understand |
I renamed the flag and left a note in the docs as suggested. |
Problem: I am updating my sketch and FS over HTTPS and keep the certificates in FS like in the httpUpdateSecure.ino example. If updating the FS fails (e.g. power failure during download) and the certificates get damaged, my customers might not be able to update and recover anymore.
Solution: Support the same two step process that is used to update the sketch.
A step towards #905. Hopefully the option to move from RTC to flash will be merged soon also.