|
Re: Keeping a Server alive
Quote:
Originally Posted by yash101
Hey guys,
My RPi Web server always crashes at the wrong times (when I am not at home). I came up with this solution to reset it automatically:
Here is the sequence:
i2c interface between MCU and Pi
MCU controlling power to Pi via relay
MCU keeps pinging the Pi via i2C (sending a packet and waiting for response)
If the MCU fails the ping 5 times in a row, calls the reboot command (sudo reboot)
MCU waits 2 minutes
MCU pings the Pi a few times to see if it is alive again
Otherwise, MCU resets Pi by unplugging it and plugging it back in (relay)
MCU calls command to clear our corruptions on the HDD
MCU reboots server
Server up again!
|
What happens if your MCU crashes?
__________________
If molecular reactions are deterministic, are all universes identical?
RIP David Shafer: you will be missed


|