Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. ioBroker Allgemein
    4. Restore funktioniert nicht

    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

    Restore funktioniert nicht

    This topic has been deleted. Only users with topic management privileges can see it.
    • R
      r0b1zZle @simatec last edited by r0b1zZle

      @simatec entpacke ich die tar.gz kommt eine .tar, wenn ich auch diese entpacke kommt ein Ordner "backup" mit einem Unterordner "files" und der "backup.json". In "files" gibt es drei Ordner: "0_userdata.0", "admin.0" und "web.0", die aus Windows-Sicht jedoch alle leer sind.

      @Jan1 simatec hatte mich gefragt, ob ich ihm den Inhalt der tar.gz auflisten könnte. Das wollte ich machen, indem ich dieses Archiv einfach temporär entpacke und mit "ls" den Inhalt schön aufliste. Daher meine Versuche, das zu entpacken.

      Den Backitup-Adapter kannte ich zum Zeitpunkt des Backups noch nicht, daher habe ich das Backup per ssh gemacht. Vorhin habe ich sowohl über den Backitup-Adapter als auch manuell per ssh versucht, das Backup wieder einzuspielen und bei beiden Varianten die gleiche Fehlermeldung erhalten.

      Bevor ich heute den Raspy geplättet habe, konnte ich gestern auch nochmal per Hand exakt das selbe tar File als Backup per ssh auf die noch laufende iobroker Version einspielen (funktionierte wunderbar).

      simatec J 2 Replies Last reply Reply Quote 0
      • simatec
        simatec Developer Most Active @r0b1zZle last edited by

        @r0b1zZle
        Dann lasse mal vorm restore bitte den Installer Fix laufen.
        Danach entweder über Konsole oder Backitup den Restore ausführen. Es gibt hier im Forum ein Howto zum Restore.

        R 1 Reply Last reply Reply Quote 0
        • J
          Jan1 @r0b1zZle last edited by

          @r0b1zZle
          OK, wenn das ein manuell erstelltes Backup ist, weiß ich nicht ob das mit dem Adapter überhaupt zu restoren geht.
          Das entpacken, wie geschrieben, ist unter Windows auch ganz normal möglich und muss nicht unter Linux gemacht werden. Da gings ja nur drum, ob der Inhalt passt und ob es beschädigt ist. Man kann das natürlich auch unter Linux machen, wenn man da aber nicht sicher ist, ist eben Windows einfacher.

          1 Reply Last reply Reply Quote 0
          • R
            r0b1zZle @simatec last edited by r0b1zZle

            @simatec Du meinst das was ich oben als bereits gemacht aufgeführt habe?

            curl -sL https://iobroker.net/fix.sh | bash -
            

            und das howto zum Restore?

            Update:

            pi@raspberrypi4-iob:/opt/iobroker $ sudo apt-get update
            pi@raspberrypi4-iob:/opt/iobroker $ sudo apt-get install redis-server
            pi@raspberrypi4-iob:/opt/iobroker $ sudo usermod -a -G redis iobroker
            pi@raspberrypi4-iob:/opt/iobroker $ sudo reboot now
            pi@raspberrypi4-iob:/opt/iobroker $ iobroker stop
            pi@raspberrypi4-iob:/opt/iobroker $ curl -sL https://iobroker.net/fix.sh | bash -
            library: loaded
            Library version=2020-01-30
            
            ==========================================================================
            
                Welcome to the ioBroker installation fixer!
                Script version: 2020-01-25
            
                You might need to enter your password a couple of times.
            
            ==========================================================================
            
            
            ==========================================================================
                Installing prerequisites (1/3)
            ==========================================================================
            
            OK:1 http://raspbian.raspberrypi.org/raspbian buster InRelease
            OK:2 http://archive.raspberrypi.org/debian buster InRelease
            OK:3 https://deb.nodesource.com/node_10.x buster InRelease
            Paketlisten werden gelesen... Fertig
            Installed gcc-c++
            
            ==========================================================================
                Checking ioBroker user and directory permissions (2/3)
            ==========================================================================
            
            Created /etc/sudoers.d/iobroker
            Fixing directory permissions...
            
            ==========================================================================
                Checking autostart (3/3)
            ==========================================================================
            
            Enabling autostart...
            Autostart enabled!
            
            ==========================================================================
            
                Your installation was fixed successfully
                Run iobroker start to start ioBroker again!
            
            ==========================================================================
            
            pi@raspberrypi4-iob:/opt/iobroker $ sudo apt-get install htop
            Paketlisten werden gelesen... Fertig
            Abhängigkeitsbaum wird aufgebaut.
            Statusinformationen werden eingelesen.... Fertig
            htop ist schon die neueste Version (2.2.0-1).
            0 aktualisiert, 0 neu installiert, 0 zu entfernen und 4 nicht aktualisiert.
            pi@raspberrypi4-iob:/opt/iobroker $ iobroker stop
            pi@raspberrypi4-iob:/opt/iobroker $ iobroker status
            iobroker is not running on this host.
            
            No iobroker host is running.
            
            Objects type: file
            States  type: file
            pi@raspberrypi4-iob:/opt/iobroker $ iobroker restore 2020_02_27-19_30_02_backupiobroker
            host.raspberrypi4-iob Cannot extract from file "/opt/iobroker/node_modules/iobroker.js-controller/lib/setup/../../../../backups/2020_02_27-19_30_02_backupiobroker.tar.gz"
            host.raspberrypi4-iob Cannot find extracted file from file "/opt/iobroker/node_modules/iobroker.js-controller/tmp/backup/backup.json"
            iobroker controller daemon is not running
            host.raspberrypi4-iob OK.
            (node:2349) UnhandledPromiseRejectionWarning: Error: ENOENT: no such file or directory, open '/opt/iobroker/node_modules/iobroker.js-controller/tmp/backup/backup.json'
                at Object.openSync (fs.js:443:3)
                at Object.readFileSync (fs.js:343:35)
                at BackupRestore.restoreAfterStop (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup/setupBackup.js:566:23)
                at Daemon.daemon.on (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup/setupBackup.js:846:22)
                at Daemon.emit (events.js:203:15)
                at Daemon._kill (/opt/iobroker/node_modules/daemonize2/lib/daemonize.js:246:14)
                at Daemon.stop (/opt/iobroker/node_modules/daemonize2/lib/daemonize.js:185:17)
                at tar.extract.err (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup/setupBackup.js:848:20)
            (node:2349) 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(). (rejection id: 1)
            (node:2349) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
            
            
            simatec J 2 Replies Last reply Reply Quote 0
            • R
              r0b1zZle last edited by

              Gibt es irgendwie die Möglichkeit, wenigstens an die Scripte und Blocklys zu kommen?

              1 Reply Last reply Reply Quote 0
              • simatec
                simatec Developer Most Active @r0b1zZle last edited by

                @r0b1zZle
                Lief dein System vorher mit redis? Wenn ja wie genau?
                Object=redis/file=redis?

                Dann muss du zuerst das redis backup wiederherstellen und dann im Anschluss iobroker

                R 1 Reply Last reply Reply Quote 0
                • R
                  r0b1zZle @simatec last edited by

                  @simatec Nein, es lief ohne redis

                  simatec 1 Reply Last reply Reply Quote 0
                  • simatec
                    simatec Developer Most Active @r0b1zZle last edited by

                    @r0b1zZle

                    hmmm warum installierst du dann redis?
                    Mache mal bitte folgendes ...

                    Lege das Backup mal in den Ordner Backups und führe folgendes aus

                    sudo chmod 777 /opt/iobroker/backups/*
                    iobroker restore 0
                    iobroker start
                    
                    R 1 Reply Last reply Reply Quote 0
                    • R
                      r0b1zZle @simatec last edited by r0b1zZle

                      @simatec Weil in der Anleitung folgendes stand:

                      *"Steht in Objects type und/oder States type "redis", müsst ihr zwingend auf dem neuen System den Redis Server installieren.
                      Steht hingehen bei beiden Typen "file", wird der Redis Server nicht benötigt.

                      Solltet ihr keinen Zugriff mehr auf das alte System haben und ihr wisst nicht, was da vorher genau konfiguriert war, dann installiert auf jeden Fall den Redis-Server im Vorfeld."*

                      Das hatte ich auch bereits getestet, gleiches Problem:

                      pi@raspberrypi4-iob:~ $ iobroker stop
                      pi@raspberrypi4-iob:~ $ sudo chmod 777 /opt/iobroker/backups/*
                      pi@raspberrypi4-iob:~ $ iobroker restore 0
                      host.raspberrypi4-iob Using backup file 2020_03_29-14_00_46_backupiobroker.tar.gz
                      host.raspberrypi4-iob Cannot extract from file "/opt/iobroker/node_modules/iobroker.js-controller/lib/setup/../../../../backups/2020_03_29-14_00_46_backupiobroker.tar.gz"
                      host.raspberrypi4-iob Cannot find extracted file from file "/opt/iobroker/node_modules/iobroker.js-controller/tmp/backup/backup.json"
                      iobroker controller daemon is not running
                      host.raspberrypi4-iob OK.
                      (node:7864) UnhandledPromiseRejectionWarning: Error: ENOENT: no such file or directory, open '/opt/iobroker/node_modules/iobroker.js-controller/tmp/backup/backup.json'
                          at Object.openSync (fs.js:443:3)
                          at Object.readFileSync (fs.js:343:35)
                          at BackupRestore.restoreAfterStop (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup/setupBackup.js:566:23)
                          at Daemon.daemon.on (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup/setupBackup.js:846:22)
                          at Daemon.emit (events.js:203:15)
                          at Daemon._kill (/opt/iobroker/node_modules/daemonize2/lib/daemonize.js:246:14)
                          at Daemon.stop (/opt/iobroker/node_modules/daemonize2/lib/daemonize.js:185:17)
                          at tar.extract.err (/opt/iobroker/node_modules/iobroker.js-controller/lib/setup/setupBackup.js:848:20)
                      (node:7864) 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(). (rejection id: 1)
                      (node:7864) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
                      
                      
                      simatec 1 Reply Last reply Reply Quote 0
                      • J
                        Jan1 @r0b1zZle last edited by Jan1

                        @r0b1zZle sagte in Restore funktioniert nicht:

                        Objects type: file
                        States type: file

                        Ja lesen und auch das machen was da steht und bei DIr im LOg steht eben sehr deutlich 2x file 😉

                        R 1 Reply Last reply Reply Quote 0
                        • simatec
                          simatec Developer Most Active @r0b1zZle last edited by

                          @r0b1zZle sagte in Restore funktioniert nicht:

                          @simatec Weil in der Anleitung folgendes stand:
                          "Steht in Objects type und/oder States type "redis", müsst ihr zwingend auf dem neuen System den Redis Server installieren.
                          Steht hingehen bei beiden Typen "file", wird der Redis Server nicht benötigt.
                          Solltet ihr keinen Zugriff mehr auf das alte System haben und ihr wisst nicht, was da vorher genau konfiguriert war, dann installiert auf jeden Fall den Redis-Server im Vorfeld."

                          Du sagtest aber du hast vorher keinen Redis Server gehabt ...
                          Mal ne ganz andere Frage. Wie hast du iobroker installiert?
                          Das sieht nach einem generellen Problem aus, was durch eine falsche Installation auftreten kann.

                          1 Reply Last reply Reply Quote 0
                          • R
                            r0b1zZle @Jan1 last edited by r0b1zZle

                            @Jan1 Ist richtig, das bezieht sich aber auf die aktuelle Installation von Iobroker. Wie gesagt, habe ich den Raspy gestern geplättet und war mir nicht mehr sicher, ob ich redis überhaupt installiert hatte oder nicht (und das habe ich soweit ich weiß, nicht gemacht). In der HowTo stand aber, wenn man sich unsicher ist, auf jeden fall redis trotzdem installieren, was ich gemacht habe.

                            @simatec IoBroker habe ich wie in seinem Video installiert:

                            sudo apt-get update
                            sudo apt-get upgrade
                            sudo raspi-config /* hier den hostname geändert */
                            curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
                            sudo apt-get install -y build-essential libavahi-compat-libdnssd-dev libudev-dev libpam0g-dev nodejs
                            curl -sL https://iobroker.net/install.sh | bash -
                            
                            J simatec 2 Replies Last reply Reply Quote 0
                            • J
                              Jan1 @r0b1zZle last edited by

                              @r0b1zZle
                              Oh je, ne externe Anleitung und hier Support dafür wollen, wenn das Homoran sieht.
                              Oben ist die Doku und die ist aktuell, alles andere kann, muss aber nicht stimmen.

                              1 Reply Last reply Reply Quote 0
                              • simatec
                                simatec Developer Most Active @r0b1zZle last edited by

                                @r0b1zZle sagte in Restore funktioniert nicht:

                                man

                                Dann setze noch mal neu auf und mach folgendes ...
                                Komplett neues Image nehmen .... nicht die jetztige Installation

                                curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
                                sudo apt install -y nodejs
                                sudo reboot now
                                curl -sL https://iobroker.net/install.sh | bash -
                                iobroker stop
                                curl -sL https://iobroker.net/fix.sh | bash -
                                iobroker backup
                                
                                // backup in den Ordner /opt/iobroker/backups legen und die Rechtevergabe kontrollieren
                                iobroker restore Dateiname-Backupdatei
                                iobroker start
                                

                                Alternativ den restore mit backitup ausführen

                                R 1 Reply Last reply Reply Quote 0
                                • R
                                  r0b1zZle @simatec last edited by

                                  @simatec Raspy komplett neu aufgesetzt, ansonsten nichts weiter außer dem, was du geschrieben hast, gleiches Ergebnis:

                                  dietpi@pi:~$ sudo iobroker restore 2020_02_27-19_30_02_backupiobroker.tar.gz
                                  host.pi Cannot extract from file "/opt/iobroker/node_modules/iobroker.js-control ler/lib/setup/../../../../backups/2020_02_27-19_30_02_backupiobroker.tar.gz"
                                  host.pi Cannot find extracted file from file "/opt/iobroker/node_modules/iobroke r.js-controller/tmp/backup/backup.json"
                                  iobroker controller daemon is not running
                                  host.pi OK.
                                  (node:1349) UnhandledPromiseRejectionWarning: Error: ENOENT: no such file or dir ectory, open '/opt/iobroker/node_modules/iobroker.js-controller/tmp/backup/backu p.json'
                                      at Object.openSync (fs.js:443:3)
                                      at Object.readFileSync (fs.js:343:35)
                                      at BackupRestore.restoreAfterStop (/opt/iobroker/node_modules/iobroker.js-co ntroller/lib/setup/setupBackup.js:566:23)
                                      at Daemon.daemon.on (/opt/iobroker/node_modules/iobroker.js-controller/lib/s etup/setupBackup.js:846:22)
                                      at Daemon.emit (events.js:203:15)
                                      at Daemon._kill (/opt/iobroker/node_modules/daemonize2/lib/daemonize.js:246: 14)
                                      at Daemon.stop (/opt/iobroker/node_modules/daemonize2/lib/daemonize.js:185:1 7)
                                      at tar.extract.err (/opt/iobroker/node_modules/iobroker.js-controller/lib/se tup/setupBackup.js:848:20)
                                      at process._tickCallback (internal/process/next_tick.js:68:7)
                                  (node:1349) 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(). (rejection  id: 1)
                                  (node:1349) [DEP0018] DeprecationWarning: Unhandled promise rejections are depre cated. In the future, promise rejections that are not handled will terminate the  Node.js process with a non-zero exit code.
                                  
                                  simatec 2 Replies Last reply Reply Quote 0
                                  • harrym
                                    harrym last edited by

                                    @r0b1zZle sagte in Restore funktioniert nicht:

                                    open '/opt/iobroker/node_modules/iobroker.js-controller/tmp/backup/backu p.json'

                                    ist da echt ein leerzeichen drinnen????? (backu p.json)

                                    R 1 Reply Last reply Reply Quote 0
                                    • simatec
                                      simatec Developer Most Active @r0b1zZle last edited by

                                      @r0b1zZle Mach mal den Restore ohne sudo

                                      1 Reply Last reply Reply Quote 0
                                      • simatec
                                        simatec Developer Most Active @r0b1zZle last edited by

                                        @r0b1zZle sagte in Restore funktioniert nicht:

                                        @simatec Raspy komplett neu aufgesetzt, ansonsten nichts weiter außer dem, was du geschrieben hast, gleiches Ergebnis:

                                        dietpi@pi:~$ sudo iobroker restore 2020_02_27-19_30_02_backupiobroker.tar.gz
                                        host.pi Cannot extract from file "/opt/iobroker/node_modules/iobroker.js-control ler/lib/setup/../../../../backups/2020_02_27-19_30_02_backupiobroker.tar.gz"
                                        host.pi Cannot find extracted file from file "/opt/iobroker/node_modules/iobroke r.js-controller/tmp/backup/backup.json"
                                        iobroker controller daemon is not running
                                        host.pi OK.
                                        (node:1349) UnhandledPromiseRejectionWarning: Error: ENOENT: no such file or dir ectory, open '/opt/iobroker/node_modules/iobroker.js-controller/tmp/backup/backu p.json'
                                            at Object.openSync (fs.js:443:3)
                                            at Object.readFileSync (fs.js:343:35)
                                            at BackupRestore.restoreAfterStop (/opt/iobroker/node_modules/iobroker.js-co ntroller/lib/setup/setupBackup.js:566:23)
                                            at Daemon.daemon.on (/opt/iobroker/node_modules/iobroker.js-controller/lib/s etup/setupBackup.js:846:22)
                                            at Daemon.emit (events.js:203:15)
                                            at Daemon._kill (/opt/iobroker/node_modules/daemonize2/lib/daemonize.js:246: 14)
                                            at Daemon.stop (/opt/iobroker/node_modules/daemonize2/lib/daemonize.js:185:1 7)
                                            at tar.extract.err (/opt/iobroker/node_modules/iobroker.js-controller/lib/se tup/setupBackup.js:848:20)
                                            at process._tickCallback (internal/process/next_tick.js:68:7)
                                        (node:1349) 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(). (rejection  id: 1)
                                        (node:1349) [DEP0018] DeprecationWarning: Unhandled promise rejections are depre cated. In the future, promise rejections that are not handled will terminate the  Node.js process with a non-zero exit code.
                                        

                                        Hast du andere Befehle auch mit sudo ausgeführt? Das hatte ich so nicht geschrieben

                                        1 Reply Last reply Reply Quote 0
                                        • R
                                          r0b1zZle @harrym last edited by r0b1zZle

                                          @harrym nein, das kommt weil ich die Console größer gezogen habe und beim Kopieren jetzt die Zeilenumbrüche nochmal als Leerzeichen gesetzt wurden.

                                          @simatec Nein, nur das backup, weil keine Berechtigung.

                                          dietpi@pi:~$ iobroker restore 2020_02_27-19_30_02_backupiobroker.tar.gz
                                          [sudo] Passwort für dietpi:
                                          Leider darf der Benutzer dietpi »/usr/bin/node /opt/iobroker/node_modules/iobroker.js-controller/iobroker.js restore 2020_02_27-19_30_02_backupiobroker.tar.gz« als iobroker auf pi nicht ausführen.
                                          
                                          

                                          PS: Das neue Backup kann ich ohne Probleme wieder einspielen.

                                          simatec 1 Reply Last reply Reply Quote 0
                                          • simatec
                                            simatec Developer Most Active @r0b1zZle last edited by

                                            @r0b1zZle
                                            Gut dann stimmen deine rechte da definitiv nicht und hast ein ganz anderes Problem ...

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

                                            Support us

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

                                            748
                                            Online

                                            31.9k
                                            Users

                                            80.1k
                                            Topics

                                            1.3m
                                            Posts

                                            17
                                            89
                                            13006
                                            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