I would like to execute a script after 12 hours. I could execute the script by remote access, but problem is I will be travelling by flight and may not have internet access. So I was wondering if there is some command to execute a script after few hours or at some specific time. e.g.,
cat my_script.sh
echo Hello World
run my_script.sh at 23:00 hr
Take a look at the man page for at
man at
There are lots of ways you can specify the time. You can do something like:
at -f my_script.sh 23:00
Use cron job in linux. like
0 */12 1 11 3 /bin/execute/my/script.sh >/dev/null 2>&1
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With