Maybe more of a Linux question, but by googling is not yielding the result I am after.
Is there a Linux command to queue up a fw console reload command? For example if I wanted the command to run in 5 minutes, I could execute the command now and go about my business (type other commands, log out, etc.). 5 minutes later the command would execute.
You can also use the at command. The advantage is that it will survive a reboot, and has no trace of any connection with your console. A possible disadvantage is that I believe it will try to email you standard error, if not empty, and FreePBX doesn’t set up mail well for mail addressed to the local user.
E.g.
$ at now + 5 minutes
warning: commands will be executed using /bin/sh
at> echo > /dev/null
at> <EOT>
job 1 at Sat Jan 22 01:08:00 2022
<EOT> represents control-D.
You can specify quite complex times, which can be absolute and include a specific day of the week.
I think the at command is actually what I want to use but it is not clicking for me after looking at the documentation. How would I write a dialplan line " in 5 minutes trigger fwconsole reload"?
Incase anyone needs this in the future, the working input is.
exten => s,n,System(echo “fwconsole reload” | at now + x minutes)
x is the number of minutes you want to delay before the command fires. This could be used asynchronously fire off other commands while the dial plan continues to execute or concludes.