Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Off Topic
    4. Proxmox
    5. Proxmox / Influxdb V1 zu V2... wie?

    NEWS

    • Monatsrückblick - April 2025

    • Minor js-controller 7.0.7 Update in latest repo

    • Save The Date: ioBroker@Smart Living Forum Solingen, 14.06.

    Proxmox / Influxdb V1 zu V2... wie?

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

      @da_woody sagte in Proxmox / Influxdb V1 zu V2... wie?:

      aber ich fummel halt nicht mit docker rum

      ich auch nicht mehr.
      Influx war das letzte Teil im Docker.
      Komm ja nichtmal zur influxdb.cfg
      Geht zwar mit cd /etc/ usw.
      Aber keine .cfg auffindbar.

      Deshalb weg damit und mit V2 neu beginnen.

      Denke Influx mit der Wetterstation ist nur für das Statistik-Script und Grafana nötig.
      Awekas funktioniert auch ohne Influx. Oder @SBorg ?

      MassiveAttack SBorg 2 Replies Last reply Reply Quote 0
      • MassiveAttack
        MassiveAttack @Negalein last edited by MassiveAttack

        @negalein

        Habe jetzt mal die v2 als container am laufen. IoBroker hat Verbindung zur DB, ich kann Daten speichern, und auch in Grafana anzeigen.

        Aber leider nur mittels "flux". Geht das nur so, oder kann man bei datasources in Grafana noch was einstellen, damit es auch mit InfluxQl funktioniert?

        EDIT:
        grad selber (leider) die Antwort gefunden:

        Neuer Container mit Influx v2 + neues Bucket = Grafana mit InfluxQL kann die Datenbank nicht finden, da es diese nicht gibt; man muss Flux nutzen

        Alter Container mit Influx v1 + Upgrade auf v2 + neues Bucket + Mapping von Datenbank auf Bucket = Grafana mit InfluxQL würde die Datenbank bzw. Bucket finden; mann kann Flux und InfluxQL nutzen

        Negalein Marc Berg 2 Replies Last reply Reply Quote 0
        • Negalein
          Negalein Global Moderator @MassiveAttack last edited by

          @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

          Aber leider nur mittels "flux". Geht das nur so, oder kann man bei datasources in Grafana noch was einstellen, damit es auch mit InfluxQl funktioniert?

          den Unterschied hab ich noch nicht gecheckt.
          Anscheinend ist Flux das neue und bessere.
          Was aber wirklich der Unterschied ist, kann ich nicht sagen.

          1 Reply Last reply Reply Quote 0
          • Marc Berg
            Marc Berg Most Active @MassiveAttack last edited by Marc Berg

            @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

            Neuer Container mit Influx v2 + neues Bucket = Grafana mit InfluxQL kann die Datenbank nicht finden, da es diese nicht gibt; man muss Flux nutzen

            Du musst nicht zwingend Flux nutzen, es gibt eine V1 API, die angesprochen werden kann:

            https://forum.iobroker.net/topic/62511/fragen-zur-influxdb/11?_=1675682795050


            a259e4f3-4ef3-4d6b-82da-e7f2cf5a5688-grafik.png

            68e6a32e-1f28-4668-9366-916de0e360e5-grafik.png

            MassiveAttack 1 Reply Last reply Reply Quote 0
            • MassiveAttack
              MassiveAttack @Marc Berg last edited by

              @marc-berg

              Ich habe aber nicht upgegraded, sondern v2 neu installiert. Kann aktuell im webinterface nichts von einer v1 api finden.

              1 Reply Last reply Reply Quote 0
              • Marc Berg
                Marc Berg Most Active last edited by

                @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

                Ich habe aber nicht upgegraded, sondern v2 neu installiert. Kann aktuell im webinterface nichts von einer v1 api finden.

                Es ist völlig egal, ob man neu installiert hat oder geupdatet. Fakt ist, dass man parallel die InfluxDB2 sowohl mit Flux als auch InfluxQL abfragen kann, wenn man die Mappings erstellt, wie in meinem Link beschrieben.

                MassiveAttack 1 Reply Last reply Reply Quote 0
                • MassiveAttack
                  MassiveAttack @Marc Berg last edited by MassiveAttack

                  @marc-berg

                  check ich leider nicht. Beim ersten Schritt bekomme ich schon einen Fehler:

                  Mapping V1 DB --> V2 Bucket:

                  influx v1 auth create --read-bucket <ID des Buckets> --username grafana
                  influx v1 dbrp create --db <DB Name> --rp autogen --bucket-id <ID des Buckets>  --default
                  

                  error: must specify org ID or org name

                  MassiveAttack 1 Reply Last reply Reply Quote 0
                  • MassiveAttack
                    MassiveAttack @MassiveAttack last edited by

                    @massiveattack

                    ok, --org-id hinzugefügt, scheint zu passen, bekomme aber jetzt "401 unauthorized"

                    Marc Berg 1 Reply Last reply Reply Quote 0
                    • Marc Berg
                      Marc Berg Most Active @MassiveAttack last edited by

                      @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

                      @massiveattack

                      ok, --org-id hinzugefügt, scheint zu passen, bekomme aber jetzt "401 unauthorized"

                      wo genau? Zeig' mal

                      MassiveAttack 1 Reply Last reply Reply Quote 0
                      • MassiveAttack
                        MassiveAttack @Marc Berg last edited by MassiveAttack

                        @marc-berg

                        root@d838f40c3dd2:/# influx v1 auth create --org-id universe --read-bucket 51f77c18f32e8b3d --username grafana
                        Error: failed to verify username "grafana" has no auth: 401 Unauthorized: unauthorized access
                        

                        funkt auch mit meinem admin user nicht

                        Marc Berg 2 Replies Last reply Reply Quote 0
                        • Marc Berg
                          Marc Berg Most Active @MassiveAttack last edited by Marc Berg

                          @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

                          funkt auch mit meinem admin user nicht

                          Hm, schwer zu sagen, bei mir läuft das ohne Probleme durch

                          65286c4a-9b1f-429b-8bc4-9986aa3227ff-grafik.png

                          1 Reply Last reply Reply Quote 0
                          • Marc Berg
                            Marc Berg Most Active @MassiveAttack last edited by

                            @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

                            @marc-berg

                            funkt auch mit meinem admin user nicht

                            Es sieht so aus, als ob bei Dir in der InfluxDB kein "default" Profil hinterlegt ist, deshalb fragt der Befehl bei Dir auch nach einer Org. Dann müsstest Du auch den Token mitgeben.

                            influx v1 auth create --org-id universe --read-bucket 51f77c18f32e8b3d --username grafana -t <TOKEN>
                            

                            Was sagt?

                            influx config list 
                            
                            MassiveAttack 1 Reply Last reply Reply Quote 0
                            • MassiveAttack
                              MassiveAttack @Marc Berg last edited by MassiveAttack

                              @marc-berg
                              wir sind einen Schritt weiter 🙂

                              Error: failed to create new authorization: 400 Bad Request: invalid json structure: id must have a length of 16 bytes
                              
                              root@d838f40c3dd2:/# influx config list
                              Active  Name    URL     Org
                              
                              Marc Berg 2 Replies Last reply Reply Quote 0
                              • Marc Berg
                                Marc Berg Most Active @MassiveAttack last edited by

                                @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

                                root@d838f40c3dd2:/# influx config list
                                Active  Name    URL     Org
                                

                                Hm, kein Profil angelegt, was eigentlich beim Setup gemacht wird. Wenn Du noch keine Daten drin hast, könntest Du mal gefahrlos

                                influx setup
                                

                                ausführen.

                                MassiveAttack 1 Reply Last reply Reply Quote 0
                                • MassiveAttack
                                  MassiveAttack @Marc Berg last edited by

                                  @marc-berg

                                  root@d838f40c3dd2:/# influx setup
                                  Error: instance has already been set up
                                  
                                  1 Reply Last reply Reply Quote 0
                                  • Marc Berg
                                    Marc Berg Most Active @MassiveAttack last edited by

                                    @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

                                    Error: failed to create new authorization: 400 Bad Request: invalid json structure: id must have a length of 16 bytes
                                    

                                    Welcher Befehl führt zu diesem Fehler?

                                    MassiveAttack 1 Reply Last reply Reply Quote 0
                                    • MassiveAttack
                                      MassiveAttack @Marc Berg last edited by MassiveAttack

                                      @marc-berg

                                      nachdem ich den token hinzugefügt habe, musste ich 2x ein PW eingeben, danach kam diese Meldung

                                      root@d838f40c3dd2:/# influx v1 auth create --org-id universe --read-bucket 51f77c18f32e8b3d --username grafana -t iuLUDd54DwIKgUl8gfJwjU92shXM8Gp1EML7bNoapea7E-bQG26LGxxZfV98i06P5U4qLGQYCHdA4K32JA1BEA==
                                      ? Please type your password **********
                                      ? Please type your password again **********
                                      Error: failed to create new authorization: 400 Bad Request: invalid json structure: id must have a length of 16 bytes
                                      
                                      Marc Berg 1 Reply Last reply Reply Quote 0
                                      • Marc Berg
                                        Marc Berg Most Active @MassiveAttack last edited by Marc Berg

                                        @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

                                        @marc-berg

                                        nachdem ich den token hinzugefügt habe, musste ich 2x ein PW eingeben, danach kam diese Meldung

                                        root@d838f40c3dd2:/# influx v1 auth create --org-id universe --read-bucket 51f77c18f32e8b3d --username grafana -t iuLUDd54DwIKgUl8gfJwjU92shXM8Gp1EML7bNoapea7E-bQG26LGxxZfV98i06P5U4qLGQYCHdA4K32JA1BEA==
                                        ? Please type your password **********
                                        ? Please type your password again **********
                                        Error: failed to create new authorization: 400 Bad Request: invalid json structure: id must have a length of 16 bytes
                                        

                                        Wenn Du die Option "--org-id" angibst, erwartet er eine ID und keinen Namen, ansonsten "--org" nutzen.

                                        MassiveAttack 1 Reply Last reply Reply Quote 0
                                        • MassiveAttack
                                          MassiveAttack @Marc Berg last edited by

                                          @marc-berg

                                          jo, da hast du wohl recht 🙂

                                          das ging mal durch

                                          ID                      Description     Username        v2 User Name    v2 User ID              Permissions
                                          0ab5bb263263b000                        grafana         Jochen          0ab57e1742211000        [read:orgs/bcc1c2a945a2c408/buckets/51f77c18f32e8b3d]
                                          

                                          beim nächste Schritt hatte ich wieder ein Berechtigungsproblem, mit dem token gings wieder:

                                          root@d838f40c3dd2:/# influx v1 dbrp create --org-id bcc1c2a945a2c408 --db iobroker --rp autogen --bucket-id 51f77c18f32e8b3d --default -t KUArezBLNDbZWty0PcwTbD0rme4qIR2JZ0sffRAU8mcT2eXMB12jp6-aTRiH0Gtw0UsY4aEr1U3JXMiYWFTlWg==
                                          ID                      Database        Bucket ID               Retention Policy        Default Organization ID
                                          0ab5bc988fa3b000        iobroker        51f77c18f32e8b3d        autogen                 true    bcc1c2a945a2c408
                                          

                                          und jetzt funktioniert influxql?

                                          Marc Berg 1 Reply Last reply Reply Quote 0
                                          • Marc Berg
                                            Marc Berg Most Active @MassiveAttack last edited by Marc Berg

                                            @massiveattack sagte in Proxmox / Influxdb V1 zu V2... wie?:

                                            und jetzt funktioniert influxql?

                                            Jetzt noch einen dedizierten API-Key anlegen und dann eine Grafana-Datenquelle wie in meinen Screenshots.

                                            Wichtig ist der Custom HTTP Header "Authorization" mit dem Inhalt "Token <API Token>", also mit dem Wort "Token" vor dem Token...

                                            Also z.B. "Token 1234ab......cdef=="

                                            MassiveAttack Negalein 2 Replies Last reply Reply Quote 0
                                            • First post
                                              Last post

                                            Support us

                                            ioBroker
                                            Community Adapters
                                            Donate

                                            538
                                            Online

                                            31.6k
                                            Users

                                            79.4k
                                            Topics

                                            1.3m
                                            Posts

                                            20
                                            221
                                            22842
                                            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