I’ve read the other posts on this topic, and so far, no one has had an answer.
2021-07-09T13:49:49Z E! [agent] Error writing to outputs.influxdb_v2: Post "https://davidgs.com:8086/api/v2/write?bucket=telegraf&org=influxdata": context deadline exceeded (Client.Timeout exceeded while awaiting headers)
And in indeed, I have no data being written to InfluxDB. Suspecting a token issue, I made a new all-access token, yet the error persists.
Earlier in the log:
2021-07-09T13:52:01Z I! Loaded inputs: cpu disk diskio dovecot http_listener http_listener_v2 (2x) kernel mem mongodb mqtt_consumer mysql net netstat processes swap syslog system webhooks 2021-07-09T13:52:01Z I! Loaded aggregators: 2021-07-09T13:52:01Z I! Loaded processors: 2021-07-09T13:52:01Z I! Loaded outputs: file influxdb_v2 2021-07-09T13:52:01Z I! Tags enabled: host=whm.davidgs.com 2021-07-09T13:52:01Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:"whm.davidgs.com", Flush Interval:10s 2021-07-09T13:52:01Z D! [agent] Initializing plugins 2021-07-09T13:52:01Z D! [agent] Connecting outputs 2021-07-09T13:52:01Z D! [agent] Attempting connection to [outputs.influxdb_v2] 2021-07-09T13:52:01Z D! [agent] Successfully connected to outputs.influxdb_v2 2021-07-09T13:52:01Z D! [agent] Attempting connection to [outputs.file] 2021-07-09T13:52:01Z D! [agent] Successfully connected to outputs.file 2021-07-09T13:52:01Z D! [agent] Starting service inputs
So it can connect, it just won’t write to the database.
Other processes can write directly to InfluxDB on that host (I have, as you know, tons of sensors around that are all writing data directly to InfluxDBv2 without Telegraf).
This problem seems unique to telelgraf.