Read the statement by Michael Teeuw here.
Crontab to Restart Magic Mirror does not work
-
-
Could you please show the crontab ?
$ crontab -l
To get rid of this:
(CRON) info (No MTA installed, discarding output)
you have to add
>/dev/null 2>&1
Try:
44 * * * * /usr/local/bin/pm2 start MagicMirror >/dev/null 2>&1
-
Problem resolved! Outstanding.
My thanks to all who responded.
My mission now is to research the provided solution and try to understand why it worked. Clearly the devil is in the details.
Thanks again to all of you
-
@desert-rat said in Crontab to Restart Magic Mirror does not work:
to understand why it worked.
your crontab entry
44 * * * * PM2 restart MagicMirror
the working crontab entry
44 * * * * /usr/local/bin/pm2 start MagicMirror >/dev/null 2>&1
could be restart as well…
simple, two things
cron runs as root, BUT certain folders are not in the path
so you need to specify the path to the command/usr/local/bin/
second the command is pm2, you tried PM2
in linux EVERYTHING is case sensitiveso yours is command not found, cause there is no command named PM2
-
@sdetweil Thanks Sam! I clearly need some education. Do you have a favorite set of training documentation for newbies
Desert Rat
-
@desert-rat sorry. no idea. my info is gathered over 20+ years
there are online linux courses, but I don’t know where they start, or how deep they go, how fast.
I have a near photographic memory which is a blessing and a curse…