2

How can I test if @reboot is working without the need of reboot the machine? Is there anyway to force @reboot to entry to run?

Thank you.

2
  • Copy it and schedule it to run at a time shortly in the future? Remember to undo the copy after its run.
    – davidgo
    Commented May 7, 2020 at 5:21
  • That said, depending on the job, even if you can trigger it without a reboot, it may not be equivalent because the system could be in a different state when its launched @reboot.
    – davidgo
    Commented May 7, 2020 at 5:22

1 Answer 1

4

crond is checking if the file /var/run/crond.reboot exists. If it exists, cron skips @reboot jobs

sudo rm /var/run/crond.reboot 
sudo service cron restart

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .