zakk Posted April 4, 2017 Posted April 4, 2017 Hi all, I am using NanoPi-Neo Air and my application is just logging binary data to a file. The board is powered by usb from a pc. I can dump and list to see binary data inside the file but after unplug power from usb then power up the board from usb again, I found the binary data is gone or some errors data, unknown data appended. Do you guys have same issued? or any suggestions? Thanks in advance
rodolfo Posted April 4, 2017 Posted April 4, 2017 Did you sync the data written and do proper shutdown before unplugging ? Unplugging without powering down is just like shooting your tyres to stop a car 1
zakk Posted April 5, 2017 Author Posted April 5, 2017 No error when shutdown or reboot by using command shell, but I plan to run the board as a main controller and power up the board by batteries. Just power ON/OFF switch then the circuit ready to work but I am worry that when power off the switch I will get incorrect data logger.
Igor Posted April 5, 2017 Posted April 5, 2017 4 hours ago, zakk said: Just power ON/OFF switch then the circuit ready to work but I am worry that when power off the switch I will get incorrect data logger. Our system is prepared for general usage and if you want to achieve this you'll need to alter few things. First is mount option commit=600 for root fs (/etc/fstab). Remove or set to 0. And the most extreme / safe thing is setting file system read-only. In this case you should not loose anything. 1
Recommended Posts