# Getting data from Windows PC data

**URL:** <https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910>\
**Category:** Dashboard\
**Tags:** windows\
**Created:** [4 July 2019 15:07 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910 "2019-07-04T15:07:08Z")\
**Posts on this page:** 20\
**Page:** 4

<div class="post-metadata">

**Author:** ![bakman2](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/bakman2/32/6207_2.png) [@bakman2](https://discourse.nodered.org/u/bakman2)\
**Post date:** [9 July 2019 14:37 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/61 "2019-07-09T14:37:48Z")

</div>

Windows is not friendly in general 😉

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [9 July 2019 15:54 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/62 "2019-07-09T15:54:28Z")

</div>

Lets not start that - it is perfectly friendly in some respects and rubbish in others - just as is true for Linux and Mac.

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [18 July 2019 10:35 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/63 "2019-07-18T10:35:34Z")

</div>

> [@TotallyInformation](#):
>
> ```auto
> [{"id":"32e92aa6.b42a56","type":"inject","z":"63281c77.40a064","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":180,"y":560,"wires":[["8f973c9a.6ab93"]]},{"id":"8f973c9a.6ab93","type":"exec","z":"63281c77.40a064","command":"C:\\Apps\\DASHBOARDS\\telegraf\\telegraf.exe -config C:\\Apps\\DASHBOARDS\\telegraf\\telegraf-nrmanual-stdout.conf","addpay":false,"append":"","useSpawn":"true","timer":"","oldrc":false,"name":"Run Telegraf Manually","x":360,"y":560,"wires":[["2a23a3a9.b2db6c"],["25e73eb8.c0ddd2"],["7e23bda9.29b1a4"]]},{"id":"25e73eb8.c0ddd2","type":"debug","z":"63281c77.40a064","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":750,"y":560,"wires":[]},{"id":"7e23bda9.29b1a4","type":"debug","z":"63281c77.40a064","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":750,"y":600,"wires":[]},{"id":"dc234d3b.dc217","type":"debug","z":"63281c77.40a064","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","x":750,"y":520,"wires":[]},{"id":"2a23a3a9.b2db6c","type":"function","z":"63281c77.40a064","name":"","func":"msg.payload = msg.payload.split('{\"fields\":{')\n\nmsg.payload.forEach((v,i) => {\n if (v === '') return\n v = '{\"fields\":{' + v\n let pay = '', topic = msg.topic\n try {\n pay = JSON.parse(v.trim())\n topic = pay.name\n } catch(e) {\n pay = msg.payload \n }\n node.send({'topic':topic,'payload':pay})\n})\n","outputs":1,"noerr":0,"x":580,"y":520,"wires":[["dc234d3b.dc217"]]},{"id":"1f8d207e.d644b","type":"udp in","z":"63281c77.40a064","name":"","iface":"","port":"8094","ipv":"udp4","multicast":"false","group":"","datatype":"utf8","x":180,"y":640,"wires":[["f451a5f1.aff128"]]},{"id":"81e6e26d.46a7f","type":"debug","z":"63281c77.40a064","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":470,"y":640,"wires":[]},{"id":"f451a5f1.aff128","type":"json","z":"63281c77.40a064","name":"","property":"payload","action":"","pretty":false,"x":320,"y":640,"wires":[["81e6e26d.46a7f"]]}]
> 
> ```

Hello everyone again.  
dear @TotallyInformation is that possible to get data from windows PC with telegram ? Is it possible and stable right ?  
Sorry I dont get it very well

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [18 July 2019 17:59 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/64 "2019-07-18T17:59:45Z")

</div>

> [@wtrk](#):
>
> is that possible to get data from windows PC with telegram ?

Do you mean to send some metrics to Telegram from a Windows PC?

If you do, then yes. You can do this easily with Telegraf and Node-RED. It seems pretty stable to me though I don't run it permanently because I don't run a Windows server.

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [19 July 2019 05:56 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/65 "2019-07-19T05:56:58Z")

</div>

> [@TotallyInformation](#):
>
> > [@wtrk](#):
> >
> > is that possible to get data from windows PC with telegram ?
> 
> Do you mean to send some metrics to Telegram from a Windows PC?
> 
> If you do, then yes. You can do this easily with Telegraf and Node-RED. It seems pretty stable to me though I don't run it permanently because I don't run a Windows server.

Now I will try to getting dta from windows and then I will inform you I did or not

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [19 July 2019 07:30 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/66 "2019-07-19T07:30:31Z")

</div>

Telegram is not working windows PC, any other solution we have getting some data from windows PC ?

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [19 July 2019 07:38 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/67 "2019-07-19T07:38:51Z")

</div>

> [@bakman2](#):
>
> Even easier.
> 
> install (on the window machine):
> 
> [python](https://www.python.org/downloads/windows/)  
> [python pip](https://github.com/BurntSushi/nfldb/wiki/Python-&-pip-Windows-installation)  
> [glances](https://glances.readthedocs.io/en/stable/install.html)
> 
> Run glances as `glances -w` which starts it as webserver
> 
> From node red you can make a request to `http://<server-ip>:61208/api/3` and using the [documentation](https://github.com/nicolargo/glances/wiki/The-Glances-RESTFULL-JSON-API) you can retrieve all system info.

Dear @bakman2 Python I installed my windows but python pip and glances didnt install it, please how can I install it, help me

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [19 July 2019 08:15 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/68 "2019-07-19T08:15:21Z")

</div>

> [@wtrk](#):
>
> Telegram is not working windows PC

What do you mean? What errors are you getting?

The Node-RED Telegram Node (actually all 3 different Nodes) works perfectly on Windows, I use it all the time.

Did you actually mean Telegraf? But that also works perfectly, I have it running on my Windows 10 Surface Book 2.

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [19 July 2019 08:41 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/69 "2019-07-19T08:41:00Z")

</div>

> [@TotallyInformation](#):
>
> > [@wtrk](#):
> >
> > Telegram is not working windows PC
> 
> What do you mean? What errors are you getting?
> 
> The Node-RED Telegram Node (actually all 3 different Nodes) works perfectly on Windows, I use it all the time.
> 
> Did you actually mean Telegraf? But that also works perfectly, I have it running on my Windows 10 Surface Book 2.

This is telegram bot, we were talking about telegraf right ?

telegraf is not working on windows, I really confused everythings.

Just want to monitor some windows services, what is the easy way to do this ?

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [19 July 2019 08:48 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/70 "2019-07-19T08:48:51Z")

</div>

> [@wtrk](#):
>
> Just want to monitor some windows services, what is the easy way to do this ?

OK, you wrote Telegram instead of Telegraf. No problem.

Right, so now we know you've not managed to get Telegraf working, we need to understand why.

In my view, Telegraf is the easiest way - short of expensive software/services or even more confusing PowerShell scripts - to export system data from Windows.

So we need to know what you did to try and install Telegraf and what errors you got from the process so that we can help you get it working. For me, I just followed the instructions.

Here are a few links on using Telegraf with Windows:

- [Google Search](https://www.startpage.com/do/dsearch?query=telegraf+windows+install&cat=web&pl=opensearch&language=english)
- [Installing Telegraf | InfluxData Documentation](https://docs.influxdata.com/telegraf/v1.11/introduction/installation/)
- [telegraf/WINDOWS\_SERVICE.md at master · influxdata/telegraf](https://github.com/influxdata/telegraf/blob/master/docs/WINDOWS_SERVICE.md)

- [Running Telegraf as a Windows service | InfluxData Documentation](https://docs.influxdata.com/telegraf/v1.11/administration/windows_service/)
- [Guide for Set Up of Telegraf for Monitoring Windows | Tracy Boggiano's SQL Server Blog](https://tracyboggiano.com/archive/2018/04/guide-for-set-up-of-telegraf-for-monitoring-windows/)

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [19 July 2019 18:57 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/71 "2019-07-19T18:57:32Z")

</div>

> [@TotallyInformation](#):
>
> > [@wtrk](#):
> >
> > Just want to monitor some windows services, what is the easy way to do this ?
> 
> OK, you wrote Telegram instead of Telegraf. No problem.
> 
> Right, so now we know you've not managed to get Telegraf working, we need to understand why.
> 
> In my view, Telegraf is the easiest way - short of expensive software/services or even more confusing PowerShell scripts - to export system data from Windows.
> 
> So we need to know what you did to try and install Telegraf and what errors you got from the process so that we can help you get it working. For me, I just followed the instructions.
> 
> Here are a few links on using Telegraf with Windows:
> 
> - [Google Search](https://www.startpage.com/do/dsearch?query=telegraf+windows+install&cat=web&pl=opensearch&language=english)
> - [Installing Telegraf | InfluxData Documentation](https://docs.influxdata.com/telegraf/v1.11/introduction/installation/)
> - [telegraf/WINDOWS\_SERVICE.md at master · influxdata/telegraf](https://github.com/influxdata/telegraf/blob/master/docs/WINDOWS_SERVICE.md)
> 
> - [Running Telegraf as a Windows service | InfluxData Documentation](https://docs.influxdata.com/telegraf/v1.11/administration/windows_service/)
> - [Guide for Set Up of Telegraf for Monitoring Windows | Tracy Boggiano's SQL Server Blog](https://tracyboggiano.com/archive/2018/04/guide-for-set-up-of-telegraf-for-monitoring-windows/)

I have downloaded and installed telegraf in windows

After that I imported your flow but it gives an error.  
what I will do, please can you define me step by step

 ![Ekran%20Al%C4%B1nt%C4%B1s%C4%B1](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/7/7c0e138e89b62bdfa4a1eb7e0a4f6d1cf501a3f3.png)

 ![Ekran%20Al%C4%B1nt%C4%B1s%C4%B1](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/2/239941da6dca3c00ca98352bb9e5f686c18c4bbc.png)

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [19 July 2019 20:15 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/72 "2019-07-19T20:15:54Z")

</div>

First step: Is Telegraf running and is it producing output? Configure a couple of collectors and perhaps the file output just to make sure it is working.

Next step is to decide where you actually want the output to go - for example, is there an MQTT broker on the same network as the Windows device? If so, that might be a good place to send stuff. Otherwise, once you have confirmed that Telegraf is working, we will need to configure Telegraf to output to a TCP port and Node-RED to listen on that same port.

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [19 July 2019 20:38 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/73 "2019-07-19T20:38:06Z")

</div>

Fİrst step : How can I understand, telegraf producing output ? I just know service is working but dont know producing output.

Next step is : Raspberry PI and windows machine same network and connected eachother also pinging

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [19 July 2019 20:41 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/74 "2019-07-19T20:41:47Z")

</div>

Please read the Telegraf documentation, it isn't difficult to configure. There are a wide range of outputs including a file output which will be the quickest to configure when testing as a service. You could also stop the service and run Telegraf manually - the default test output goes to the console in that case.

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [19 July 2019 20:46 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/75 "2019-07-19T20:46:29Z")

</div>

I have read many times, but I dont get it clearly.

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [20 July 2019 08:04 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/76 "2019-07-20T08:04:33Z")

</div>

Log files always say this.  
How can I go forward

```auto
2019-07-19T22:07:41Z E! [outputs.influxdb] when writing to [http://localhost:8086]: Post http://localhost:8086/write?db=telegraf: dial tcp [::1]:8086: connectex: Target Machine actively refused connection.

```

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [20 July 2019 08:42 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/77 "2019-07-20T08:42:45Z")

</div>

Is influxdb running on that computer?  
If you believe it is are you able to access using, for example, the influx command line client?

---

<div class="post-metadata">

**Author:** ![wtrk](https://avatars.discourse-cdn.com/v4/letter/w/97f17d/32.png) [@wtrk](https://discourse.nodered.org/u/wtrk)\
**Post date:** [20 July 2019 08:56 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/78 "2019-07-20T08:56:01Z")

</div>

My pc is x86 I didnt find influxdb for win x86 OS, so I dont install influx db on my windows. But raspberry already installed influx db.

On windows PC I only run telegraf.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [20 July 2019 09:29 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/79 "2019-07-20T09:29:58Z")

</div>

I assume that log is on the PC. I don't use telegraf, but looking at the error suggests that you have told it to use influx on the PC (that's what localhost means), you need to tell it where the influx server is.

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [20 July 2019 10:13 UTC](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910/80 "2019-07-20T10:13:30Z")

</div>

> [@wtrk](#):
>
> Log files always say this.

You have left in the configuration to output to InfluxDB and you don't want that. Just remove it from the Telegraf config file and put in the file output instead.

[Previous page](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910.md?page=3)

[Next page](https://discourse.nodered.org/t/getting-data-from-windows-pc-data/12910.md?page=5)
