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.

    updated installer script available for testing

    Scheduled Pinned Locked Moved Solved Troubleshooting
    211 Posts 18 Posters 254.5k Views 19 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.
    • S Offline
      sdetweil @jorgnyg
      last edited by

      @jorgnyg the run-start.sh script now handles this problem and launches chromium instead of electron to connect to mm in serveronly mode

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      J 1 Reply Last reply Reply Quote 0
      • J Offline
        jorgnyg @sdetweil
        last edited by

        @sdetweil got it!

        1 Reply Last reply Reply Quote 0
        • J Offline
          jthirasilpa
          last edited by

          Hi - firstly thanks for putting together this installer!

          I am running Raspbian on RP3b+ as a fresh install using the command

          curl -sL https://raw.githubusercontent.com/sdetweil/MagicMirror_scripts/master/raspberry.sh | bash

          Installer indicated successful install of MagicMirror.

          Using SSH DISPLAY=:0 npm start gives the following error:

          magicmirror@2.10.1 start /home/jojo/MagicMirror
          ./run-start.sh

          No protocol specified

          (electron:17801): Gtk-WARNING **: 18:36:26.218: cannot open display: :0
          npm ERR! code ELIFECYCLE
          npm ERR! errno 1
          npm ERR! magicmirror@2.10.1 start: ./run-start.sh
          npm ERR! Exit status 1
          npm ERR!
          npm ERR! Failed at the magicmirror@2.10.1 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/jojo/.npm/_logs/2020-01-25T18_36_26_308Z-debug.log

          Debug log contents are as follows:

          0 info it worked if it ends with ok
          1 verbose cli [ ‘/usr/bin/node’, ‘/usr/bin/npm’, ‘start’ ]
          2 info using npm@6.13.4
          3 info using node@v10.18.1
          4 verbose run-script [ ‘prestart’, ‘start’, ‘poststart’ ]
          5 info lifecycle magicmirror@2.10.1~prestart: magicmirror@2.10.1
          6 info lifecycle magicmirror@2.10.1~start: magicmirror@2.10.1
          7 verbose lifecycle magicmirror@2.10.1~start: unsafe-perm in lifecycle true
          8 verbose lifecycle magicmirror@2.10.1~start: PATH: /usr/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/jojo/MagicMirror/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games
          9 verbose lifecycle magicmirror@2.10.1~start: CWD: /home/jojo/MagicMirror
          10 silly lifecycle magicmirror@2.10.1~start: Args: [ ‘-c’, ‘./run-start.sh’ ]
          11 silly lifecycle magicmirror@2.10.1~start: Returned: code: 1 signal: null
          12 info lifecycle magicmirror@2.10.1~start: Failed to exec start script
          13 verbose stack Error: magicmirror@2.10.1 start: ./run-start.sh
          13 verbose stack Exit status 1
          13 verbose stack at EventEmitter. (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
          13 verbose stack at EventEmitter.emit (events.js:198:13)
          13 verbose stack at ChildProcess. (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
          13 verbose stack at ChildProcess.emit (events.js:198:13)
          13 verbose stack at maybeClose (internal/child_process.js:982:16)
          13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
          14 verbose pkgid magicmirror@2.10.1
          15 verbose cwd /home/jojo/MagicMirror
          16 verbose Linux 4.19.75-v7+
          17 verbose argv “/usr/bin/node” “/usr/bin/npm” “start”
          18 verbose node v10.18.1
          19 verbose npm v6.13.4
          20 error code ELIFECYCLE
          21 error errno 1
          22 error magicmirror@2.10.1 start: ./run-start.sh
          22 error Exit status 1
          23 error Failed at the magicmirror@2.10.1 start script.
          23 error This is probably not a problem with npm. There is likely additional logging output above.
          24 verbose exit [ 1, true ]

          Any thoughts on how to troubleshoot? Many thanks.

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

            @jthirasilpa seems like you are running in console mode, instead of graphical mode.

            Mm requires the full desktop.

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            J 1 Reply Last reply Reply Quote 0
            • J Offline
              jthirasilpa @sdetweil
              last edited by

              @sdetweil Thanks. The RP is running a full desktop - if I run npm start directly from the RP, the debug log gives the following output:

              0 info it worked if it ends with ok
              1 verbose cli [ ‘/usr/bin/node’, ‘/usr/bin/npm’, ‘start’ ]
              2 info using npm@6.13.4
              3 info using node@v10.18.1
              4 verbose run-script [ ‘prestart’, ‘start’, ‘poststart’ ]
              5 info lifecycle magicmirror@2.10.1~prestart: magicmirror@2.10.1
              6 info lifecycle magicmirror@2.10.1~start: magicmirror@2.10.1
              7 verbose lifecycle magicmirror@2.10.1~start: unsafe-perm in lifecycle true
              8 verbose lifecycle magicmirror@2.10.1~start: PATH: /usr/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/jojo/MagicMirror/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games
              9 verbose lifecycle magicmirror@2.10.1~start: CWD: /home/jojo/MagicMirror
              10 silly lifecycle magicmirror@2.10.1~start: Args: [ ‘-c’, ‘./run-start.sh’ ]
              11 silly lifecycle magicmirror@2.10.1~start: Returned: code: 1 signal: null
              12 info lifecycle magicmirror@2.10.1~start: Failed to exec start script
              13 verbose stack Error: magicmirror@2.10.1 start: ./run-start.sh
              13 verbose stack Exit status 1
              13 verbose stack at EventEmitter. (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
              13 verbose stack at EventEmitter.emit (events.js:198:13)
              13 verbose stack at ChildProcess. (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
              13 verbose stack at ChildProcess.emit (events.js:198:13)
              13 verbose stack at maybeClose (internal/child_process.js:982:16)
              13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
              14 verbose pkgid magicmirror@2.10.1
              15 verbose cwd /home/jojo/MagicMirror
              16 verbose Linux 4.19.75-v7+
              17 verbose argv “/usr/bin/node” “/usr/bin/npm” “start”
              18 verbose node v10.18.1
              19 verbose npm v6.13.4
              20 error code ELIFECYCLE
              21 error errno 1
              22 error magicmirror@2.10.1 start: ./run-start.sh
              22 error Exit status 1
              23 error Failed at the magicmirror@2.10.1 start script.
              23 error This is probably not a problem with npm. There is likely additional logging output above.
              24 verbose exit [ 1, true ]

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

                @jthirasilpa change line 1 of run-start.sh to be

                #~/bin/bash -x
                

                then do the npm start again…

                also do

                 which chromium-browser
                

                my system returns
                /usr/bin/chromium-browser

                can u send me the MagicMirror/installers/upgrade.log via email

                same userid as here, at gmail

                thanks

                Sam

                How to add modules

                learning how to use browser developers window for css changes

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

                  @sdetweil sorry, typo on run-start

                  #!/bin/bash -x
                  

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  J 1 Reply Last reply Reply Quote 0
                  • N Offline
                    Neebotol
                    last edited by

                    Hello there!

                    Thank you for this script, it has worked better than the original one for me. But I still really unlucky and have an issue.

                    Here it is :

                    pi@raspberrypi:~ $ curl -sL https://raw.githubusercontent.com/sdetweil/MagicMirr  or_scripts/master/raspberry.sh | bash
                    
                    $$\      $$\                     $$\           $$\      $$\ $$\                                            $$$$$$\
                    $$$\    $$$ |                    \__|          $$$\    $$$ |\__|                                          $$  __$$\
                    $$$$\  $$$$ | $$$$$$\   $$$$$$\  $$\  $$$$$$$\ $$$$\  $$$$ |$$\  $$$$$$\   $$$$$  $\   $$$$$$\   $$$$$$\  \__/  $$ |
                    $$\$$\$$ $$ | \____$$\ $$  __$$\ $$ |$$  _____|$$\$$\$$ $$ |$$ |$$  __$$\ $$  __  $$\ $$  __$$\ $$  __$$\  $$$$$$  |
                    $$ \$$$  $$ | $$$$$$$ |$$ /  $$ |$$ |$$ /      $$ \$$$  $$ |$$ |$$ |  \__|$$ |    \__|$$ /  $$ |$$ |  \__|$$  ____/
                    $$ |\$  /$$ |$$  __$$ |$$ |  $$ |$$ |$$ |      $$ |\$  /$$ |$$ |$$ |      $$ |        $$ |  $$ |$$ |      $$ |
                    $$ | \_/ $$ |\$$$$$$$ |\$$$$$$$ |$$ |\$$$$$$$\ $$ | \_/ $$ |$$ |$$ |      $$ |        \$$$$$$  |$$ |      $$$$$$$$\
                    \__|     \__| \_______| \____$$ |\__| \_______|\__|     \__|\__|\__|      \__|         \______/ \__|      \________|
                                           $$\   $$ |
                                           \$$$$$$  |
                                            \______/
                    
                    install log being saved to /home/pi/install.log
                    Updating packages ...
                    Installing helper tools ...
                    Lecture des listes de paquets... Fait
                    Construction de l'arbre des dépendances
                    Lecture des informations d'état... Fait
                    build-essential est déjà la version la plus récente (12.6).
                    curl est déjà la version la plus récente (7.64.0-4).
                    unzip est déjà la version la plus récente (6.0-23+deb10u1).
                    wget est déjà la version la plus récente (1.20.1-1.1).
                    wget passé en « installé manuellement ».
                    Paquets suggérés :
                      git-daemon-run | git-daemon-sysvinit git-doc git-el git-email git-gui gitk gitwe
                    Les paquets suivants seront mis à jour :
                      git
                    1 mis à jour, 0 nouvellement installés, 0 à enlever et 166 non mis à jour.
                    Il est nécessaire de prendre 4 203 ko dans les archives.
                    Après cette opération, 33,8 ko d'espace disque supplémentaires seront utilisés.
                    Réception de :1 http://mirrors.ircam.fr/pub/raspbian/raspbian buster/main armhf gi
                    4 203 ko réceptionnés en 2s (2 281 ko/s)
                    apt-listchanges : Lecture des fichiers de modifications (« changelog »)...
                    (Lecture de la base de données... 93835 fichiers et répertoires déjà installés.)
                    Préparation du dépaquetage de .../git_1%3a2.20.1-2+deb10u1_armhf.deb ...
                    Dépaquetage de git (1:2.20.1-2+deb10u1) sur (1:2.20.1-2) ...
                    Paramétrage de git (1:2.20.1-2+deb10u1) ...
                    Check current Node installation ...
                    Node.js is not installed.
                    Installing Node.js ...
                    Warning: apt-key output should not be parsed (stdout is not a terminal)
                    Lecture des listes de paquets... Fait
                    Construction de l'arbre des dépendances
                    Lecture des informations d'état... Fait
                    Les NOUVEAUX paquets suivants seront installés :
                      nodejs
                    0 mis à jour, 1 nouvellement installés, 0 à enlever et 166 non mis à jour.
                    Il est nécessaire de prendre 14,6 Mo dans les archives.
                    Après cette opération, 77,3 Mo d'espace disque supplémentaires seront utilisés.
                    Réception de :1 https://deb.nodesource.com/node_10.x buster/main armhf nodejs armhf 10.18.1-1nodesource1 [14,6 MB]
                    14,6 Mo réceptionnés en 11s (1 365 ko/s)
                    Sélection du paquet nodejs précédemment désélectionné.
                    (Lecture de la base de données... 93842 fichiers et répertoires déjà installés.)
                    Préparation du dépaquetage de .../nodejs_10.18.1-1nodesource1_armhf.deb ...
                    Dépaquetage de nodejs (10.18.1-1nodesource1) ...
                    Paramétrage de nodejs (10.18.1-1nodesource1) ...
                    Traitement des actions différées (« triggers ») pour man-db (2.8.5-2) ...
                    node version is
                    Node.js installation Done! version=v10.18.1
                    Check current NPM installation ...
                    NPM currently installed. Checking version number.
                    internal/modules/cjs/loader.js:638
                        throw err;
                        ^
                    
                    Error: Cannot find module 'rimraf'
                        at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
                        at Function.Module._load (internal/modules/cjs/loader.js:562:25)
                        at Module.require (internal/modules/cjs/loader.js:692:17)
                        at require (internal/modules/cjs/helpers.js:25:18)
                        at Object.<anonymous> (/usr/lib/node_modules/npm/node_modules/fs-vacuum/vacuum.js:6:14)
                        at Module._compile (internal/modules/cjs/loader.js:778:30)
                        at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
                        at Module.load (internal/modules/cjs/loader.js:653:32)
                        at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
                        at Function.Module._load (internal/modules/cjs/loader.js:585:3)
                    Minimum npm version: V6.0.0
                    Installed npm version: V
                    npm should be upgraded.
                    Installing npm ...
                    E: Impossible de corriger les problèmes, des paquets défectueux sont en mode « garder en l'état ».
                    internal/modules/cjs/loader.js:638
                        throw err;
                        ^
                    
                    Error: Cannot find module 'rimraf'
                        at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
                        at Function.Module._load (internal/modules/cjs/loader.js:562:25)
                        at Module.require (internal/modules/cjs/loader.js:692:17)
                        at require (internal/modules/cjs/helpers.js:25:18)
                        at Object.<anonymous> (/usr/lib/node_modules/npm/node_modules/fs-vacuum/vacuum.js:6:14)
                        at Module._compile (internal/modules/cjs/loader.js:778:30)
                        at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
                        at Module.load (internal/modules/cjs/loader.js:653:32)
                        at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
                        at Function.Module._load (internal/modules/cjs/loader.js:585:3)
                    internal/modules/cjs/loader.js:638
                        throw err;
                        ^
                    
                    Error: Cannot find module 'rimraf'
                        at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
                        at Function.Module._load (internal/modules/cjs/loader.js:562:25)
                        at Module.require (internal/modules/cjs/loader.js:692:17)
                        at require (internal/modules/cjs/helpers.js:25:18)
                        at Object.<anonymous> (/usr/lib/node_modules/npm/node_modules/fs-vacuum/vacuum.js:6:14)
                        at Module._compile (internal/modules/cjs/loader.js:778:30)
                        at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
                        at Module.load (internal/modules/cjs/loader.js:653:32)
                        at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
                        at Function.Module._load (internal/modules/cjs/loader.js:585:3)
                    npm installation Done! version=V
                    Cloning MagicMirror ...
                    Clonage dans 'MagicMirror'...
                    remote: Enumerating objects: 331, done.
                    remote: Counting objects: 100% (331/331), done.
                    remote: Compressing objects: 100% (295/295), done.
                    remote: Total 331 (delta 42), reused 193 (delta 23), pack-reused 0
                    Réception d'objets: 100% (331/331), 676.44 KiB | 1.57 MiB/s, fait.
                    Résolution des deltas: 100% (42/42), fait.
                    Cloning MagicMirror Done!
                    Installing dependencies ...
                    internal/modules/cjs/loader.js:638
                        throw err;
                        ^
                    
                    Error: Cannot find module 'rimraf'
                        at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
                        at Function.Module._load (internal/modules/cjs/loader.js:562:25)
                        at Module.require (internal/modules/cjs/loader.js:692:17)
                        at require (internal/modules/cjs/helpers.js:25:18)
                        at Object.<anonymous> (/usr/lib/node_modules/npm/node_modules/fs-vacuum/vacuum.js:6:14)
                        at Module._compile (internal/modules/cjs/loader.js:778:30)
                        at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
                        at Module.load (internal/modules/cjs/loader.js:653:32)
                        at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
                        at Function.Module._load (internal/modules/cjs/loader.js:585:3)
                    Unable to install dependencies!
                    

                    Any idea please? Honnestly I have spent so much time on this project, all my past weekend and some hours in the week. I tried many things, with several tutorials, raspian stretch, buster… I’m a little desperate, but I’m not giving up!

                    Thanks

                    S Mykle1M 2 Replies Last reply Reply Quote 0
                    • S Offline
                      sdetweil @Neebotol
                      last edited by

                      @Neebotol looks like npm is not able to run after the node upgrade…

                      do this

                      rm -rf MagicMirror
                      npm clean cache
                      

                      then start the installer script again

                      Sam

                      How to add modules

                      learning how to use browser developers window for css changes

                      1 Reply Last reply Reply Quote 0
                      • Mykle1M Offline
                        Mykle1 Project Sponsor Module Developer @Neebotol
                        last edited by

                        @Neebotol said in updated installer script available for testing:

                        I’m a little desperate,

                        We’ve all been there.

                        but I’m not giving up!

                        :thumbsup:

                        Create a working config
                        How to add modules

                        N 1 Reply Last reply Reply Quote 0
                        • 1
                        • 2
                        • 3
                        • 4
                        • 5
                        • 21
                        • 22
                        • 2 / 22
                        • 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