2

I've just downloaded and installed the Windows version of InfluxDB v2.2.0. It's up an running, and I can access it via the Web UI. However, I'm unable to connect to it via the command client.

The command client is Influx version CLI 2.3.0 (git: 88ba346) build_date: 2022-04-06T19:30:53Z.

For example, if I run the client like this:

influx

it returns a list of commands:

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

If I run:

influx --org example-org --token mySuP3rS3cr3tT0keN

it returns:

Incorrect Usage. flag provided but not defined: -org

If I run

influx config list

It actually works:

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

But I would like to get into the client to run the InfluxSQL commands.

And ideas?

Jack BeNimble
  • 35,733
  • 41
  • 130
  • 213

1 Answers1

0

Not sure I'm answering your exact question, but one thing to note is that the influx command was changed at >=influx:2.0.0 to be influxd instead.

So anyone running <=influx:1.8.0 will use the influx command, and later will use influxd.

I was following a tutorial that was using v1.8.0, unknowingly, and I installed v2.4.0 using this installation guide using homebrew on a mac. After too long trying workarounds to get the influx command to work, including downgrading to 1.8.0, I then undid all of that and then ran influxd and all was well after that. Hope that helps you or anyone else time traveling to figure out the various startup commands from v1+ to v2+.

Cat Perry
  • 944
  • 1
  • 11
  • 15
  • Thanks for the comment. Actually, the problem was I was expecting a the influx command to bring me into a shell, similar to mysql. I later realized it wasn't a shell, just a way to run influx client commands from a regular command lines. – Jack BeNimble Oct 19 '22 at 20:49