InfluxDB2/Configuration

From r00tedvw.com wiki
(Difference between revisions)
Jump to: navigation, search
(Created page with "Installation | Configuration")
 
(Modifications)
 
(10 intermediate revisions by one user not shown)
Line 1: Line 1:
 
[[InfluxDB2/Installation|Installation]] | [[InfluxDB2/Configuration|Configuration]]
 
[[InfluxDB2/Installation|Installation]] | [[InfluxDB2/Configuration|Configuration]]
 +
=Connect and Authenticate=
 +
[https://docs.influxdata.com/influxdb/v2.4/reference/cli/influx/config/create/ config] If you need to setup a new <code>configs</code> file to authenticate with influx cli
 +
<nowiki>~$ influx config create --active \
 +
  -n config-name \
 +
  -u http://localhost:8086 \
 +
  -t mySuP3rS3cr3tT0keN \
 +
  -o example-org</nowiki>
 +
 +
=Initial Setup=
 +
[https://docs.influxdata.com/influxdb/v2.4/reference/cli/influx/setup/ influx setup]
 +
This will also setup the <code>configs</code> file in <code>~/.influxdbv2/configs</code>
 +
<nowiki>~$ /usr/bin/influx setup --org name-org --bucket name-bucket --username user --password password --force</nowiki>
 +
[https://docs.influxdata.com/influxdb/v2.4/organizations/create-org/ influx org create]
 +
<nowiki>~$ /usr/bin/influx org create -n name-org</nowiki>
 +
[https://docs.influxdata.com/influxdb/v2.4/users/create-user/ influx user create]
 +
<nowiki>~$ /usr/bin/influx user create -n user -p password -o name-org</nowiki>
 +
[https://docs.influxdata.com/influxdb/v2.4/organizations/buckets/create-bucket/ influx bucket create]
 +
<nowiki>~$ /usr/bin/influx bucket create --name name-bucket --org name-org --retention 30d</nowiki>
 +
[https://docs.influxdata.com/influxdb/v2.4/security/tokens/create-token/ influx auth create]
 +
<nowiki>~$ /usr/bin/influx auth create --org name-org --read-bucket <alpha numeric bucket id> --read-tasks --write-bucket <alpha numeric bucket id> --write-tasks --user user</nowiki>
 +
 +
=Queries=
 +
[https://docs.influxdata.com/influxdb/v2.4/organizations/view-orgs/ org list]
 +
<nowiki>~$ /usr/bin/influx org list</nowiki>
 +
[https://docs.influxdata.com/influxdb/v2.4/organizations/buckets/view-buckets/ bucket list]
 +
<nowiki>~$ /usr/bin/influx bucket list</nowiki>
 +
 +
=Modifications=
 +
[https://docs.influxdata.com/influxdb/v2.4/organizations/buckets/update-bucket/ bucket update] Update the retention policy of a bucket
 +
<nowiki>~$ influx bucket update -i 16bb74d262c1aa5d -r 30d</nowiki>
 +
[https://docs.influxdata.com/influxdb/v2.4/organizations/buckets/create-bucket/ bucket create] Create a bucket
 +
<nowiki>~$ influx bucket create -n truenas-bucket -o grafana-org -r 30d</nowiki>
 +
[https://docs.influxdata.com/influxdb/v2.4/organizations/buckets/delete-bucket/ bucket delete] Delete a bucket
 +
<nowiki>~$ influx bucket delete -n truenas -o grafana-org</nowiki>
 +
[https://docs.influxdata.com/influxdb/v2.4/security/tokens/delete-token/ auth delete] Delete an API token
 +
<nowiki>~$ influx auth delete -i 09ef201ff19b2000</nowiki>

Latest revision as of 22:01, 8 September 2022

Installation | Configuration

Contents

[edit] Connect and Authenticate

config If you need to setup a new configs file to authenticate with influx cli

~$ influx config create --active \
  -n config-name \
  -u http://localhost:8086 \
  -t mySuP3rS3cr3tT0keN \
  -o example-org

[edit] Initial Setup

influx setup This will also setup the configs file in ~/.influxdbv2/configs

~$ /usr/bin/influx setup --org name-org --bucket name-bucket --username user --password password --force

influx org create

~$ /usr/bin/influx org create -n name-org

influx user create

~$ /usr/bin/influx user create -n user -p password -o name-org

influx bucket create

~$ /usr/bin/influx bucket create --name name-bucket --org name-org --retention 30d

influx auth create

~$ /usr/bin/influx auth create --org name-org --read-bucket <alpha numeric bucket id> --read-tasks --write-bucket <alpha numeric bucket id> --write-tasks --user user

[edit] Queries

org list

~$ /usr/bin/influx org list

bucket list

~$ /usr/bin/influx bucket list

[edit] Modifications

bucket update Update the retention policy of a bucket

~$ influx bucket update -i 16bb74d262c1aa5d -r 30d

bucket create Create a bucket

~$ influx bucket create -n truenas-bucket -o grafana-org -r 30d

bucket delete Delete a bucket

~$ influx bucket delete -n truenas -o grafana-org

auth delete Delete an API token

~$ influx auth delete -i 09ef201ff19b2000
Personal tools
Namespaces

Variants
Actions
Navigation
Mediawiki
Confluence
DevOps Tools
Ubuntu
Ubuntu 22
Mac OSX
Oracle Linux
AWS
Windows
OpenVPN
Grafana
InfluxDB2
TrueNas
OwnCloud
Pivotal
osTicket
OTRS
phpBB
WordPress
VmWare ESXI 5.1
Crypto currencies
HTML
CSS
Python
Java Script
PHP
Raspberry Pi
Canvas LMS
Kaltura Media Server
Plex Media Server
MetaSploit
Zoneminder
ShinobiCE
Photoshop CS2
Fortinet
Uploaded
Certifications
General Info
Games
Meal Plans
NC Statutes
2020 Election
Volkswagen
Covid
NCDMV
Toolbox