Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. ioBroker Allgemein
    4. Nach Absturz keine Verbindung mehr REDIS PROBLEM [gelöst]

    NEWS

    • Neues Video über Aliase, virtuelle Geräte und Kategorien

    • Wir empfehlen: Node.js 22.x

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    Nach Absturz keine Verbindung mehr REDIS PROBLEM [gelöst]

    This topic has been deleted. Only users with topic management privileges can see it.
    • Homoran
      Homoran Global Moderator Administrators @Glasfaser last edited by

      @glasfaser sagte in Nach Absturz keine Verbindung mehr zum Admin REDIS PROBLEM:

      gemacht , sehe ich nicht

      zeile 1 - sieht aber komisch aus

      1 Reply Last reply Reply Quote 0
      • M
        meicker @Glasfaser last edited by

        @glasfaser sagte in Nach Absturz keine Verbindung mehr zum Admin REDIS PROBLEM:

        sudo systemctl enable redis-server

        in Zeile 1 wqeiter oben im code

        Glasfaser 1 Reply Last reply Reply Quote 0
        • Glasfaser
          Glasfaser @meicker last edited by

          @meicker

          Habe oben Edit gemacht ... mache die Befehle

          1 Reply Last reply Reply Quote 0
          • M
            meicker @Glasfaser last edited by

            @glasfaser sagte in Nach Absturz keine Verbindung mehr zum Admin REDIS PROBLEM:

            sudo systemctl enable redis-server

            marc@ioBroker:~$ sudo systemctl enable redis-server
            [sudo] Passwort für marc: 
            Synchronizing state of redis-server.service with SysV service script with /lib/systemd/systemd-sysv-install.
            Executing: /lib/systemd/systemd-sysv-install enable redis-server
            marc@ioBroker:~$ iobroker status
            No connection to states 127.0.0.1:6379[redis]
            
            1 Reply Last reply Reply Quote 0
            • Glasfaser
              Glasfaser @meicker last edited by

              @meicker sagte in Nach Absturz keine Verbindung mehr zum Admin REDIS PROBLEM:

              Dez 04 14:59:47 ioBroker systemd[1]: Failed to start Advanced key-value store.

              Ist ioBroker in einer VM installiert !?

              https://forum.iobroker.net/topic/18835/auf-redis-umstellen/82?_=1638625607365

              M 1 Reply Last reply Reply Quote 0
              • M
                meicker @Glasfaser last edited by

                @glasfaser

                marc@ioBroker:~$ iobroker stop
                marc@ioBroker:~$ iobroker host this
                No connection to states 127.0.0.1:6379[redis]
                marc@ioBroker:~$ iobroker start
                marc@ioBroker:~$ iobroker status
                No connection to states 127.0.0.1:6379[redis]
                marc@ioBroker:~$ 
                
                1 Reply Last reply Reply Quote 0
                • M
                  meicker @Glasfaser last edited by

                  @glasfaser sagte in Nach Absturz keine Verbindung mehr zum Admin REDIS PROBLEM:

                  Ist ioBroker in einer VM installiert !?

                  nein

                  1 Reply Last reply Reply Quote 0
                  • M
                    meicker last edited by

                    Hat bis zum Absturz einwandfrei funktioniert ... läuft auf einem Tinker Board ...

                    Meister Mopper 1 Reply Last reply Reply Quote 0
                    • Meister Mopper
                      Meister Mopper @meicker last edited by

                      @meicker
                      Hast Du schon mal in den redis-server logfiles gesucht? Die liegen vermutlich in
                      /var/log/redis

                      M 1 Reply Last reply Reply Quote 0
                      • M
                        meicker @Meister Mopper last edited by

                        @meister-mopper
                        da darf ich als 'user' nicht rein. Aber mit root ...

                        4666:C 04 Dec 2021 15:00:18.887 # WARNING supervised by systemd - you MUST set appropriate values for TimeoutStartSec and TimeoutStopSec in your service unit.
                        4666:C 04 Dec 2021 15:00:18.888 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
                        4666:C 04 Dec 2021 15:00:18.888 # Redis version=6.0.15, bits=32, commit=00000000, modified=0, pid=4666, just started
                        4666:C 04 Dec 2021 15:00:18.888 # Configuration loaded
                        4666:M 04 Dec 2021 15:00:18.890 # Warning: 32 bit instance detected but no memory limit set. Setting 3 GB maxmemory limit with 'noeviction' policy now.
                                        _._                                                  
                                   _.-``__ ''-._                                             
                              _.-``    `.  `_.  ''-._           Redis 6.0.15 (00000000/0) 32 bit
                          .-`` .-```.  ```\/    _.,_ ''-._                                   
                         (    '      ,       .-`  | `,    )     Running in standalone mode
                         |`-._`-...-` __...-.``-._|'` _.-'|     Port: 6379
                         |    `-._   `._    /     _.-'    |     PID: 4666
                          `-._    `-._  `-./  _.-'    _.-'                                   
                         |`-._`-._    `-.__.-'    _.-'_.-'|                                  
                         |    `-._`-._        _.-'_.-'    |           http://redis.io        
                          `-._    `-._`-.__.-'_.-'    _.-'                                   
                         |`-._`-._    `-.__.-'    _.-'_.-'|                                  
                         |    `-._`-._        _.-'_.-'    |                                  
                          `-._    `-._`-.__.-'_.-'    _.-'                                   
                              `-._    `-.__.-'    _.-'                                       
                                  `-._        _.-'                                           
                                      `-.__.-'                                               
                        
                        4666:M 04 Dec 2021 15:00:18.892 # Server initialized
                        4666:M 04 Dec 2021 15:00:18.892 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
                        4666:M 04 Dec 2021 15:00:18.892 # Wrong signature trying to load DB from file
                        4666:M 04 Dec 2021 15:00:18.892 # Fatal error loading the DB: Invalid argument. Exiting.
                        4681:C 04 Dec 2021 15:00:19.278 # WARNING supervised by systemd - you MUST set appropriate values for TimeoutStartSec and TimeoutStopSec in your service unit.
                        4681:C 04 Dec 2021 15:00:19.278 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
                        4681:C 04 Dec 2021 15:00:19.278 # Redis version=6.0.15, bits=32, commit=00000000, modified=0, pid=4681, just started
                        4681:C 04 Dec 2021 15:00:19.278 # Configuration loaded
                        4681:M 04 Dec 2021 15:00:19.281 # Warning: 32 bit instance detected but no memory limit set. Setting 3 GB maxmemory limit with 'noeviction' policy now.
                        

                        im zweiten Block Zeiole 2 und 3 kommt was ...

                        Meister Mopper Thomas Braun 2 Replies Last reply Reply Quote 0
                        • Meister Mopper
                          Meister Mopper @meicker last edited by

                          @meicker

                          Wie sieht denn Deine Arbeitsspeicherlandschaft aus? htop

                          Und hast Du Redis Backup (Persistenz) konfiguriert?

                          M 2 Replies Last reply Reply Quote 0
                          • M
                            meicker last edited by

                            Ich habe jetzt mal folgendes gemacht: setup custom - wieder auf File gesetzt. iobroker Status sieht dann gut aus und iobroker ist auch erreichbar.
                            Dann habe ich noch ein Update gemacht was ebenfalls anstand: iob update / und upgrade self ... Dann neu gestartet.

                            Dann habe ich versucht wieder redis einzuschalten für die states. Sieht zunächst auch gut aus aber wenn es daran geht sich mit der Datenbank zu verbinen schlägt das fehl ...

                            marc@ioBroker:~$ iob stop
                            marc@ioBroker:~$ iobroker setup custom
                            Current configuration:
                            - Objects database:
                              - Type: file
                              - Host/Unix Socket: 127.0.0.1
                              - Port: 9001
                            - States database:
                              - Type: file
                              - Host/Unix Socket: 127.0.0.1
                              - Port: 9000
                            - Data Directory: ../../iobroker-data/
                            
                            Type of objects DB [(f)ile, (r)edis, ...], default [file]: 
                            Host / Unix Socket of objects DB(file), default[127.0.0.1]: 
                            Port of objects DB(file), default[9001]: 
                            Type of states DB [(f)file, (r)edis, ...], default [file]: r
                            
                            When States are stored in a Redis database please make sure to configure Redis
                            persistence to make sure a Redis problem will not cause data loss!
                            
                            Host / Unix Socket of states DB (redis), default[127.0.0.1]: 
                            Port of states DB (redis), default[6379]: 
                            Data directory (file), default[../../iobroker-data/]: 
                            Host name of this machine [ioBroker]: 
                            This host appears to be a Master or a Single host system. Is this correct? [Y/n]: Y
                            
                            Do you want to migrate objects and states from "file/file" to "file/redis" [y/N]: y
                            Connecting to previous DB "file"...
                            Creating backup ...
                            This can take some time ... please be patient!
                            host.ioBroker 11855 states saved
                            host.ioBroker 30778 objects saved
                            Backup created: /opt/iobroker/backups/2021_12_04-17_39_34_backupiobroker-migration.tar.gz
                            updating conf/iobroker.json
                            
                            Connecting to new DB "file" (can take up to 20s) ...
                            No connection to states 127.0.0.1:6379[redis]
                            
                            New Database could not be connected. Please check your settings. No settings have been changed.
                            restoring conf/iobroker.json
                            
                            1 Reply Last reply Reply Quote 0
                            • M
                              meicker @Meister Mopper last edited by

                              @meister-mopper sagte in Nach Absturz keine Verbindung mehr zum Admin REDIS PROBLEM:

                              Wie sieht denn Deine Arbeitsspeicherlandschaft aus? htop

                              7762fffd-4475-4f88-9727-6f9aed1d278d-grafik.png

                              1 Reply Last reply Reply Quote 0
                              • M
                                meicker @Meister Mopper last edited by

                                @meister-mopper sagte in Nach Absturz keine Verbindung mehr zum Admin REDIS PROBLEM:

                                Und hast Du Redis Backup (Persistenz) konfiguriert?

                                ich denke nicht ... kommt mir unbekannt vor - wie prüfen oder machen ?

                                Meister Mopper 1 Reply Last reply Reply Quote 0
                                • Meister Mopper
                                  Meister Mopper @meicker last edited by

                                  @meicker

                                  Schau mal hier.

                                  1 Reply Last reply Reply Quote 0
                                  • M
                                    meicker last edited by

                                    Eine Sicherung zurückspielen vom 3.12 oder 12.2 wo noch alles OK war wird wahrscheinlich nicht helfen weil ja die Verbindung zur DB nicht funktioniert. Die Daten als solches haben damit ja wahrscheinlich nichts zu tun.
                                    Mir ist aber bei upgrade self noch was aufgefallen, da kam eine Fehlermeldung:

                                    marc@ioBroker:~$ iob upgrade self
                                    Update js-controller from @3.3.19 to @3.3.21
                                    NPM version: 6.14.15
                                    npm install iobroker.js-controller@3.3.21 --loglevel error --unsafe-perm --prefix "/opt/iobroker" (System call)
                                    Server Cannot move /opt/iobroker/iobroker-data/objects.json.new to /opt/iobroker/iobroker-data/objects.json: ENOENT: no such file or directory, stat '/opt/iobroker/iobroker-data/objects.json.new'. Try direct write as fallback
                                    
                                    
                                    Meister Mopper 1 Reply Last reply Reply Quote 0
                                    • Meister Mopper
                                      Meister Mopper @meicker last edited by

                                      @meicker

                                      Die Fehlermeldung sagt mir nichts, aber hast Du denn überhaupt redis-backups?
                                      Du musst ja die states/objects zurückspielen können, sonst sind sie perdu.

                                      M 1 Reply Last reply Reply Quote 0
                                      • M
                                        meicker @Meister Mopper last edited by

                                        @meister-mopper
                                        klar mache ich backups ... zurückspielen wäre kein Problem, aber da es ja scheinbar ein Paroblem mit der Datenbankverbindung gibt wird das wenig Sinn machen ... denke ich ...

                                        Meister Mopper 1 Reply Last reply Reply Quote 0
                                        • M
                                          meicker last edited by

                                          oder ich lasse das mit redis einfach und bleibe bei file 😞 Aber es muss doch eigentlich ne Lösung geben dafür ... redis-server deinstallieren und neu installierten ? Vielleicht ist beim Crash was kaputt gegangen.

                                          1 Reply Last reply Reply Quote 0
                                          • Meister Mopper
                                            Meister Mopper @meicker last edited by Meister Mopper

                                            @meicker sagte in Nach Absturz keine Verbindung mehr zum Admin REDIS PROBLEM:

                                            klar mache ich backups ...

                                            Na dann, die Daten liegen in /var/lib/redis/dump.rdb, aber davon läuft der redis-server noch immer nicht.
                                            Ich würde jetzt redis purgen und neu einrichten.

                                            M 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

                                            439
                                            Online

                                            32.1k
                                            Users

                                            80.6k
                                            Topics

                                            1.3m
                                            Posts

                                            5
                                            63
                                            5747
                                            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