• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[SOLVED] Storing data on a (remote) database
#1
Hi Armin,

One of our customer wants to read data from AB PLC ( Ethernet/IP ) & store/log in to netPI & then want to export the database to a server...How we can do this with netPI? Can we use SQLite node with netPI?

BR
Madhumati
  Reply
#2
Well Madhumati,

if I hear "data storage" under long term conditions I am always concerned about the durability of the default SD card memory we use in netPI. It is a NAND Flash based of type MLC and by its very nature of design it has limited program/erase write cycles (3000 p/e by the way per block).  So the question is how many data does this customer want to store on the SD card per day? Examinations about the SD cards durability were topic of another thread.

You say "to export the database to a server" ... of which type of server is this? Can the database server be defined/setup still or is it set already?

I am asking because I would not recommend SQlite but a time series database like InfluxDB instead. See here a comparison.

So the server should run InfluxDB and there is Node-RED influxdb node available to write to InfluxDB from local netPI to the remote database. So there is no need to store data locally which is good for the SD card.
You never fail until you stop trying.“, Albert Einstein (1879 - 1955)

  Reply
#3
Is there any way to test this in office ? Can we have Influx DB server avilble on PC?
Also,Do you have any earlier experience on this?

I am trying to configure the flow, but it shows error for DB node, please check attached screenshot..

I have to demonstate this to one of our customer here. He wants to read data from AB PLC ( alarms, event etc) & log it into netPI

can you please help?


Attached Files Thumbnail(s)
       
  Reply
#4
Hi Madhumati,

you can read the data from the PLC , process the data and can write the values into a InfluxDB with Node-RED.

For the communication to the InfluxDB i use the "node-red-contrib-influxdb" Node-RED node.
You can download the InfluxDB server for Windows, Linux, Mac OS .... under https://portal.influxdata.com/downloads/


Best Regards
Patrick
  Reply
#5
Hello Madhumati,

have you already installed InfluxDB on your Windows PC 192.168.0.5? In your screen shot of InfluxDB node I see you did not enter the name of your InfluxDB database. So the question is how did you name the InfluxDB after installation?
You never fail until you stop trying.“, Albert Einstein (1879 - 1955)

  Reply
#6
Hi,

Ihave created a databse now Test  & also now added the dtaabase name in my flow.attached screnshot.

I could not see the data into logview...


Attached Files Thumbnail(s)
           
  Reply
#7
Madhumati, your screen shots show InfluxDB installed as www on the influxcloud.net cloud as internet service and not installed on your local PC 192.168.0.5.

So you have not installed InfluxDB in your local PC. You need to install InfluxDB as Windows Version.
You never fail until you stop trying.“, Albert Einstein (1879 - 1955)

  Reply
#8
(May-28th-2019, 11:33 AM)Armin@netPI Wrote: Madhumati, your screen shots show InfluxDB installed as www on the influxcloud.net cloud as internet service and not installed on your local PC 192.168.0.5.

So you have not installed InfluxDB in your local PC. You need to install InfluxDB as Windows Version.

I can see as attached  screenshot herewith --Is it correct application? How I can proceed in this case?

(May-28th-2019, 09:35 AM)Patrick@netPI Wrote: Hi Madhumati,

you can read the data from the PLC , process the data and can write the values into a InfluxDB with Node-RED.

For the communication to the InfluxDB i use the "node-red-contrib-influxdb" Node-RED node.
You can download the InfluxDB server for Windows, Linux, Mac OS .... under https://portal.influxdata.com/downloads/


Best Regards
Patrick

On this link I get as below attached -Is it the correct aplication to use ?


Attached Files Thumbnail(s)
       
  Reply
#9
Hello Madhumati,

this screen shot looks good.

But after starting InfluxDB application on Windows you need to create a database first. You can name it "armin", "madhumati", "netpi" or anything else. You can have multiple databases running under InfluxDB at the same time, but all with different names. Here find explained https://docs.influxdata.com/influxdb/v1...._download/ how to proceed to create a database with a windows console.

Later - without a database name- you cannot use InfluxDB Node-RED to write to a database since InfluxDB addressing scheme including Node-RED InfluxDB node needs next to the IP address also the name of the database where to write to.

Since running a time series data base like InfluxDB under windows or other systems is of interest for others we will be providing an example how to get a InfluxDB up and running today in another thread. We will be showing how to create a database without use of a console but within a simple Node-RED and then how to access it.

Thx
You never fail until you stop trying.“, Albert Einstein (1879 - 1955)

  Reply
#10
I have posted a very easy Node-RED flow.
This flow can create or delete a database, write values and can read values from the database.

Link: Node-RED flow
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Information InfluxDB - Time series database under Windows patrick 1 4,130 February-1st-2021, 07:13 PM
Last Post: Armin@netPI
  Read/write data from S7 with netPI over Profinet student 10 9,434 September-9th-2020, 04:59 PM
Last Post: Armin@netPI
  Send Data to Specific Port via UDP Hoeber 2 3,355 July-29th-2020, 09:10 AM
Last Post: Hoeber
  TOSIBOX enables netPI remote access from anywhere jkrimpenfort 3 6,251 July-18th-2020, 06:35 AM
Last Post: Armin@netPI
  PROFINET to OPC UA data conversion with Node-RED Armin@netPI 0 3,480 July-7th-2020, 12:20 PM
Last Post: Armin@netPI
  Getting data from AllenBradley PLC MarcoMedina 3 4,036 February-26th-2020, 11:53 AM
Last Post: Armin@netPI
  Fetch data from S7 PLC Profibus DP MGharat 3 3,679 March-14th-2019, 11:21 AM
Last Post: Armin@netPI
  [SOLVED] EtherCAT Slave snortman 5 5,742 February-7th-2019, 07:36 AM
Last Post: Armin@netPI
  Secomea Remote Acccess ballesj 1 7,536 May-15th-2018, 12:42 PM
Last Post: Armin@netPI
  IBM sensor data historian and analytics engine for the netPi AlexKoeMuc 0 2,273 November-28th-2017, 01:39 PM
Last Post: AlexKoeMuc

Forum Jump:


Users browsing this thread: 1 Guest(s)