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.

    MagicMirror won't load.

    Scheduled Pinned Locked Moved Solved Troubleshooting
    3 Posts 2 Posters 773 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.
    • A Offline
      aunrea
      last edited by

      I tried to upgrade MagicMirror earlier but then MagicMirror would not load. No black screen, just never opening. So I did a fresh install of Raspberry Pi OS and Magic Mirror.
      I am using a Raspberry Pi 4 with Raspberry Pi OS 64-bit. Everything was working so I went ahead and installed some modules and copied over my config and CSS files. Now it won’t load again. I have tried using pm2 start mm.sh (I set up the mm.sh as per the MM documentation). I have also tried pm2 start mm.sh. Terminal gives my no errors, it looks like MM is loading, but MagicMirror doesn’t load.

      My pm2 mm-error log file has this message:

      [02.12.2023 18:33.47.262] [ERROR] (node:1232) UnhandledPromiseRejectionWarning: Error: Cannot find module 'node-fetch'
      Require stack:
      - /home/pi/MagicMirror/modules/MMM-OneTracker/node_helper.js
      - /home/pi/MagicMirror/js/app.js
      - /home/pi/MagicMirror/js/electron.js
      - /home/pi/MagicMirror/node_modules/electron/dist/resources/default_app.asar/main.js
      - 
          at node:internal/modules/cjs/loader:1084:15
          at Function.<anonymous> (node:electron/js2c/browser_init:2:117419)
          at Module._resolveFilename (/home/pi/MagicMirror/node_modules/module-alias/index.js:49:29)
          at node:internal/modules/cjs/loader:929:27
          at Function._load (node:electron/js2c/asar_bundle:2:13327)
          at Module.require (node:internal/modules/cjs/loader:1150:19)
          at require (node:internal/modules/cjs/helpers:110:18)
          at Object.<anonymous> (/home/pi/MagicMirror/modules/MMM-OneTracker/node_helper.js:10:15)
          at Module._compile (node:internal/modules/cjs/loader:1271:14)
          at Object..js (node:internal/modules/cjs/loader:1326:10)
          at Module.load (node:internal/modules/cjs/loader:1126:32)
          at node:internal/modules/cjs/loader:967:12
          at Function._load (node:electron/js2c/asar_bundle:2:13327)
          at Module.require (node:internal/modules/cjs/loader:1150:19)
          at require (node:internal/modules/cjs/helpers:110:18)
          at loadModule (/home/pi/MagicMirror/js/app.js:180:19)
          at loadModules (/home/pi/MagicMirror/js/app.js:210:10)
          at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
          at async App.start (/home/pi/MagicMirror/js/app.js:258:3)
      (Use `electron --trace-warnings ...` to show where the warning was created)
      [02.12.2023 18:33.47.264] [ERROR] (node:1232) 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)
      [1947:1202/183350.594642:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.595113:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.595532:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.595918:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.596287:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.610727:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.611149:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.613660:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.622792:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.623222:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.623582:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.623993:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.624373:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      [1947:1202/183350.624748:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
      
      

      If I run pm2 info mm I get this info

      
       Describing process with id 0 - name mm
      ┌───────────────────┬─────────────────────────────────┐
      │ status            │ online                          │
      │ name              │ mm                              │
      │ namespace         │ default                         │
      │ version           │ N/A                             │
      │ restarts          │ 0                               │
      │ uptime            │ 7m                              │
      │ 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-0.pid     │
      │ interpreter       │ bash                            │
      │ interpreter args  │ N/A                             │
      │ script id         │ 0                               │
      │ exec cwd          │ /home/pi                        │
      │ exec mode         │ fork_mode                       │
      │ node.js version   │ N/A                             │
      │ node env          │ N/A                             │
      │ watch & reload    │ ✘                               │
      │ unstable restarts │ 0                               │
      │ created at        │ 2023-12-02T23:30:45.763Z        │
      └───────────────────┴─────────────────────────────────┘
       Divergent env variables from local env
      ┌────────────────┬──────────────────────┐
      │ SSH_CONNECTION │ 10.0.0.79 52375 10.0 │
      │ SSH_CLIENT     │ 10.0.0.79 52375 22   │
      └────────────────┴──────────────────────┘
      
       Add your own code metrics: http://bit.ly/code-metrics
       Use `pm2 logs mm [--lines 1000]` to display logs
       Use `pm2 env 0` to display environment variables
       Use `pm2 monit` to monitor CPU and Memory usage mm
      
      

      I am not sure what to do to fix this. I have been trying to figure it out for over 6 hours and have no answers. Any help is appreciated.

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

        @aunrea Cannot find module ‘node-fetch’
        Require stack:

        • /home/pi/MagicMirror/modules/MMM-OneTracker/node_helper.js

        in the MMM-OneTracker folder do

        npm install node-fetch@2
        

        we removed that library in this release as node has a built-in and supported fetch

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        A 1 Reply Last reply Reply Quote 0
        • A Offline
          aunrea @sdetweil
          last edited by

          @sdetweil Thank you that fixed the issue.

          1 Reply Last reply Reply Quote 1
          • 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