System Corn Reboot Pi-Star
System Corn Reboot Pi-Star
Hi.
Can someone make a command line to add to System Corn to reboot Pi-Star at 3am ?
Would want this to happen every day at 3am
Hope someone can help.
Many thanks
Norman
Can someone make a command line to add to System Corn to reboot Pi-Star at 3am ?
Would want this to happen every day at 3am
Hope someone can help.
Many thanks
Norman
Re: System Corn Reboot Pi-Star
Firstly you don't want to select 3am because this is the time that the overnight updates are run!
Under the expert tab you will see one titled System Cron, go into that and add to the end of the list
This will reboot the pi at 04:15am every day!
Sent from my Pixel 2 XL using Tapatalk
Under the expert tab you will see one titled System Cron, go into that and add to the end of the list
Code: Select all
15 4 * * * root /sbin/shutdown -r now >/dev/null 2>&1
Sent from my Pixel 2 XL using Tapatalk
Re: System Corn Reboot Pi-Star
I just tried
It did not reboot at 17.03hrs
Any help welcome
Code: Select all
3 17 * * * root /sbin/shutdown -r now >/dev/null 2>&1
Any help welcome
Re: System Corn Reboot Pi-Star
Ok I thought by specifying the full syntax would have worked! So try...
See how you go!
Sent from my Pixel 2 XL using Tapatalk
Code: Select all
3 17 * * * root reboot >/dev/null 2>&1
Sent from my Pixel 2 XL using Tapatalk
Re: System Corn Reboot Pi-Star
Also tried this and it did not work
Have also restarted Pi-Star when made any changes to make sure the new setting will be read.
.
Code: Select all
22 17 * * * root /usr/local/sbin/shutdown -r now >/dev/null 2>&1
.
Re: System Corn Reboot Pi-Star
Ok you can pipe the output of the command to a text file with...
Just make sure you have the drive set to rw access! Otherwise it cannot write the file...
Sent from my Pixel 2 XL using Tapatalk
Code: Select all
40 17 * * * root /sbin/shutdown -r now > /home/pi-star/cron_output.txt
Sent from my Pixel 2 XL using Tapatalk
Last edited by VK7HSE on Fri Jun 07, 2019 4:36 pm, edited 1 time in total.
Re: System Corn Reboot Pi-Star
Just looked in /usr/local/sbin/ and can not see a shutdown command.
Re: System Corn Reboot Pi-Star
Scratch trying to pipe the output cause the pi essentially is to fast on the shutdown!
Code: Select all
15 3 * * * root /sbin/shutdown -r now >/dev/null 2>&1
Re: System Corn Reboot Pi-Star
If you change to the root user and just try...
This should cause the pi to reboot! (I've just tested it and it works)
So this "should" work!
Sent from my Pixel 2 XL using Tapatalk
Code: Select all
sudo - s
/sbin/shutdown -r now
Code: Select all
15 3 * * * root /sbin/shutdown -r now >/dev/null 2>&1
Sent from my Pixel 2 XL using Tapatalk
Last edited by VK7HSE on Fri Jun 07, 2019 5:06 pm, edited 1 time in total.
Re: System Corn Reboot Pi-Star
This worked
But only when I moved the code to the top of the list
So if I do
That will reboot at 04.15am every day.
Thank you so much for all your help
Norman M6NBP
Code: Select all
5 18 * * * root reboot >/dev/null 2>&1
So if I do
Code: Select all
15 4 * * * root reboot >/dev/null 2>&1
Thank you so much for all your help
Norman M6NBP