MagicMirror² v2.5.0 is available! For more information about this release, check out this topic.

PM2 error



  • I get this error when trying to run pm2 startup

    pi@MagicMirror:~ $ pm2 startup
    /usr/lib/node_modules/pm2/bin/pm2:6
    if (semver.satisfies(process.versions.node, ‘>= 6.0.0’))
    ^

    TypeError: semver.satisfies is not a function
    at Object. (/usr/lib/node_modules/pm2/bin/pm2:6:12)
    at Module._compile (internal/modules/cjs/loader.js:654:30)
    at Object.Module._extensions…js (internal/modules/cjs/loader.js:665:10)
    at Module.load (internal/modules/cjs/loader.js:566:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:506:12)
    at Function.Module._load (internal/modules/cjs/loader.js:498:3)
    at Function.Module.runMain (internal/modules/cjs/loader.js:695:10)
    at startup (internal/bootstrap/node.js:201:19)
    at bootstrapNodeJSCore (internal/bootstrap/node.js:516:3)

    Please help a novice



  • I have the exact same issue. Have you found a fix for this?



  • Have you tried reinstalling pm2 or installing the latest version?

    sudo npm install pm2@latest -g
    

    I can’t find the line mentioned in the file /usr/lib/node_modules/pm2.
    So better reinstall I guess…



  • @lavolp3 I have not, right now my workaround is not using pm2 at all and just starting Magic Mirror with DISPLAY=:0 npm start



  • tried re-installing, same issue



  • @status-board how do I do this