Stable: 2.5.2
Development: 2.6-alpha3
I lose power in my area occasionally and would really like my system (RPi3) to auto reboot like I can with the bios under other pc's i have. I realise this is RPi specific but wondered if anyone else had pursued this with a RPi at all?
I found someones work around for dealing with this and it read:
"I managed to get past this issue by installing the operating system on a usb stick, I used a "cruzer fit" stick due to how small it is.
I would then modify the boot sequence on the SD card to boot from the usb stick. Read write would switch to the usb stick after boot thus limiting the chance for the sd card to get corrupted.
The device in question has been running as a media centre for more than a year and dropping power of any kind has not caused any issues yet"
...I have no idea if the above will sit ok with MOC but any pointers will help me not waste time trying possibly!
Sean
tomaszg
Mon, 2019-11-25 09:46
Permalink
The only thing that may here
The only thing that may here have something to do with MOC is the fact that sometimes when MOC shuts down not cleanly, it leaves behind a PID file (~/.moc/pid) which needs to be manually removed after restart.
Other things are more less unrelated or RPi specific. However from my experience, reboots rarely cause data corruption these days with modern journaling filesystems. But you probably know that the best solution to your problem is to get a UPS :)
seanjackson
Thu, 2019-11-28 18:21
Permalink
yes i think a UPS is probably
yes i think a UPS is probably the way to go for me, and yes i am experiencing the PID file remove flag because of my shutdowns. thanks
jcf
Mon, 2019-11-25 18:58
Permalink
Auto-Restartablilty
There will be numerous examples on your system of what it is (we think) you're trying to achieve. Check out your
/etc/rc.d
or/etc/init.d
directory (or whatever SystemD uses if that's what RPi uses), or/etc/inittab
. Using those clues you should be able to auto-restart MOC, if that's your intent.As to the more general question of how to auto-restart the RPi itself, that is outside the scope of this Forum. You would need to consult a more RPI-specific source.
seanjackson
Thu, 2019-11-28 18:23
Permalink
i'm not in deep enough to
i'm not in deep enough to understand everything you mention but yes point taken about other forum, thanks.