MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    PM2 status online, but mirror doesn't start

    Scheduled Pinned Locked Moved Solved Troubleshooting
    5 Posts 2 Posters 813 Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M Offline
      matt216
      last edited by

      Fresh install on a Pi 3 B+ using Sam’s install script (thank you - I particularly like the boot splash screen).

      pm2 status shows the MagicMirror application as online, however no mirror appears on the screen. Browsing from another machine to http://ip:8080 gives connection_refused.

      pm2 (red coloured) logs below:

      0|MagicMirror  | [06.10.2023 09:53.38.255] [ERROR] (node:1992) UnhandledPromiseRejectionWarning: /home/pi/MagicMirror/modules/MMM-MyCommute/node_modules/jsbn/index.js:647
      0|MagicMirror  |     function 
      0|MagicMirror  |              
      0|MagicMirror  | SyntaxError: Unexpected end of input
      0|MagicMirror  |     at internalCompileFunction (node:internal/vm:73:18)
      0|MagicMirror  |     at wrapSafe (node:internal/modules/cjs/loader:1185:20)
      0|MagicMirror  |     at Module._compile (node:internal/modules/cjs/loader:1227:27)
      0|MagicMirror  |     at Object..js (node:internal/modules/cjs/loader:1326:10)
      0|MagicMirror  |     at Module.load (node:internal/modules/cjs/loader:1126:32)
      0|MagicMirror  |     at node:internal/modules/cjs/loader:967:12
      0|MagicMirror  |     at Function._load (node:electron/js2c/asar_bundle:2:13327)
      0|MagicMirror  |     at Module.require (node:internal/modules/cjs/loader:1150:19)
      0|MagicMirror  |     at require (node:internal/modules/cjs/helpers:110:18)
      0|MagicMirror  |     at Object.<anonymous> (/home/pi/MagicMirror/modules/MMM-MyCommute/node_modules/ecc-jsbn/lib/ec.js:6:18)
      0|MagicMirror  |     at Module._compile (node:internal/modules/cjs/loader:1271:14)
      0|MagicMirror  |     at Object..js (node:internal/modules/cjs/loader:1326:10)
      0|MagicMirror  |     at Module.load (node:internal/modules/cjs/loader:1126:32)
      0|MagicMirror  |     at node:internal/modules/cjs/loader:967:12
      0|MagicMirror  |     at Function._load (node:electron/js2c/asar_bundle:2:13327)
      0|MagicMirror  |     at Module.require (node:internal/modules/cjs/loader:1150:19)
      0|MagicMirror  | (Use `electron --trace-warnings ...` to show where the warning was created)
      0|MagicMirror  | [06.10.2023 09:53.38.256] [ERROR] (node:1992) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
      0|MagicMirror  | [1992:1006/095338.666307:ERROR:object_proxy.cc(590)] Failed to call method: org.freedesktop.portal.Settings.Read: object_path= /org/freedesktop/portal/desktop: org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.portal.Desktop was not provided by any .service files
      0|MagicMirror  | MESA-LOADER: failed to retrieve device information
      
      

      Anyone spot anything obvious I can look in to?

      The pi has been acting odd since the fresh install - SSH tunnel freezing and not even responding to pings. :worried_face:

      Thanks in advance,
      Matt

      S 1 Reply Last reply Reply Quote 0
      • M Offline
        matt216
        last edited by

        Solution:

        pm2 stop all
        cd ~/MagicMirror
        npm start

        Pay attention to logs. In my case one of the modules was throwing an error. I removed the module folder, re-cloned it (including required npm install within the module folder) and then restarted the application with pm2 start MagicMirror.

        S 1 Reply Last reply Reply Quote 0
        • S Offline
          sdetweil @matt216
          last edited by sdetweil

          @matt216 do this

          pm2 stop all
          cd ~/MagicMirror
          npm start
          

          I suspect this

          https://forum.magicmirror.builders/topic/15778/fix-for-black-screen-in-2-16-and-later

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          M 1 Reply Last reply Reply Quote 0
          • M Offline
            matt216 @sdetweil
            last edited by

            @sdetweil ok and we’re back in and working :)

            the npm start generated a few errors relating to a particular module…

            [06.10.2023 14:10.39.752] [ERROR] (node:2973) UnhandledPromiseRejectionWarning: /home/pi/MagicMirror/modules/MMM-MyCommute/node_modules/jsbn/index.js:647
                function 
            

            So I removed and re-added that. pm2 start MagicMirror got it going again.

            Thank you again!

            Matt

            1 Reply Last reply Reply Quote 0
            • M Offline
              matt216
              last edited by

              Solution:

              pm2 stop all
              cd ~/MagicMirror
              npm start

              Pay attention to logs. In my case one of the modules was throwing an error. I removed the module folder, re-cloned it (including required npm install within the module folder) and then restarted the application with pm2 start MagicMirror.

              S 1 Reply Last reply Reply Quote 0
              • S Offline
                sdetweil @matt216
                last edited by

                @matt216 Yes there are a bunch of modules impacted by us removing libraries from the base so you have to carefully look at the error messages to see what libraries were missing and which modules were impacted as well

                see this for general process of fixing missing libs
                https://forum.magicmirror.builders/topic/15778/fix-for-black-screen-in-2-16-and-later

                Sam

                How to add modules

                learning how to use browser developers window for css changes

                1 Reply Last reply Reply Quote 0
                • 1 / 1
                • First post
                  Last post
                Enjoying MagicMirror? Please consider a donation!
                MagicMirror created by Michael Teeuw.
                Forum managed by Sam, technical setup by Karsten.
                This forum is using NodeBB as its core | Contributors
                Contact | Privacy Policy