Hilscher Community Forum
MySQL database - Printable Version

+- Hilscher Community Forum (https://forum.hilscher.com)
+-- Forum: netPI 3 - Docker featuring Industrial Raspberry Pi 3 platform (https://forum.hilscher.com/forum-1.html)
+--- Forum: Software (https://forum.hilscher.com/forum-5.html)
+--- Thread: MySQL database (/thread-681.html)

MySQL database - DSongra - December-31st-2020


I have installed MySQL docker image version 5.7 from (https://hub.docker.com/r/mysql/mysql-server) on netPI RTE, I have created container . But container continuously restarting, in MySQL container logs showing (standard_init_linux.go:211: exec user process caused "exec format error") attached screenshot.

Thanks in advance.


RE: MySQL database - Armin@netPI - December-31st-2020

Yes this is normal. The MySQL docker image that you are loading is made for x86/x64 CPU processors:


And netPI CPU is an ARM based processor. So loading the standard MySQL container will fail in any case.

Remark: by the way the message "standard_init_linux.go:211: exec user process caused "exec format error"" is nothing special specifically for this container only. It is reported by any container worldwide if the processor type does not match.

So in your case you need to load a container made for ARM processors: I found in this Hilscher forum the following thread https://forum.hilscher.com/thread-316.html from year 2018. In this thread there is a container referenced named https://hub.docker.com/r/hypriot/rpi-mysql/. Its landing page describes the parameter the container needs. Mainly I see just the environment variable
that needs to be set. So once you want to start this container on netPI just define this environment variable MYSQL_ROOT_PASSWORD with a password of your choice and let it run.

In my post https://forum.hilscher.com/thread-316.html I managed it to get to work successfully.  So you should be able to do the very same.

At the end I have a question related to MySQL in general: why do you need to use MySQL? What do you want to store in this database?


RE: MySQL database - MGharat - January-6th-2021

Hi Armin,

Happy new year!

One of our customer has requirement for data logging at different time interval.

There are multiple AB PLC ( Ethernet/IP ) into network & we have to log the data read from the PLC at different time interval. Data has to be stored on cloud/remote server plus customer has requirement of remote upload/download of PLC program .

Thanks & BR

RE: MySQL database - Armin@netPI - January-6th-2021

But then MySQL database is the wrong choice. You need a time series database influxdb instead.

RE: MySQL database - Armin@netPI - January-6th-2021

The Influxdb coontainer supports ARM processor from the beginning and can be used on netPI right away. Here is the Docker homepage of Influxdb container: https://hub.docker.com/_/influxdb.

I have tested InfluxDB myself 1 year ago with version 1.7.8 successfully on netPI.

On netPI use the "add container" function with the following settings:

   name: influxdb
   image: influxdb:1.7.8
   restart: always
   network port mapping:
     - "host -> 8086: container -> 8086"
     - bridge
   environment variables:
     - INFLUXDB_DB=db0
     - INFLUXDB_USER=user

Of course you can change my dummy passwords with any other passwords you like.

After the successful deployment of this container you can test the influxdb container very easy using standard Node-RED and install influxdb read/write nodes additionally as documented here: https://flows.nodered.org/node/node-red-contrib-influxdb.

RE: MySQL database - DSongra - January-7th-2021

Hello Armin,

Now I am able to perform complete InfluxDB in netPi RTE. Attached screenshot.

InfluxDB server install on my laptop. 

Thanks for your help.


RE: MySQL database - Armin@netPI - January-7th-2021

Ok I see. But I understood that you customer wants to run database directly on netPI. In this case following this link https://forum.hilscher.com/thread-684.html and it show you how to install Node-RED, InfluxDB and visualization Grafana all in one on netPI.