Hey everyone…
I just did a complete Udpate of my pi
sudo apt-get update
sudo apt full-upgrade
sudo apt clean
I am now on “Raspbian GNU/Linux 9 (stretch)”.
After that i switched to the Magic Mirror Folder and did a
git pull
Everything worked like a charm.
But now the Magic Mirror 2 won’t start…
I also did a reinstall of pm2 (i used this -> https://github.com/MichMich/MagicMirror/wiki/Auto-Starting-MagicMirror)
“pm2 show mm” gives me:
pi@mirrorpi:~/script $ pm2 show mm
Describing process with id 1 - name mm
┌───────────────────┬─────────────────────────────────┐
│ status │ online │
│ name │ mm │
│ namespace │ default │
│ version │ N/A │
│ restarts │ 6845 │
│ uptime │ 0s │
│ script path │ /home/pi/mm.sh │
│ script args │ N/A │
│ error log path │ /home/pi/.pm2/logs/mm-error.log │
│ out log path │ /home/pi/.pm2/logs/mm-out.log │
│ pid path │ /home/pi/.pm2/pids/mm-1.pid │
│ interpreter │ bash │
│ interpreter args │ N/A │
│ script id │ 1 │
│ exec cwd │ /home/pi │
│ exec mode │ fork_mode │
│ node.js version │ N/A │
│ node env │ N/A │
│ watch & reload │ ✘ │
│ unstable restarts │ 0 │
│ created at │ 2020-07-26T14:26:42.028Z │
└───────────────────┴─────────────────────────────────┘
Divergent env variables from local env
┌────────────────┬──────────────────────┐
│ SSH_CONNECTION │ fe80::6d33:b8d3:9d81 │
│ PWD │ /home/pi/.pm2/module │
│ SSH_CLIENT │ fe80::6d33:b8d3:9d81 │
└────────────────┴──────────────────────┘
Add your own code metrics: http://bit.ly/code-metrics
Use `pm2 logs mm [--lines 1000]` to display logs
Use `pm2 env 1` to display environment variables
Use `pm2 monit` to monitor CPU and Memory usage mm
Describing process with id 2 - name mm
┌───────────────────┬─────────────────────────────────┐
│ status │ online │
│ name │ mm │
│ namespace │ default │
│ version │ N/A │
│ restarts │ 6841 │
│ uptime │ 0s │
│ script path │ /home/pi/mm.sh │
│ script args │ N/A │
│ error log path │ /home/pi/.pm2/logs/mm-error.log │
│ out log path │ /home/pi/.pm2/logs/mm-out.log │
│ pid path │ /home/pi/.pm2/pids/mm-2.pid │
│ interpreter │ bash │
│ interpreter args │ N/A │
│ script id │ 2 │
│ exec cwd │ /home/pi │
│ exec mode │ fork_mode │
│ node.js version │ N/A │
│ node env │ N/A │
│ watch & reload │ ✘ │
│ unstable restarts │ 0 │
│ created at │ 2020-07-26T14:32:37.082Z │
└───────────────────┴─────────────────────────────────┘
Divergent env variables from local env
┌────────────────┬──────────────────────┐
│ SSH_CONNECTION │ fe80::6d33:b8d3:9d81 │
│ PWD │ /home/pi │
│ SSH_CLIENT │ fe80::6d33:b8d3:9d81 │
└────────────────┴──────────────────────┘
Add your own code metrics: http://bit.ly/code-metrics
Use `pm2 logs mm [--lines 1000]` to display logs
Use `pm2 env 2` to display environment variables
Use `pm2 monit` to monitor CPU and Memory usage mm
If i try to stop and start the mirror i get:
pi@mirrorpi:~/script $ pm2 start mm
[PM2] Applying action restartProcessId on app [mm](ids: [ 1, 2 ])
[PM2] [mm](1) ✓
[PM2] [mm](2) ✓
[PM2] Process successfully started
┌────┬────────────────────┬──────────┬──────┬───────────┬──────────┬──────────┐
│ id │ name │ mode │ ↺ │ status │ cpu │ memory │
├────┼────────────────────┼──────────┼──────┼───────────┼──────────┼──────────┤
│ 1 │ mm │ fork │ 6905 │ online │ 0% │ 2.5mb │
│ 2 │ mm │ fork │ 6902 │ online │ 0% │ 2.6mb │
└────┴────────────────────┴──────────┴──────┴───────────┴──────────┴──────────┘
Module
┌────┬────────────────────┬──────────┬──────────┬──────────┐
│ id │ name │ status │ cpu │ mem │
├────┼────────────────────┼──────────┼──────────┼──────────┤
│ 0 │ pm2-logrotate │ online │ 0% │ 48.1mb │
└────┴────────────────────┴──────────┴──────────┴──────────┘
why do i have 2 id’s??
My startup script looks like this:
cd /~MagicMirror
DISPLAY=:0 npm start
If i try to start the mirror manualy, i get:
pi@mirrorpi:~ $ cd ./MagicMirror
pi@mirrorpi:~/MagicMirror $ npm start
> magicmirror@2.12.0 start /home/pi/MagicMirror
> DISPLAY="${DISPLAY:=:0}" ./node_modules/.bin/electron js/electron.js
[2020-07-28 23:54:26.833] [ERROR] App threw an error during load
[2020-07-28 23:54:26.861] [ERROR] TypeError: Bind must be called on a function
at bind (<anonymous>)
at /home/pi/MagicMirror/js/logger.js:32:38
at /home/pi/MagicMirror/js/logger.js:16:20
at Object.<anonymous> (/home/pi/MagicMirror/js/logger.js:21:3)
at Object.<anonymous> (/home/pi/MagicMirror/js/logger.js:46:3)
at Module._compile (internal/modules/cjs/loader.js:711:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10)
at Module.load (internal/modules/cjs/loader.js:620:32)
at tryModuleLoad (internal/modules/cjs/loader.js:559:12)
at Function.Module._load (internal/modules/cjs/loader.js:551:3)
A JavaScript error occurred in the main process
Uncaught Exception:
TypeError: Bind must be called on a function
at bind (<anonymous>)
at /home/pi/MagicMirror/js/logger.js:32:38
at /home/pi/MagicMirror/js/logger.js:16:20
at Object.<anonymous> (/home/pi/MagicMirror/js/logger.js:21:3)
at Object.<anonymous> (/home/pi/MagicMirror/js/logger.js:46:3)
at Module._compile (internal/modules/cjs/loader.js:711:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10)
at Module.load (internal/modules/cjs/loader.js:620:32)
at tryModuleLoad (internal/modules/cjs/loader.js:559:12)
at Function.Module._load (internal/modules/cjs/loader.js:551:3)
And now i am at a point where i just don’t know what to do…
Well i could try to update Javascript.
The strange thing is: i did this a couple of times - and all the times everything just worked out of the box…
What is going on here?
Plus i now have a steady cpu load around 50%…
what the hell?
Looking forward to any suggestions/ideas/etc.
thank you all
stefan