II12yanII
Posts: 7
Joined: Thu Oct 13, 2016 3:25 am

need help with crontab

Tue Oct 25, 2016 3:52 am

i cant seem to get crontab to work correctly i guess im not understanding it entirely. i installed the packages and did crontab -e to edit the schedule but i cant seem to get it to execute. im trying to start magic mirror on startup. im starting the line with @reboot but then after that im confused at to put. all i really need to do is launch the terminal and put in two commands CD MagicMirror and the put in npm start. any help would be greatly appreciated.

User avatar
DougieLawson
Posts: 39304
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: need help with crontab

Tue Oct 25, 2016 6:06 pm

If your program needs Xwindows running then starting it from @reboot happens too early.

Start it from the LXDE / Pixel autostart directory.
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

II12yanII
Posts: 7
Joined: Thu Oct 13, 2016 3:25 am

Re: need help with crontab

Wed Oct 26, 2016 7:23 pm

DougieLawson wrote:If your program needs Xwindows running then starting it from @reboot happens too early.

Start it from the LXDE / Pixel autostart directory.
Then what variable would work? What I'm trying to do is that if the pi loses power due to a power outage or something when power does return I'd like the pi to boot up and in that time start the magic mirror process.

User avatar
DougieLawson
Posts: 39304
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: need help with crontab

Wed Oct 26, 2016 7:35 pm

Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

Return to “Beginners”