When there are very small time window to update the content in flash. do you choose to:
1. initially mount as ro, remount as rw, write your changes and remount back to ro? OR 2. just mount as rw to boot up? On Thu, Mar 27, 2014 at 8:47 PM, Yiling Cao <yiling....@gmail.com> wrote: > Thanks for your reply. > > On Thu, Mar 27, 2014 at 8:41 PM, Charles Steinkuehler < > char...@steinkuehler.net> wrote: > >> On 3/26/2014 10:22 PM, Yiling Cao wrote: >> > Thanks Brandon for your experience. I do agree with that better to put >> > whole disk read only. >> > >> > But how do iPhone and Android survive? Esp for those Android phones? >> They >> > are very prone to sudden power removal as well. >> >> What? These devices are battery powered, and other than opening the >> case and physically removing the battery they are guaranteed enough >> power to do a proper and orderly shutdown. >> >> What I mean is you can take out battery at back very easily as well. > > >> > How do routers handle this issue? they save the settings on different >> > devices? >> >> Routers save a very small amount of setup data, and either have a very >> small window when they are writing updates to the filesystem, or in some >> cases can store the configuration in EEPROM. >> >> > I have a SQLite db around 1-2M and data will be written to them. Would >> like >> > to have some easy and quick solution to make it absolutely stable. >> >> I don't think "easy and quick" go together with "absolutely stable" in >> this context. You're looking at solutions like adding a backup battery, >> migrating your SQLite db to a different storage device, or other >> solutions that do not fit the "easy and quick" description. >> >> I think about the simplest thing you can do is add a uSD card and >> separate the OS from the data storage. This gets you around the problem >> of corrupting the OS when writing to the data, but you can still run >> into problems because the uSD card need to have specific boot files >> present or the BBB won't boot. That problem can be fixed by updating >> the u-boot configuration on the eMMC so it ignores the uSD card and >> always boots from eMMC. >> >> You'll still need to be able to deal with data corruption in your db >> files, but that's a solvable software problem if the system reliably >> boots. >> >> > I have already minimized data writes. I hope by next version I will write > stuff to eeprom. > >> -- >> Charles Steinkuehler >> char...@steinkuehler.net >> >> -- >> For more options, visit http://beagleboard.org/discuss >> --- >> You received this message because you are subscribed to the Google Groups >> "BeagleBoard" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to beagleboard+unsubscr...@googlegroups.com. >> For more options, visit https://groups.google.com/d/optout. >> > > -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.