photonvision
photonvision copied to clipboard
Make coprocessor SD card readonly and disable logging
Add a control in the GUI to make the SD card writeable when you configure, then set it back to non writeable when done. This will prevent SD card corruption on power loss. WPILIB pi image currently has this feature.
This is tricky because our logging is crucial to helping people troubleshoot issues. Losing persistent logs is a heavy cost when we've had no reports of filesystem corruption for a good while.
Is there a burning platform or way to reproduce the issue seen? We've had good luck so far with only occasionally losing logs, but never with image corruption on power off that I am aware of.
Could use a usb drive to write logs to?
Possibly. I think this is a larger tear up, and a fairly unique requirement that needs care to ensure we don't reduce usability to end users.
I only opened this issue because of a an imagined potential for the write while shut down causing a corruption. If this issue isn't being experienced then we don't need to keep it open. Maybe just as a thought.
On Thu, Nov 3, 2022, 3:09 PM Chris Gerth @.***> wrote:
Possibly. I think this is a larger tear up, and a fairly unique requirement that needs care to ensure we don't reduce usability to end users.
— Reply to this email directly, view it on GitHub https://github.com/PhotonVision/photonvision/issues/484#issuecomment-1302611484, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALMSQWMTSUE7FZKFMSKMN6LWGQLYTANCNFSM6AAAAAAQ5WYZFQ . You are receiving this because you authored the thread.Message ID: @.***>
Sweet ok. Churning it over, having an option to automatically pump to an attached usb drive and attempt to keep the main sd card read only could be doable. Probably a "next summer" thing.
Also possibly worthwhile.... I recall some filesystems were less good than others at corruption. I don't recall if what the current pi image process does is good or bad on that spectrum. Worthwhile to research what the exposure we have is currently.