This shows you the differences between two versions of the page.
Next revision | Previous revisionNext revisionBoth sides next revision | ||
one_off_reboot [2020/08/28 12:17] – created rs232 | one_off_reboot [2023/05/23 19:46] – -condense, formatting hogwild | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== One off reboot | + | ====== |
- | You might find yourself in the position where you need to e.g. restart your device | + | What if you wanted |
- | A simple workaround is to add a command to the contable to do this for you: | + | You might have noticed the option under // |
- | < | + | A simple solution to this is to configure a reboot to be performed only once. FreshTomato includes a miniature version of the Linux crontable command, called " |
+ | |||
+ | You can arrange the the above by adding a command directly into the crontable. | ||
+ | |||
+ | \\ | ||
+ | |||
+ | For example: | ||
+ | |||
+ | \\ | ||
+ | |||
+ | < | ||
cru a reboot-one-off "0 5 * * * / | cru a reboot-one-off "0 5 * * * / | ||
+ | </ | ||
+ | |||
+ | \\ This command would restart your device at 5:00 AM. | ||
+ | |||
+ | The standard Unix cron syntax can be found here: [[https:// | ||
+ | |||
+ | This command will take effect on a running device, but would not be saved permanently in the configuration. Thus, after a reboot, the scheduled activity would automatically disappear, which in this case, is the desired result. | ||
+ | |||
+ | If you need to remove the scheduled activity before it is executed, use the following command: | ||
+ | |||
+ | \\ | ||
+ | |||
+ | <code -> | ||
+ | cru d reboot-one-off | ||
+ | </ | ||
+ | |||
+ | | ||
+ | |||
+ | \\ | ||
+ | <code -> | ||
+ | cru l | ||
</ | </ | ||
- | This command above will restart your device at 5am. The time syntax is the standard unix [[https:// | + | \\ |
- | NOTE: this is effective but not saved permanently anywhere in the confi, hence after reboot the sheduled activity will automatically disappear. | + | \\ |