Read the statement by Michael Teeuw here.
Problem with instalation on raspbian
-
Hello everyone,
I used the Magic Mirror website installation guide, but I got the error that my node.js version is not supported by Magic Mirror (it was the node.js version that was on the website: version 10. I don’t now). So I installed the latest version of node.js (version 12.18.2) with this command:curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
But then I got this error:
> magicmirror@2.12.0 start /home/pi/MagicMirror > DISPLAY="${DISPLAY:=:0}" ./node_modules/.bin/electron js/electron.js sh: 1: ./node_modules/.bin/electron: not found npm ERR! code ELIFECYCLE npm ERR! syscall spawn npm ERR! file sh npm ERR! errno ENOENT npm ERR! magicmirror@2.12.0 start: `DISPLAY="${DISPLAY:=:0}" ./node_modules/.bin/electron js/electron.js` npm ERR! spawn ENOENT npm ERR! npm ERR! Failed at the magicmirror@2.12.0 start script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /home/pi/.npm/_logs/2020-07-06T17_40_44_705Z-debug.log
Can anyone help me?
-
@Ety60 use the install script command from here
https://github.com/sdetweil/MagicMirror_scripts
if this is a pi0, electron is no longer available, but I set the system up in split mode the run chromium instead
-
I did it and it was successful. But what do I do now to restart the MagicMirror software? It still doesn’t work with this:
cd MagicMirror
npm run start
I’m using an rpi 4 for this project.
-
@Ety60 when u did the install, did u say yes to pm2?
if so, then pm2 start 0 should work, also npm start should work
if you did use pm2, then it will start at boot, so npm start would try to start a second copy.
pm2 status will show u what is running
-
The program did not ask me to install pm2.
-
@Ety60 then u did not use my script.
does ~/install.log exist? -
yes ~·install.log exist. So I think I used your script.
-
@Ety60 and it should have prompted you, “Do you want to use pm2 to autostart your MagicMirror”
if u said n, and want to fix it, you can use the fixuppm2.sh script
-
@sdetweil I tried to run the entire script again and this time asked me for pm2. It worked and MagicMirror now works. Thank you very much for your help!