Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. ioBroker Allgemein
    4. iob node fix - Skript

    NEWS

    • Neuer Blog: Fotos und Eindrücke aus Solingen

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

    • ioBroker goes Matter ... Matter Adapter in Stable

    iob node fix - Skript

    This topic has been deleted. Only users with topic management privileges can see it.
    • David G.
      David G. @Thomas Braun last edited by

      @thomas-braun

      Bei mir läuft es auch Problemlos

      ioBroker nodejs fixer 2023-09-03
      Recommended nodejs-version is: 18.17.1
      Checking your installation now. Please be patient!
      
      Your current setup is:
      /usr/bin/nodejs         v18.17.1                              /usr/bin/node           v18.17.1
      /usr/bin/npm            9.6.7                                 /usr/bin/npx            9.6.7
      /usr/bin/corepack       0.18.0                                
      I found these versions available:                             nodejs:
        Installed: 18.17.1-deb-1nodesource1
        Candidate: 18.17.1-deb-1nodesource1
        Version table:                                               *** 18.17.1-deb-1nodesource1 500
              500 https://deb.nodesource.com/node_18.x bullseye/main armhf Packages
              100 /var/lib/dpkg/status
           12.22.12~dfsg-1~deb11u4 500
              500 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf Packages
      
      
      
      Nothing to do, your installation seems to be correct
      
      1 Reply Last reply Reply Quote 0
      • F
        fastfoot @fastfoot last edited by

        @fastfoot sagte in iob node fix - Skript:

        Ein paar Dinge hätte ich dazu noch anzumerken

        @Thomas-Braun die haben sich über Nacht wohl aufgelöst 🙂 Aber in Zeile 254 hat sich noch ein Fehler eingeschlichen. Ersetze mal durch:
        if [[ $NODEINSTMAJOR > $NODE_MAJOR || "$NODERECOMNF" = 1 ]]

        die double-braces sind hier wichtig.

        Tolle Arbeit!

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

          @fastfoot sagte in iob node fix - Skript:

          die double-braces sind hier wichtig.

          Die sind auch schon raus. Hab den Code an der Stelle umgestellt.
          Die ist aber im Moment noch der Punkt wo es hakelt...
          Ohne ausgelesenem state aus der iob-Datenbank was die empfohlene Version angeht komme ich da ins Schleudern.

          F 1 Reply Last reply Reply Quote 1
          • F
            fastfoot @Thomas Braun last edited by

            @thomas-braun sagte in iob node fix - Skript:

            Hab den Code an der Stelle umgestellt.

            hat aber nicht funktioniert 🙂 Mach mal wie beschrieben, da kommt kein Fehler mehr

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

              @fastfoot
              Ist doch drin?

              if [[ $NODEINSTMAJOR -gt $NODE_MAJOR || "$NODERECOMNF" -eq 1 ]]
              
              F 1 Reply Last reply Reply Quote 1
              • F
                fastfoot @Thomas Braun last edited by

                @thomas-braun sagte in iob node fix - Skript:

                @fastfoot
                Ist doch drin?

                if [[ $NODEINSTMAJOR -gt $NODE_MAJOR || "$NODERECOMNF" -eq 1 ]]
                

                yep, so schnell kann man gar nicht nachladen 🙂 so funktionieren upgrades als auch downgrades.

                evtl. könnte man noch die Ausgabe von apt policy unterdrücken, die bringt eh nur die verfügbaren versionen der current installation, nicht der recommended

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

                  @fastfoot sagte in iob node fix - Skript:

                  evtl. könnte man noch die Ausgabe von apt policy unterdrücken, die bringt eh nur die verfügbaren versionen der current installation, nicht der recommended

                  Ja, das nehme ich noch raus, dient im Moment noch zum debuggen. Damit ich sehe was da passiert. Die Ausgaben leite ich nach /dev/null, wenn es stabil läuft.

                  E F 3 Replies Last reply Reply Quote 1
                  • E
                    emil70 @Thomas Braun last edited by

                    @thomas-braun

                    Lief auf Docker sauber durch

                    ioBroker nodejs fixer 2023-09-03
                    Recommended nodejs-version is: 18.17.1
                    Checking your installation now. Please be patient!
                    
                    Your current setup is:
                    /usr/bin/nodejs         v18.17.0
                    /usr/bin/node           v18.17.0
                    /usr/bin/npm            9.6.7
                    /usr/bin/npx            9.6.7
                    /usr/bin/corepack       0.18.0
                    
                    I found these versions available:
                    
                    nodejs:
                      Installed: 18.17.0-deb-1nodesource1
                      Candidate: 18.17.1-deb-1nodesource1
                      Version table:
                         18.17.1-deb-1nodesource1 500
                            500 https://deb.nodesource.com/node_18.x bullseye/main amd64 Packages
                     *** 18.17.0-deb-1nodesource1 100
                            100 /var/lib/dpkg/status
                         12.22.12~dfsg-1~deb11u4 500
                            500 http://security.debian.org/debian-security bullseye-security/main amd64 Packages
                         12.22.12~dfsg-1~deb11u3 500
                            500 http://deb.debian.org/debian bullseye/main amd64 Packages
                    
                    
                    
                    Nothing to do, your installation seems to be correct
                    
                    !!! THIS CODE IS IN BETA STAGE. TRY IT AT YOUR OWN RISK !!!
                    
                    You are running nodejs v18.17.0. Do you want to install recommended nodejs v18.17.1?  
                    *** DO NOT TRY THIS FIX ON NON-LINUX-SYSTEMS! ***
                    
                    Press <y> to continue or any other key to quit
                    
                    root@iobroker:/opt/iobroker# 
                    
                    Homoran Thomas Braun 2 Replies Last reply Reply Quote 0
                    • Homoran
                      Homoran Global Moderator Administrators @emil70 last edited by

                      @Thomas-Braun

                      @emil70 sagte in iob node fix - Skript:

                      *** DO NOT TRY THIS FIX ON NON-LINUX-SYSTEMS! ***

                      wäre es nicht besser (zusätzlich) das OS zu Beginn zu prüfen und das Skript mit einer Warnung zu beenden?

                      1 Reply Last reply Reply Quote 1
                      • F
                        fastfoot @Thomas Braun last edited by

                        @thomas-braun $SUDOX rm "$(sudo find / -name nodesource.key)" &> /dev/null;

                        sudo durch $SUDOX ersetzen und Fehler auch nach /dev/null

                        Thomas Braun 1 Reply Last reply Reply Quote 0
                        • E
                          emil70 @Thomas Braun last edited by

                          @thomas-braun

                          update hat auch geklappt

                          ioBroker nodejs fixer 2023-09-03
                          Recommended nodejs-version is: 18.17.1
                          Checking your installation now. Please be patient!
                          
                          Your current setup is:
                          /usr/bin/nodejs         v18.17.0
                          /usr/bin/node           v18.17.0
                          /usr/bin/npm            9.6.7
                          /usr/bin/npx            9.6.7
                          /usr/bin/corepack       0.18.0
                          
                          I found these versions available:
                          
                          nodejs:
                            Installed: 18.17.0-deb-1nodesource1
                            Candidate: 18.17.1-deb-1nodesource1
                            Version table:
                               18.17.1-deb-1nodesource1 500
                                  500 https://deb.nodesource.com/node_18.x bullseye/main amd64 Packages
                           *** 18.17.0-deb-1nodesource1 100
                                  100 /var/lib/dpkg/status
                               12.22.12~dfsg-1~deb11u4 500
                                  500 http://security.debian.org/debian-security bullseye-security/main amd64 Packages
                               12.22.12~dfsg-1~deb11u3 500
                                  500 http://deb.debian.org/debian bullseye/main amd64 Packages
                          
                          
                          
                          Nothing to do, your installation seems to be correct
                          
                          !!! THIS CODE IS IN BETA STAGE. TRY IT AT YOUR OWN RISK !!!
                          
                          You are running nodejs v18.17.0. Do you want to install recommended nodejs v18.17.1?  
                          *** DO NOT TRY THIS FIX ON NON-LINUX-SYSTEMS! ***
                          
                          Press <y> to continue or any other key to quit
                          Trying to fix your installation now. Please be patient.
                          find: '/proc/401/map_files': Permission denied
                          find: '/proc/462/map_files': Permission denied
                          find: '/proc/488/map_files': Permission denied
                          find: '/proc/656/map_files': Permission denied
                          find: '/proc/713/map_files': Permission denied
                          find: '/proc/728/map_files': Permission denied
                          find: '/proc/789/map_files': Permission denied
                          find: '/proc/846/map_files': Permission denied
                          find: '/proc/976/map_files': Permission denied
                          find: '/proc/1094/map_files': Permission denied
                          find: '/proc/1138/map_files': Permission denied
                          find: '/proc/1429/map_files': Permission denied
                          find: '/proc/1496/map_files': Permission denied
                          find: '/proc/1592/map_files': Permission denied
                          find: '/proc/1745/map_files': Permission denied
                          find: '/proc/1944/map_files': Permission denied
                          find: '/proc/2057/map_files': Permission denied
                          find: '/proc/3118/map_files': Permission denied
                          find: '/proc/5214/map_files': Permission denied
                          find: '/proc/7598/map_files': Permission denied
                          find: '/proc/7605/map_files': Permission denied
                          find: '/proc/8786/map_files': Permission denied
                          find: '/proc/13521/map_files': Permission denied
                          find: '/proc/16592/map_files': Permission denied
                          find: '/proc/17200/map_files': Permission denied
                          find: '/proc/19043/map_files': Permission denied
                          find: '/proc/22112/map_files': Permission denied
                          find: '/proc/26681/map_files': Permission denied
                          find: '/proc/26702/map_files': Permission denied
                          find: '/proc/26882/map_files': Permission denied
                          find: '/proc/31575/map_files': Permission denied
                          find: '/proc/401/map_files': Permission denied
                          find: '/proc/462/map_files': Permission denied
                          find: '/proc/488/map_files': Permission denied
                          find: '/proc/656/map_files': Permission denied
                          find: '/proc/713/map_files': Permission denied
                          find: '/proc/728/map_files': Permission denied
                          find: '/proc/789/map_files': Permission denied
                          find: '/proc/846/map_files': Permission denied
                          find: '/proc/976/map_files': Permission denied
                          find: '/proc/1094/map_files': Permission denied
                          find: '/proc/1138/map_files': Permission denied
                          find: '/proc/1429/map_files': Permission denied
                          find: '/proc/1496/map_files': Permission denied
                          find: '/proc/1592/map_files': Permission denied
                          find: '/proc/1745/map_files': Permission denied
                          find: '/proc/1944/map_files': Permission denied
                          find: '/proc/2057/map_files': Permission denied
                          find: '/proc/3118/map_files': Permission denied
                          find: '/proc/5214/map_files': Permission denied
                          find: '/proc/7598/map_files': Permission denied
                          find: '/proc/7605/map_files': Permission denied
                          find: '/proc/8786/map_files': Permission denied
                          find: '/proc/13521/map_files': Permission denied
                          find: '/proc/16592/map_files': Permission denied
                          find: '/proc/17200/map_files': Permission denied
                          find: '/proc/19043/map_files': Permission denied
                          find: '/proc/22112/map_files': Permission denied
                          find: '/proc/26681/map_files': Permission denied
                          find: '/proc/26702/map_files': Permission denied
                          find: '/proc/26882/map_files': Permission denied
                          find: '/proc/31575/map_files': Permission denied
                          
                          iobroker controller daemon is not running
                          Waiting for ioBroker to shut down - Give me a minute...
                          ############################################################
                          Get:1 http://security.debian.org/debian-security bullseye-security InRelease [48.4 kB]
                          Hit:2 http://deb.debian.org/debian bullseye InRelease   
                          Get:3 http://deb.debian.org/debian bullseye-updates InRelease [44.1 kB]
                          Get:4 http://security.debian.org/debian-security bullseye-security/main amd64 Packages [245 kB]
                          Fetched 337 kB in 1s (412 kB/s) 
                          Reading package lists... Done
                          deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_18.x nodistro main
                          Hit:1 http://deb.debian.org/debian bullseye InRelease
                          Hit:2 http://deb.debian.org/debian bullseye-updates InRelease           
                          Hit:3 http://security.debian.org/debian-security bullseye-security InRelease
                          Get:4 https://deb.nodesource.com/node_18.x nodistro InRelease [12.1 kB] 
                          Get:5 https://deb.nodesource.com/node_18.x nodistro/main amd64 Packages [5181 B]
                          Fetched 17.3 kB in 2s (11.1 kB/s) 
                          Reading package lists... Done
                          DEBUG NODEINSTMAJOR: 18 NODEMAJOR:  NODERECOMNF:  
                          *** DEBUG *** Installation ohne spez. Version
                          Reading package lists... Done
                          Building dependency tree... Done
                          Reading state information... Done
                          The following packages will be upgraded:
                            nodejs
                          1 upgraded, 0 newly installed, 0 to remove and 9 not upgraded.
                          Need to get 29.4 MB of archives.
                          After this operation, 7168 B of additional disk space will be used.
                          Get:1 https://deb.nodesource.com/node_18.x nodistro/main amd64 nodejs amd64 18.17.1-1nodesource1 [29.4 MB]
                          Fetched 29.4 MB in 3s (10.7 MB/s) 
                          (Reading database ... 32259 files and directories currently installed.)
                          Preparing to unpack .../nodejs_18.17.1-1nodesource1_amd64.deb ...
                          Detected old npm client, removing...
                          Unpacking nodejs (18.17.1-1nodesource1) over (18.17.0-deb-1nodesource1) ...
                          Setting up nodejs (18.17.1-1nodesource1) ...
                          
                          *** You need to manually restart your container now! *** 
                          
                          We tried our best to fix your nodejs. Please run 'iob diag' again to verify.
                          
                          1 Reply Last reply Reply Quote 0
                          • Thomas Braun
                            Thomas Braun Most Active @emil70 last edited by Thomas Braun

                            @emil70 sagte in iob node fix - Skript:

                            Lief auf Docker sauber durch

                            Auf einem Docker sollte das eigentlich gar nicht laufen.

                            Edit: Man sollte den entsprechenden Code auch aktiv setzen...

                            E 1 Reply Last reply Reply Quote 1
                            • Thomas Braun
                              Thomas Braun Most Active @fastfoot last edited by

                              @fastfoot

                              Ist doch...
                              Line 230:

                              $SUDOX rm "$(sudo find / -name nodesource.key)" &> /dev/null;
                              
                              F 1 Reply Last reply Reply Quote 1
                              • E
                                emil70 @Thomas Braun last edited by emil70

                                @thomas-braun sagte in iob node fix - Skript:

                                Edit: Man sollte den entsprechenden Code auch aktiv setzen...

                                wie meinen??

                                Mit ```
                                systemd-detect-virt 2

                                kann Docker nix anfangen
                                
                                
                                

                                Dadurch wird doch das ausgelöst oder nicht

                                 if [ "$SYSTDDVIRT" != "none" ]; then
                                                                echo "$SYSTDDVIRT";
                                                                #sudo pkill -u iobroker;    #FIX ME! How to shut down iob in LXC without killing the script? 
                                                                                            #Using 'iob stop' in the meantime.  
                                                                iob stop;
                                                        else
                                                                iob stop;
                                                        fi;
                                
                                Thomas Braun 1 Reply Last reply Reply Quote 0
                                • Thomas Braun
                                  Thomas Braun Most Active @emil70 last edited by

                                  @emil70

                                  Dann zieh den Code jetzt nochmal runter.
                                  Sollte jetzt abgebrochen werden.

                                  E 1 Reply Last reply Reply Quote 1
                                  • E
                                    emil70 @Thomas Braun last edited by

                                    @thomas-braun sagte in iob node fix - Skript:

                                    @emil70

                                    Dann zieh den Code jetzt nochmal runter.
                                    Sollte jetzt abgebrochen werden.

                                    root@iobroker:/opt/iobroker# curl https://raw.githubusercontent.com/Grothesk242/iob_diag/main/iob_node_update > iob_node_update
                                      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                                                     Dload  Upload   Total   Spent    Left  Speed
                                    100 10916  100 10916    0     0  50073      0 --:--:-- --:--:-- --:--:-- 50073
                                    root@iobroker:/opt/iobroker# ./iob_node_update
                                    ioBroker node-update v2023-09-03 is starting. Please be patient!
                                    Fixing Docker is not supported, please update your Docker Container
                                    root@iobroker:/opt/iobroker# 
                                    
                                    Thomas Braun 1 Reply Last reply Reply Quote 0
                                    • Thomas Braun
                                      Thomas Braun Most Active @emil70 last edited by

                                      @emil70

                                      Ja, so soll das.

                                      1 Reply Last reply Reply Quote 1
                                      • Homoran
                                        Homoran Global Moderator Administrators last edited by Homoran

                                        @Thomas-Braun

                                        Was soll das denn sein

                                        root@iobroker:/opt/iobroker# curl https://raw.githubusercontent.com/Grothesk242/iob_diag/main/iob_node_update > iob_node_update
                                        
                                          % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                                                         Dload  Upload   Total   Spent    Left  Speed
                                        100 10916  100 10916    0     0  50073      0 --:--:-- --:--:-- --:--:-- 50073
                                        
                                        root@iobroker:/opt/iobroker# ./iob_node_update
                                        ioBroker node-update v2023-09-03 is starting. Please be patient!
                                        Fixing Docker is not supported, please update your Docker Container
                                        root@iobroker:/opt/iobroker# 
                                        

                                        Das ist doch keine GUI.
                                        Da musst du noch mal ran 😂

                                        E Thomas Braun 2 Replies Last reply Reply Quote 1
                                        • E
                                          emil70 @Homoran last edited by

                                          @homoran sagte in iob node fix - Skript:

                                          @Thomas-Braun
                                          Das ist doch keine GUI.
                                          Da musst du noch mal ran 😂

                                          Verstehe ich gerade nicht

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

                                            @homoran
                                            ncurses kommt noch...
                                            Erstmal muss der Code noch rundgelutscht werden.
                                            Sollte aber Stand 'gerade jetzt' funktionieren. Werden halt noch ein paar Meldungen ausgespuckt, aber die kann man unterdrücken.

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

                                            Support us

                                            ioBroker
                                            Community Adapters
                                            Donate
                                            FAQ Cloud / IOT
                                            HowTo: Node.js-Update
                                            HowTo: Backup/Restore
                                            Downloads
                                            BLOG

                                            867
                                            Online

                                            31.7k
                                            Users

                                            79.8k
                                            Topics

                                            1.3m
                                            Posts

                                            34
                                            198
                                            25989
                                            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