Reading through the shake manual I noticed that shutting down the shake from the web GUI is the only recommended way in order to prevent damage and data corruption. Because I am developing a remote installation, access to the web GUI is not possible. Can someone provide me with an API that I can call (such as POST localhost/shutdown) so that I can programmatically perform a shutdown in the event of low power?
yes, this is possible in other ways than just from the GUI. namely, the command
> rsh-system-cmd S
will shut down the machine for you safely (data services are first shut down in a friendly manner). likewise, the same command can be used to reboot the machine, but specifying âRâ as the sole argument:
> rsh-system-cmd R
there is no API available from the outside, for obvious security reasons, but this command can be sent using ssh to achieve the same result.
Sorry to reopen this question after so many years. I have two questions:
There are several instructions in the manual, for example, where the user is instructed to use the sudo reboot command. Would this be considered a âgraceful shutdownâ? Or do we need to first go through the rs.local dashboard and shutdown the shake?
After doing rsh-system-cmd S and shutting down and unplugging the shake, does the reboot (rsh-system-cmd R) or any other command need to be done after turning the shake back on? Or does it automatically restart the rsh system/services when turned back on?
That is correct, sudo reboot is a graceful shutdown command, as doing the same action via ârs.local/â is. Basically, anything different from âpulling the plug without shutting down the Shakeâ (which can damage the microSD card) can be considered as âgracefulâ.
No, regardless of the shutdown method (sudo shutdown, rsh-system-cmd S, or others), all RS software services are started from a NULL state on system boot-up. That is, no assumptions are made as to how the system was previously shut down.
If you need anything else, let us know. Youâre welcome!