Can't run telegraf on AWS EC2 ( Amazon Linux )

I configed “http” output in telegraf.conf, but got this error log.

2021-06-21T09:48:30Z I! Starting Telegraf 1.19.0
2021-06-21T09:48:30Z E! [telegraf] Error running agent: Error loading config file /etc/telegraf/telegraf.conf: error parsing http array, line 92: field corresponding to `tls_cert’ in http.HTTP cannot be set through TOML
“/var/log/telegraf/telegraf.log” 210L, 33046C

This is my telegraf.conf file

interval = “10s”
round_interval = true
metric_batch_size = 5000
metric_buffer_limit = 10000
collection_jitter = “0s”
flush_interval = “10s”
flush_jitter = “0s”
precision = “”
omit_hostname = false
url = “
timeout = “5s”
method = “POST”
data_format = “influx”
content_encoding = “gzip”
insecure_skip_verify = true
name_prefix = “rn-”
tls_ca = “/etc/telegraf/cert/ca.pem”
tls_cert = “/etc/telegraf/cert/client-cert.pem”
tls_key = “/etc/telegraf/cert/client-key.pem”
percpu = true
totalcpu = true
collect_cpu_time = false
report_active = false

@popey can you please help me here?
Thank you

1 Like

Hi, sorry to hear you’re having problems with this.

I’ve reproduced the issue here on telegraf 1.19, and note that the error doesn’t occur on telegraf 1.18.3. Please could you try rolling back to telegraf 1.18.3 and see if that works around the issue?

It looks like we have an issue reported, so if we confirm with you it’s a problem with the 1.19.0 release, we should continue the conversation there, I think.

1 Like