Hello,
I have installed Telegraf on a server and I’m trying to pull metrics from my
VMware vCenter 6.7 and push to Influx to monitor data on Grafana with this Dashboard : VMware vSphere - Overview | Grafana Labs
But the vSphere Input Plugin start and nothing happens, i don’t have any data on my dashboard
Here is Telegraf’s log :
2020-04-02T16:19:15Z I! Starting Telegraf 1.14.0,
2020-04-02T16:19:15Z I! Using config file: /etc/telegraf/telegraf.conf,
2020-04-02T16:19:15Z I! Loaded aggregators: ,
2020-04-02T16:19:15Z I! Loaded inputs: cpu disk kernel vsphere system diskio mem processes swap,
2020-04-02T16:19:15Z I! Loaded outputs: influxdb,
2020-04-02T16:19:15Z I! Loaded processors: ,
2020-04-02T16:19:15Z I! Tags enabled: host=INFVM-FORGE-MONITOR,
2020-04-02T16:19:15Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:“INFVM-FORGE-MONITOR”, Flush Interval:10s,
2020-04-02T16:19:15Z I! [inputs.vsphere] Starting plugin
I edited telegraf.conf to
add influxdb localhost IP + username and password :
adding vsphere input plugin like said in the dashboard documentation :
I’m running influx / telegraf / grafana on docker containers that are on the same network as the vCenter
How can i do to make it work ?
Thanks
I have the same issue. Did you ever solve this?
same situation, anything help??
Hi Daniel,
I’d suggest starting with the following:
Check your vCenter URL is correct and accessible from the server where Telegraf is running.
Update your telegraf.conf file and set debug = true
for your [agent]
section.
Check your connectivity ability, including firewall settings.
Pete
Hi Pete,
thanks for your help
the result is:
May 20 13:38:15 bumvmonlnx01 telegraf[72168]: 2024-05-20T13:38:15Z D! [inputs.vsphere] Creating client: 10.91.xxx.yyy
May 20 13:38:15 bumvmonlnx01 telegraf[72168]: 2024-05-20T13:38:15Z E! [telegraf] Error running agent: starting input inputs.vsphere: Post “https://10.91.xxx.yyy/sdk ”: EOF
May 20 13:38:15 bumvmonlnx01 systemd[1]: telegraf.service: Main process exited, code=exited, status=1/FAILURE
May 2
Danieldvv:
EOF
Getting an EOF error could mean a lot of different things.
In terms of the network, some network connection might have gone down or a proxy between you and the vsphere server could be cutting off the connection. The proxy scenario is the most likely if this is constantly repeatable and not intermittent.
From the remote server, it might not be up or rejected the request due to credentials.
i dont have Proxy in the middle.
using telnet to test connectivity does not appear with problems
What do you advise me to continue trying and solve my problem?
thanks in advance
What version of vsphere are you using?
What version of Telegraf?
I am going to assume that you always get the EOF error and the plugin never works? It would be good to get the full logs, not just two lines as well.
Vmware vcenter server version 6.0.0
Comp. 3634794
telegraf --version
Telegraf 1.30.2 (git: HEAD@10c15ce4)
May 22 19:31:08 bumvmonlnx01 systemd[1]: Starting Telegraf…
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Loading config: /etc/telegraf/telegraf.conf
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Loading config: /etc/telegraf/telegraf.d/influx.conf
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Loading config: /etc/telegraf/telegraf.d/ping.conf
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Loading config: /etc/telegraf/telegraf.d/vsphere-stats.conf
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z W! DeprecationWarning: Option “force_discover_on_init” of plugin “inputs.vsphere” deprecated since version 1.14.0 and will be removed in 2.0.0: option is ignored
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z W! DeprecationWarning: Option “force_discover_on_init” of plugin “inputs.vsphere” deprecated since version 1.14.0 and will be removed in 2.0.0: option is ignored
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Starting Telegraf 1.30.2 brought to you by InfluxData the makers of InfluxDB
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Available plugins: 233 inputs, 9 aggregators, 31 processors, 24 parsers, 60 outputs, 6 secret-stores
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Loaded inputs: cpu disk diskio kernel mem ping processes swap system vsphere (2x)
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Loaded aggregators:
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Loaded processors:
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Loaded secretstores:
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Loaded outputs: influxdb_v2
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! Tags enabled: host=bumvmonlnx01
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z W! Deprecated inputs: 0 and 2 options
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! [agent] Config: Interval:10s, Quiet:false, Hostname:“bumvmonlnx01”, Flush Interval:10s
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z D! [agent] Initializing plugins
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z D! [agent] Connecting outputs
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z D! [agent] Attempting connection to [outputs.influxdb_v2]
May 22 19:31:08 bumvmonlnx01 systemd[1]: Started Telegraf.
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z D! [agent] Successfully connected to outputs.influxdb_v2
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z D! [agent] Starting service inputs
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z I! [inputs.vsphere] Starting plugin
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z D! [inputs.vsphere] Creating client: 10.91.xxx.yyy
May 22 19:31:08 bumvmonlnx01 telegraf[76179]: 2024-05-22T19:31:08Z E! [telegraf] Error running agent: starting input inputs.vsphere: Post “https://10.91.xxx.yyy/sdk ”: EOF
May 22 19:31:08 bumvmonlnx01 systemd[1]: telegraf.service: Main process exited, code=exited, status=1/FAILURE
May 22 19:31:08 bumvmonlnx01 systemd[1]: telegraf.service: Failed with result ‘exit-code’.
thanks very much
This could be the reason, 6, including 6.5 and 6.7 are EOL. The library used may not be responding to vsphere 6 correctly anymore.
vsphere (2x)
You have two vsphere plugins defined? Is this what you expected? Are both failing?
I’ve seen EOL errors come up before in the library Telegraf uses with vsphere:
The only one that looks relevant would be the first:
Not specifying /sdk in the path, which you have unless a second is configured incorrectly?
Not talking to the sdk itself
Josh, Thank you for your time and availability.
I think what you say about the EOL of the Vcenter Server version could be the issue.
As you indicated, I eliminated the “/sdk” part of the url but it was still added to the error log
Is there any other way to monitor my version of vcenter with telegraph?
I had two input.vspheres, I deleted the second one (which had captures every 300 seconds) and left only the 60 second one. but I still get the error.
Unfortunately, not directly. You could try writing your own code to collect whatever you want from the API directly and pass it to Telegraf, but that could be a larger endeavor.