influxd - InfluxDB service

API token hashing is enabled by default in InfluxDB OSS 2.9.0

Stronger token security: tokens are stored as hashes on disk, so a copy of the database file doesn’t expose usable tokens. Existing tokens are hashed on first startup and the original strings can’t be recovered afterward — capture any plaintext tokens you still need before you upgrade.

For more information, see Token hashing.

The influxd daemon starts and runs all the processes necessary for InfluxDB to function.

Usage

influxd [flags]
influxd [command]

For information about other available InfluxDB configuration methods, see InfluxDB configuration options.

Commands

CommandDescription
downgradeDowngrade metadata schema to match an older release
helpOutput help information for influxd
inspectInspect on-disk database data
print-config(Deprecated) Print full influxd configuration for the current environment
recoveryRecover operator access to InfluxDB
runStart the influxd server (default)
upgradeUpgrade a 1.x version of InfluxDB to 2.10
versionOutput the current version of InfluxDB

Flags

Exit codes

Available in InfluxDB OSS v2.10 and later.

When the influxd server fails to start, its exit code tells you whether restarting can help. The codes follow the BSD sysexits.h convention.

CodeNameMeaningRestart helps?
0EX_OKStartup and shutdown succeeded, including a shutdown requested by a signal.—
1—An error with no category. Subcommands such as inspect, upgrade, and recovery report all failures with this code.Unknown
64EX_USAGEThe command line is wrong: an unknown flag, a flag value that can’t be parsed, or an unexpected argument.No
65EX_DATAERRThe data on disk isn’t readable by this version–for example, InfluxDB 1.x _series or index directories under --engine-path.No
66EX_NOINPUTA path doesn’t exist or is the wrong type–for example, --engine-path points to a file, or a parent directory is missing.No
69EX_UNAVAILABLEA required resource is in use: the --http-bind-address port, an existing --pid-file, or a dependency that refused the connection.Only after the conflict clears
70EX_SOFTWAREStartup failed without an operating system cause. Read the error and the log.No
71EX_OSERRThe operating system ran out of file descriptors or memory.After you raise the limits
73EX_CANTCREATA file can’t be created or extended: the disk is full, a quota is exhausted, or the file system is read-only.After you free space or make the file system writable
74EX_IOERRAn I/O error occurred while reading or writing, usually from hardware or a failing file system.No
75EX_TEMPFAILAn operation didn’t finish: a dependency timed out, SIGINT interrupted startup, or shutdown exceeded its time limit.Yes
77EX_NOPERMPermission was denied on a data directory, PID file, TLS certificate, or privileged port.No
78EX_CONFIGA configuration value is wrong–for example, 1.x keys in a 2.x configuration file, a configuration file that can’t be parsed, or an invalid option value.No

To retrieve the startup error from the /health and /ready endpoints before influxd exits, set startup-error-linger.

Prevent restart loops with systemd

If influxd exits with a code that a restart can’t fix, systemd restarts it into the same failure. To stop restarting on those codes, add RestartPreventExitStatus to the influxd service unit:

[Service]
Restart=on-failure
RestartPreventExitStatus=64 65 66 70 74 77 78

Was this page helpful?

Thank you for your feedback!