【问题标题】:Unable to connect to Influx DB Client无法连接到 Influxdb 客户端
【发布时间】:2022-10-20 04:46:18
【问题描述】:

我刚刚下载并安装了InfluxDB v2.2.0 的Windows 版本。它正在运行,我可以通过 Web UI 访问它。但是,我无法通过命令客户端连接到它。

命令客户端为 Influx 版本CLI 2.3.0 (git: 88ba346) build_date: 2022-04-06T19:30:53Z.

例如,如果我这样运行客户端:

influx

它返回一个命令列表:

NAME:
   influx - Influx Client

USAGE:
   influx [command]

COMMANDS:
   version              Print the influx CLI version
   write                Write points to InfluxDB
   bucket               Bucket management commands
   completion           Generates completion scripts
   query                Execute a Flux query
   config               Config management commands
   org, organization    Organization management commands
   delete               Delete points from InfluxDB
   user                 User management commands
   task                 Task management commands
   telegrafs            List Telegraf configuration(s). Subcommands manage Telegraf configurations.
   dashboards           List Dashboard(s).
   export               Export existing resources as a template
   secret               Secret management commands
   v1                   InfluxDB v1 management commands
   auth, authorization  Authorization management commands
   apply                Apply a template to manage resources
   stacks               List stack(s) and associated templates. Subcommands manage stacks.
   template             Summarize the provided template
   bucket-schema        Bucket schema management commands
   ping                 Check the InfluxDB /health endpoint
   setup                Setup instance with initial user, org, bucket
   backup               Backup database
   restore              Restores a backup directory to InfluxDB
   remote               Remote connection management commands
   replication          Replication stream management commands
   server-config        Display server config
   help, h              Shows a list of commands or help for one command

GLOBAL OPTIONS:
   --help, -h  show help

如果我运行:

influx --org example-org --token mySuP3rS3cr3tT0keN

它返回:

Incorrect Usage. flag provided but not defined: -org

如果我跑

influx config list

它实际上有效:

Active  Name    URL                     Org
*       default http://localhost:8086   example-org

但我想进入客户端运行 InfluxSQL 命令。

和想法?

【问题讨论】:

    标签: influxdb-2


    【解决方案1】:

    不确定我是否在回答您的确切问题,但需要注意的一点是 influx 命令在 >=influx:2.0.0 处更改为 influxd

    所以运行 <=influx:1.8.0 的任何人都将使用influx 命令,稍后将使用influxd

    我在不知不觉中遵循了一个使用 v1.8.0 的教程,并在 Mac 上使用自制软件使用 this installation guide 安装了 v2.4.0。经过太长时间尝试变通办法让influx 命令工作,包括降级到1.8.0,然后我撤消了所有这些,然后运行influxd,之后一切都很好。希望能帮助您或其他任何人花时间找出从 v1+ 到 v2+ 的各种启动命令。

    【讨论】:

      猜你喜欢
      • 2013-06-06
      • 2011-09-19
      • 1970-01-01
      • 2016-12-08
      • 2015-08-19
      • 1970-01-01
      • 1970-01-01
      • 2013-02-14
      • 1970-01-01
      相关资源
      最近更新 更多