I'd like to know if there's a way to find out when the next time a cron job will run - via a bash job. Has anyone tried something like this?
I've been googling but I haven't found anything yet.
Just some more details of what I'm after. When I check crontab -l, see the following output:
lab-1:/etc/crontabs# crontab -l # do daily/weekly/monthly maintenance # min hour day month weekday command */15 * * * * run-parts /etc/periodic/15min 0 * * * * run-parts /etc/periodic/hourly 0 2 * * * run-parts /etc/periodic/daily 0 3 * * 6 run-parts /etc/periodic/weekly 0 5 1 * * run-parts /etc/periodic/monthly #Ansible: Run every minute * * * * * run-parts /etc/periodic/1min
What I need to know is not just that the 15 minute folder is "enabled" but if there's a way, I'd like to know that for example, 3 minutes from now, the job in the 15 minute folder will be triggered.
Is there any way to do this?