I have a very simple flow which collects and records around 30 inputs from a PLC register every minute and stores the data in a MySQL Database.
The flow.json size is 50kb.
The MySQL database is at 96 MB and has a years worth data (30 records /minute * 365 days) approx 525,600 records x 30 columns
the database size grows around 0.2 MB every day.
current setup is one PC running windows 10 with no active users, and set to auto run a NR service to run the collect data from a PLC and database logging flow.
my question is: what is the minimum hardware specification required to run this
(i am looking a at a Raspberry pi) , If i plan to take a backup of data on daily basis into a cloud storage, but still want to keep a years data on the device. (around 100MB size of data).
I run Node-red and MySQL (Mariadb) plus several other services very happily on a Raspberry Pi 4 with 2GB memory and 120GB SSD.
My database is not as big as yours though, only 1 month's data.
You say 30 records per minute but 525 600 records is just 1 per minute?
I guess you must have paid due attention to db indexing.
How long does the daily backup take? I wonder how this will impact your inserts every 2 seconds.
Minimum hardware - Mariadb will run on a Pi Zero 2, so will Node-red, but perhaps not on the same Zero 2.
I wrote this wrong. 30 individual data register readings from from plc (modbus read), combined into one insert statement to update one row of data with 30 fields. insert statement triggered with cronplus at a once per minute frequency
525600 rows for one year
So a Pi-4 with 2GB should be OK ?
the current setup of a windows PC is fine, but i want to put the complete setup near the PLC module itself so in the event of a network failure i will not lose the data from plc. installing a computer unit near PLC is slightly difficult because of space issue there.