Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Einsteigerfragen
    4. Installation
    5. Troubleshooting NodeJS update

    NEWS

    • ioBroker@Smart Living Forum Solingen, 14.06. - Agenda added

    • ioBroker goes Matter ... Matter Adapter in Stable

    • Monatsrückblick - April 2025

    Troubleshooting NodeJS update

    This topic has been deleted. Only users with topic management privileges can see it.
    • crunchip
      crunchip Forum Testing Most Active @Creatorhs last edited by

      @creatorhs sagte in Troubleshooting NodeJS update:

      Was möchtest du mir dort zeigen?

      da stehn alle Threads( die oberen) zu deinen Problemen

      @creatorhs sagte in Troubleshooting NodeJS update:

      habe mich an die Artikel hier gehalten

      an welche? dann würde ja keine v12 drin stehen

      1 Reply Last reply Reply Quote 0
      • Thomas Braun
        Thomas Braun Most Active @Creatorhs last edited by

        @creatorhs

        Bzgl. nodejs kannst du auch probieren mit der aktuellen Beta vom iob_diag-Skript das gerade ziehen zu lassen.

        Nutzt dir aber nix bei den anderen Dingen, die da bei dir im Argen liegen.

        1 Reply Last reply Reply Quote 0
        • C
          Chu last edited by Chu

          Hallo,

          ich hab eben das Update von nodeJS 14 auf 18 gemacht. Nach dieser Anleitung: https://forum.iobroker.net/topic/64032/update-nodejs-best-practise-supported-16-und-18

          type -P nodejs node npm npx && nodejs -v && node -v && npm -v && npx -v
          /usr/bin/nodejs
          /usr/bin/node
          /usr/bin/npm
          /usr/bin/npx
          v18.17.1
          v18.17.1
          9.6.7
          9.6.7
          

          Jedoch erkennt der ioBroker die Version nicht:
          iobroker_nodeJS.png

          und das update für den Admin Adapter kann ebenfalls nicht durchgeführt werden wegen zu geringer nodeJS Version.

          Hat jemand eine Idee wie ich den ioBroker die neue Version nutzen lasse?

          Danke

          Thomas Braun C 2 Replies Last reply Reply Quote 0
          • Thomas Braun
            Thomas Braun Most Active @Chu last edited by

            @chu sagte in Troubleshooting NodeJS update:

            Hat jemand eine Idee wie ich den ioBroker die neue Version nutzen lasse?

            Starte den neu.

            1 Reply Last reply Reply Quote 0
            • C
              Chu @Chu last edited by

              @chu

              NPM war noch outdated:

              npm install -g npm@9.8.1
              

              danach noch ein reboot und ioBroker hat die aktuelle Version erkannt.

              mcm1957 Thomas Braun 2 Replies Last reply Reply Quote 0
              • mcm1957
                mcm1957 @Chu last edited by mcm1957

                @chu
                Klingt komisch.
                Erstens sollte npm nur mit node zusammen aktualisisert werden (wenn nicht besondere Gründe existieren) und zwitens hängt npm nicht mit der Erkennung der Node version zusammen ...

                Schätze eher dass der Reboot gehoöfen hat.

                Ansonsten - wenns jetzt geht solls recht sein ...

                Thomas Braun 1 Reply Last reply Reply Quote 0
                • Thomas Braun
                  Thomas Braun Most Active @Chu last edited by Thomas Braun

                  @chu

                  Lass die Finger von einer globalen Installation von 'npm'. Das kommt immer in passender Version beim Paket 'nodejs' mit.

                  f80e321a-762e-49a3-bcde-ef6851504306-image.png

                  1 Reply Last reply Reply Quote 0
                  • Thomas Braun
                    Thomas Braun Most Active @mcm1957 last edited by Thomas Braun

                    @mcm57 sagte in Troubleshooting NodeJS update:

                    Schätze eher dass der Reboot gehoöfen hat.

                    Ja.
                    Den iobroker stoppt man ja auch eigentlich, bevor man da die Laufzeitumgebung anpackt. Hier ist das augenscheinlich nicht passiert, sonst würde keine Uptime von 14 Tagen angezeigt.

                    Wäre der 2 Punkt aus der Anleitung gewesen...

                    mcm1957 C 2 Replies Last reply Reply Quote 0
                    • mcm1957
                      mcm1957 @Thomas Braun last edited by

                      @thomas-braun
                      OK - hab ich nicht gesehen.
                      Wundert mich, dass er sich nicht selbst "gestoppt" hat (= gecrashed ist).

                      1 Reply Last reply Reply Quote 0
                      • C
                        Chu @Thomas Braun last edited by

                        @thomas-braun

                        hab die Anleitung befolgt, nur der ioBroker hat es nicht erkannt. alles commands von heute:

                         894  apt-get update
                          895  apt-get upgrade
                          896  reboot
                          897  iob stop
                          898  sudo apt purge --autoremove nodejs* npm node-*
                          899  curl -fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash -
                          900  sudo apt install -y nodejs
                          901  sudo ln -s /usr/bin/node /usr/bin/nodejs &> /dev/null
                          902  type -P nodejs node npm npx && nodejs -v && node -v && npm -v && npx -v
                          903  iob fix
                          904  iob start
                          905  apt-get update
                          906  apt-get dist-upgrade
                          907  reboot
                          908  sudo ln -s /usr/bin/node /usr/bin/nodejs &> /dev/null
                          909  type -P nodejs node npm npx && nodejs -v && node -v && npm -v && npx -v
                          910  env
                          911  npm i iobroker.sma-em
                          912  npm install -g npm@9.8.1
                          913  reboot
                          914  apt-get update
                          915  history
                        
                        

                        Ich hatte bereits (mehrfach, 896 907) neu gestartet, aber nicht gesehen das der ioBroker das nicht erkannt hat und erst nach nach dem update und anschließendem reboot die neue version erkannt hat. solange jetzt alles funktioniert werde ich es erstmal so lassen 😄

                        Thomas Braun 1 Reply Last reply Reply Quote 0
                        • Thomas Braun
                          Thomas Braun Most Active @Chu last edited by

                          @chu

                          iob stop
                          sudo apt update 
                          sudo apt install --reinstall nodejs
                          iob start
                          

                          setzt dich da wieder auf das richtige Gleis.

                          1 Reply Last reply Reply Quote 0
                          • M
                            MatthiasPetersen last edited by Negalein

                            Hi, ich habe nodejs & Co. gemäß der Anleitung https://forum.iobroker.net/topic/64032/update-nodejs-best-practise-supported-16-und-18 aktualisiert und bin jetzt auf den folgenden Versionen unterwegs:

                            /usr/bin/nodejs
                            /usr/bin/node
                            /usr/bin/npm
                            /usr/bin/npx
                            v18.17.1
                            v18.17.1
                            9.6.7
                            9.6.7
                            

                            Nun habe ich ein Update auf die aktuellste Version des Admin-Adapters gemacht und bekomme im Log die Meldung:

                            2023-08-27 12:50:21.214  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]: node:internal/modules/cjs/loader:1080
                            2023-08-27 12:50:21.214  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:   throw err;
                            2023-08-27 12:50:21.214  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:   ^
                            2023-08-27 12:50:21.215  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]: Error: Cannot find module '@iobroker/types'
                            2023-08-27 12:50:21.215  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]: Require stack:
                            2023-08-27 12:50:21.215  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]: - /opt/iobroker/node_modules/iobroker.admin/node_modules/@iobroker/adapter-core/build/index.js
                            2023-08-27 12:50:21.215  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]: - /opt/iobroker/node_modules/iobroker.admin/main.js
                            2023-08-27 12:50:21.215  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at Module._resolveFilename (node:internal/modules/cjs/loader:1077:15)
                            2023-08-27 12:50:21.216  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at Module._load (node:internal/modules/cjs/loader:922:27)
                            2023-08-27 12:50:21.216  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at Module.require (node:internal/modules/cjs/loader:1143:19)
                            2023-08-27 12:50:21.216  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at require (node:internal/modules/cjs/helpers:121:18)
                            2023-08-27 12:50:21.217  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at Object.<anonymous> (/opt/iobroker/node_modules/iobroker.admin/node_modules/@iobroker/adapte$
                            2023-08-27 12:50:21.217  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at Module._compile (node:internal/modules/cjs/loader:1256:14)
                            2023-08-27 12:50:21.217  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
                            2023-08-27 12:50:21.218  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at Module.load (node:internal/modules/cjs/loader:1119:32)
                            2023-08-27 12:50:21.218  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at Module._load (node:internal/modules/cjs/loader:960:12)
                            2023-08-27 12:50:21.218  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     at Module.require (node:internal/modules/cjs/loader:1143:19) {
                            2023-08-27 12:50:21.218  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:   code: 'MODULE_NOT_FOUND',
                            2023-08-27 12:50:21.218  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:   requireStack: [
                            2023-08-27 12:50:21.219  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     '/opt/iobroker/node_modules/iobroker.admin/node_modules/@iobroker/adapter-core/build/index.js',
                            2023-08-27 12:50:21.219  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:     '/opt/iobroker/node_modules/iobroker.admin/main.js'
                            2023-08-27 12:50:21.219  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]:   ]
                            2023-08-27 12:50:21.219  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]: }
                            2023-08-27 12:50:21.219  - ^[[31merror^[[39m: host.iobroker Caught by controller[0]: Node.js v18.17.1
                            

                            auch ein Reboot hat leider keine Verbesserung gebracht.

                            Habt Ihr eine Idee, woran es liegen könnte?

                            Viele Grüße im Voraus
                            Matthias

                            crunchip 1 Reply Last reply Reply Quote 0
                            • crunchip
                              crunchip Forum Testing Most Active @MatthiasPetersen last edited by

                              @matthiaspetersen sagte in Troubleshooting NodeJS update:

                              aktualisiert und bin jetzt auf den folgenden Versionen unterwegs:

                              sicher?

                              M 1 Reply Last reply Reply Quote 0
                              • M
                                MatthiasPetersen @crunchip last edited by

                                @crunchip
                                Wenn Du so fragst ... ich hoffe, dass ich auf den Versionen unterwegs bin. Die Daten kommen gemäß der Anleitung, wenn ich die Befehle

                                sudo ln -s /usr/bin/node /usr/bin/nodejs &> /dev/null
                                type -P nodejs node npm npx && nodejs -v && node -v && npm -v && npx -v

                                absetze. Dass ich auf nodejs 18.17.1 bin steht auch beim Log am Ende der Fehlermeldung.

                                crunchip 1 Reply Last reply Reply Quote 0
                                • crunchip
                                  crunchip Forum Testing Most Active @MatthiasPetersen last edited by

                                  @matthiaspetersen und iobroker war vorher auch gestoppt?
                                  Augabe von

                                  iob diag
                                  
                                  M 1 Reply Last reply Reply Quote 0
                                  • M
                                    MatthiasPetersen @crunchip last edited by

                                    @crunchip Den iobroker hatte ich vorher per iob stop gestoppt.

                                    iob diag sieht bei mir wie folgt aus:

                                    ======================= SUMMARY =======================
                                    		     v.2023-04-16
                                    
                                    
                                    Operatingsystem: 	Raspbian GNU/Linux 10 (buster)
                                    Kernel: 		5.10.103-v7l+
                                    Installation: 		Native
                                    Timezone: 		Europe/Berlin (CEST, +0200)
                                    User-ID: 		1000
                                    X-Server: 		false
                                    Boot Target: 		graphical.target
                                    
                                    Pending OS-Updates: 	0
                                    Pending iob updates: 	4
                                    
                                    Nodejs-Installation: 	/usr/bin/nodejs 	v18.17.1
                                    			/usr/bin/node 		v18.17.1
                                    			/usr/bin/npm 		9.6.7
                                    			/usr/bin/npx 		9.6.7
                                    
                                    Recommended versions are nodejs 18.x.y and npm 9.x.y
                                    Your nodejs installation is correct
                                    
                                    MEMORY: 
                                                  total        used        free      shared  buff/cache   available
                                    Mem:           3.8G        1.2G        1.8G        8.0M        826M        2.5G
                                    Swap:           99M          0B         99M
                                    Total:         3.9G        1.2G        1.9G
                                    
                                    Active iob-Instances: 	28
                                    Active repo(s): stable
                                    
                                    ioBroker Core: 		js-controller 		4.0.24
                                    			admin 			6.8.0
                                    
                                    ioBroker Status: 	iobroker is running on this host.
                                    
                                    
                                    Objects type: jsonl
                                    States  type: redis
                                    
                                    Status admin and web instance:
                                      system.adapter.admin.0                  : admin                 : iobroker                                 -  enabled, port: 8081, bind: 0.0.0.0, run as: admin
                                    + system.adapter.web.0                    : web                   : iobroker                                 -  enabled, port: 8082, bind: 0.0.0.0, run as: admin
                                    
                                    Objects: 		9681
                                    States: 		10090
                                    
                                    Size of iob-Database:
                                    
                                    13M	/opt/iobroker/iobroker-data/objects.jsonl
                                    7.9M	/opt/iobroker/iobroker-data/objects.json.migrated
                                    7.9M	/opt/iobroker/iobroker-data/objects.json.bak.migrated
                                    0	/opt/iobroker/iobroker-data/objects.json.broken
                                    144K	/opt/iobroker/iobroker-data/states.json.bak
                                    144K	/opt/iobroker/iobroker-data/states.json
                                    
                                    
                                    
                                    =================== END OF SUMMARY ====================
                                    

                                    Hilft Dir das Summary oder soll ich lieber den ganzen Report mal schicken?

                                    crunchip 1 Reply Last reply Reply Quote 0
                                    • crunchip
                                      crunchip Forum Testing Most Active @MatthiasPetersen last edited by crunchip

                                      @matthiaspetersen sagte in Troubleshooting NodeJS update:

                                      10 (buster)

                                      du fährst ein altes System
                                      https://forum.iobroker.net/post/667685

                                      M 1 Reply Last reply Reply Quote 0
                                      • M
                                        MatthiasPetersen @crunchip last edited by

                                        @crunchip said in Troubleshooting NodeJS update:

                                        https://forum.iobroker.net/post/667685

                                        @crunchip Ah, danke für den Hinweis. Ich hatte die ganze Zeit ein Problem mit nodejs & Co. vermutet. Ich mache mal dann mal das Update auf Bullseye und führe ich die Schritte von https://forum.iobroker.net/topic/64032/update-nodejs-best-practise-supported-16-und-18 nochmal durch.

                                        Danke Dir

                                        M 1 Reply Last reply Reply Quote 0
                                        • M
                                          MatthiasPetersen @MatthiasPetersen last edited by Negalein

                                          @matthiaspetersen
                                          Ich bin jetzt auf bullseye und habe die Installation von nodejs & Co. nochmal gemacht. Der Fehler ist aber leider der Gleiche.

                                          Hier ist das Ergebnis von iob diag:

                                          ======================= SUMMARY =======================
                                          		     v.2023-04-16
                                          
                                          
                                          Operatingsystem: 	Raspbian GNU/Linux 11 (bullseye)
                                          Kernel: 		5.10.103-v7l+
                                          Installation: 		Native
                                          Timezone: 		Europe/Berlin (CEST, +0200)
                                          User-ID: 		1000
                                          X-Server: 		false
                                          Boot Target: 		graphical.target
                                          
                                          Pending OS-Updates: 	0
                                          Pending iob updates: 	4
                                          
                                          Nodejs-Installation: 	/usr/bin/nodejs 	v18.17.1
                                          			/usr/bin/node 		v18.17.1
                                          			/usr/bin/npm 		9.6.7
                                          			/usr/bin/npx 		9.6.7
                                          
                                          Recommended versions are nodejs 18.x.y and npm 9.x.y
                                          Your nodejs installation is correct
                                          
                                          MEMORY: 
                                                         total        used        free      shared  buff/cache   available
                                          Mem:            3.8G        193M        2.4G        0.0K        1.2G        3.5G
                                          Swap:            99M          0B         99M
                                          Total:          3.9G        193M        2.5G
                                          
                                          Active iob-Instances: 	1
                                          Active repo(s): stable
                                          
                                          ioBroker Core: 		js-controller 		4.0.24
                                          			admin 			6.8.0
                                          
                                          ioBroker Status: 	iobroker is not running on this host.
                                          
                                          
                                          Objects type: jsonl
                                          States  type: redis
                                          
                                          Status admin and web instance:
                                            system.adapter.admin.0                  : admin                 : iobroker                                 -  enabled, port: 8081, bind: 0.0.0.0, run as: admin
                                            system.adapter.web.0                    : web                   : iobroker                                 -  enabled, port: 8082, bind: 0.0.0.0, run as: admin
                                          
                                          Objects: 		9683
                                          States: 		10056
                                          
                                          Size of iob-Database:
                                          
                                          11M	/opt/iobroker/iobroker-data/objects.jsonl
                                          7.9M	/opt/iobroker/iobroker-data/objects.json.migrated
                                          7.9M	/opt/iobroker/iobroker-data/objects.json.bak.migrated
                                          0	/opt/iobroker/iobroker-data/objects.json.broken
                                          144K	/opt/iobroker/iobroker-data/states.json.bak
                                          144K	/opt/iobroker/iobroker-data/states.json
                                          
                                          
                                          
                                          =================== END OF SUMMARY ====================
                                          
                                          crunchip 1 Reply Last reply Reply Quote 0
                                          • crunchip
                                            crunchip Forum Testing Most Active @MatthiasPetersen last edited by

                                            @matthiaspetersen sagte in Troubleshooting NodeJS update:

                                            Der Fehler ist aber leider der Gleiche.

                                            welcher?

                                            M 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post

                                            Support us

                                            ioBroker
                                            Community Adapters
                                            Donate

                                            829
                                            Online

                                            31.7k
                                            Users

                                            79.8k
                                            Topics

                                            1.3m
                                            Posts

                                            nodejs 18 nodejs update
                                            60
                                            504
                                            85005
                                            Loading More Posts
                                            • Oldest to Newest
                                            • Newest to Oldest
                                            • Most Votes
                                            Reply
                                            • Reply as topic
                                            Log in to reply
                                            Community
                                            Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen
                                            The ioBroker Community 2014-2023
                                            logo